Обсуждение: Bad SQL generated by application

Поиск
Список
Период
Сортировка

Bad SQL generated by application

От
Curtis Galloway
Дата:
Hi all.  I'm trying to get a Windows application to talk to a Postgres
database using the Postgres ODBC driver.  The application, ThumbsPlus,
is designed to work with Microsoft Jet or SQL Server, but I have been
able to port their schema to something that works with Postgres.

It mostly works, but there are some areas in the application that don't
work.  In particular, it seems to try to drop and recreate some indexes,
as well as dynamically creating a couple of tables.

I am trying to figure out whether the problem is in the SQL the
application generates, or whether the ODBC driver is generating the SQL.
    I can't tell from looking at the ODBC log which is the case.

I am relatively new to Postgres and ODBC, although I have a lot of
experience with Oracle.  Can anyone give me some advice for debugging
this problem?

Thanks,
--Curtis


Re: Bad SQL generated by application

От
Cedar Cox
Дата:
On Mon, 14 Jan 2002, Curtis Galloway wrote:
>
> I am trying to figure out whether the problem is in the SQL the
> application generates, or whether the ODBC driver is generating the SQL.
>     I can't tell from looking at the ODBC log which is the case.
>
> I am relatively new to Postgres and ODBC, although I have a lot of
> experience with Oracle.  Can anyone give me some advice for debugging
> this problem?

Turn on debugging ;)  Really, turn on logging of SQL commands in the
backend and look there so you can see how the backend gets the SQL (from
the ODBC driver).

-Cedar