Page 1 of 1

PgSqlLoader problems/questions

Posted: Mon 04 May 2009 15:10
by robofx
I have some PgSqlLoader problems/questions:

Using:
Visual Basic 2008
dotconnect for Postgresql Pro 4.50.29

1. I followed your VB demo project code closely, but still cannot figure out: how to APPEND data to database? For example, I load 10 rows to database from a file by using loader. Then I load 10 more rows from different file. I should have 20 rows total, but in fact I have only 10 rows. No append! Am I missing some setting or something?

2. I load some rows. Then later I load some more rows. No append, but still working OK. But on THIRD load, it crashes at line containing "loader.createcolumns" with error:
Syntax error at or near ")"

Also, loader.columns.count is correct for 1st & 2nd load, but count becomes ZERO on the 3rd (failed) load.

-------
Thank you, I emailed these questions also to support.

Posted: Tue 05 May 2009 15:14
by robofx
I figured out what's cause the problem.

Postgresql database table must have *NO* primary key in order for pgsqlloader to work correctly??

How to use loader when table has primary key?

Posted: Wed 06 May 2009 10:18
by Shalex
We will investigate this issue and notify you about the results as soon as possible.

Posted: Thu 07 May 2009 09:17
by Shalex
The current build of dotConnect for PostgreSQL has a problem: if the referential integrity is violated when adding new rows to the table with a primary key, the rows are not added, but the appropriate exception is catched inside our code, and it is not shown outside. We have fixed this behaviour. Exceptions that allow to identify the problem will be included in the next build of dotConnect for PostgreSQL that will be available in 2 weeks.

Probably, this is a referential integrity issue in your case. Please make sure there is no referential integrity violation when you are adding new rows into your table.

Posted: Fri 22 May 2009 16:33
by Shalex
The new build of dotConnect for PostgreSQL 4.50.33 is available for download now.
It can be downloaded from http://www.devart.com/dotconnect/postgr ... nload.html (trial version) or from Registered Users' Area (for users with valid subscription only).
For more information, please refer to http://www.devart.com/forums/viewtopic.php?t=14911 .