Użytkownik John Fabiani napisał:
> No I think what he is saying is the code I provided (designed to work with
> Postgres) is causing a problem with FireBird because of the LIMIT statement
> I'm most likely added.
>
> I guess there are several ways this can be handled.
>
> 1. create an if elif statement handling the different ways the different
> databases require it.
>
> 2. change the code to use .setLimitClause("1000") - I'm guessing that will be
> much harder.
>
I think it's not so hard.
Instead of using cursor.execute("some sql"), use the embedded SQL
builder instead:
cursor.setFieldClause(...)
cursor.setFromClause(...)
cursor.setWhereClause(...)
cursor.setLimitClause("1000")
cursor.executeSQL((param1, param2, param3))
It's the backend independent way.
Regards
Jacek Kałucki
_______________________________________________
Post Messages to: [email protected]
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: http://leafe.com/archives/byMID/[email protected]