Hello,
My main use of TUniSQL is for multiple command execution. By default TUniSQL.SpecificOptions.UnpreparedExecute is set to True.
This is not a problem for Microsoft SQL Server. However, PostgreSQL cannot insert multiple commands into a prepared statement.
Is it possible to define a project wide setting for all TUniSQL components so that their SpecificOptions.UnpreparedExecute will be set to False?
Or, is it possible to turn this parameter to False by default if provider is PostgreSQL?
Thanks & regards,
Ertan
TUniSQL with PostgreSQL
Re: TUniSQL with PostgreSQL
To solve the specified issue you can use one of the following solutions:
- to execute multiple SQL queries you can use the TUniScript component: https://www.devart.com/unidac/docs/?dev ... script.htm
- in the code of a custom application set the specific option UnpreparedExecute to True for each TUniSQL instance
- use the protocol 2.0 to connect to PostgreSQL. For this, you need to set TUniConnection.SpecificOptions.Values['PostgreSQL.ProtocolVersion'] to the 'pv20' value.
- to execute multiple SQL queries you can use the TUniScript component: https://www.devart.com/unidac/docs/?dev ... script.htm
- in the code of a custom application set the specific option UnpreparedExecute to True for each TUniSQL instance
- use the protocol 2.0 to connect to PostgreSQL. For this, you need to set TUniConnection.SpecificOptions.Values['PostgreSQL.ProtocolVersion'] to the 'pv20' value.