PgSqlCommandBuilder - Problems with SQL-Keywords

PgSqlCommandBuilder - Problems with SQL-Keywords

Postby itools_berlin » Thu 14 Sep 2006 16:26

While working with PgSqlCommandBuilder (PostgreSQLDirect .NET Professional 2.50.15.0) I encountered two Problems with SQL-Keywords in the "template"-Select-SQL which is used to generate Insert-, Update- and Delete-Statements.

1. Problem:
if a field in any Table has a name with "from" in the end, e.g. "arrival_from", the commandbuilder generates generates a comma (","), because it assumes the next word to be the tablename.

with a query like
select id, name, arrival_from, moves_to from table package_items
the commandbuilder generates wrong commands

2. Problem
if I'm using inheritance in my Postgres-database i need to use the "only" keyword in my Statements to update only rows of a certain entity-type and not all its sub-classes (sub-tables). The commandbuilder is not able to recognize the only keyword in the "template"-Select-SQL Statement. the commandbuilder assumes the "only"-Keyword to be the tablename.

with a query like
select id, name, surname, birth_date from only person
the commandbuilder generates wrong commands

the generate update command is like this:
update only set id = :p1, ...

what i expect to be generated is a statement like this:
update only person set id = :p1, ...

could you please fix this behaviour or tell me when planning to do so

regards Christan
itools_berlin
 
Posts: 1
Joined: Thu 14 Sep 2006 15:56

Postby Alexey » Fri 15 Sep 2006 07:13

The first problem seems to be absent in PostgreSQLDirect 2.50.20.
The second is reproduced and will be fixed in the next build.
Alexey
 
Posts: 2756
Joined: Mon 13 Mar 2006 07:43


Return to dotConnect for PostgreSQL