[unixODBC-support] BUG: postgresql prepare statment doesn't support creating tables

Nick Gorham nick at lurcher.org
Mon Oct 26 18:24:07 GMT 2015


On 26/10/15 18:13, support at vip-consult.co.uk wrote:
> Hi all could you please comment on this bug report ?
>
> Kind Regards Chris
> <https://plus.google.com/104360588474957851138/about><https://www.facebook.com/VIPConsultitcentre>
> 	Happy with our service ?
> Join us and leave feedback
>
> Vip consult Logo <http://www.vip-consult.co.uk>
> 08455 271771    01202 232240
> Company Registration No. 8434950
>
> *From:* support at vip-consult.co.uk <mailto:support at vip-consult.co.uk>
> *Sent:* Thursday, October 22, 2015 5:39 PM
> *To:* unixodbc-support at mailman.unixodbc.org 
> <mailto:unixodbc-support at mailman.unixodbc.org>
> *Subject:* BUG: postgresql prepare statment doesn't support creating 
> tables
> hi all
>
> the postgresqk  unixdbc driver doesn’t seem to work with table create 
> statments on Debian Jessie
> on isql trying to execute
> CREATE TABLE a (c integer)
> ERROR:  syntax error at or near "create" at character 29
> I have looked at the logs and it seems that is uses PREPARE create 
> table   statments which as far as I know  is not supported in postgresql
> ERROR:  syntax error at or near "create" at character 29
> STATEMENT:  PREPARE "_PLAN0x25ca9e0" as create table aaa (aa 
> integer);;EXECUTE "_PLAN0x25ca9e0"
>
> is there any way to disable prepare statements or  a better way fix 
> this bug ?
> Debian jessie
> unixODBC 2.3.4
> postgresql 9.3 (also tried latest)
>
> [freeswitch]
> Driver        = /usr/lib/x86_64-linux-gnu/odbc/psqlodbcw.so
> Description=Connection to LDAP/POSTGRESQL
> Servername=localhost
> Port=5432
> Protocol=6.4
> FetchBufferSize=99
> Username=fs
> Password=xxxxx
> Database=fs
> ReadOnly=no
> Debug=1
> CommLog=1

Try

isql -e freeswitch

To call SQLExecDirect instead of SQLPrepare/SQLExecute

Though thats just a workround, the bug is in the driver, so I would ask 
the driver writers as to the solution.

-- 
Nick
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.unixodbc.org/pipermail/unixodbc-support/attachments/20151026/c03ee805/attachment.html>


More information about the unixODBC-support mailing list