pg.ddx.io pgsql-interfaces@postgresql.org mailing list archive
help / color / mirror / Atom feedHow to use question mark in query thru ODBC from Windows
2+ messages / 2 participants
[nested] [flat]
* How to use question mark in query thru ODBC from Windows
@ 2000-06-24 18:47 Kari Lempiainen <kari@funky.pp.fi>
2000-06-25 19:46 ` Re: How to use question mark in query thru ODBC from Windows Byron Nikolaidis <byron.nikolaidis@home.com>
0 siblings, 1 reply; 2+ messages in thread
From: Kari Lempiainen @ 2000-06-24 18:47 UTC (permalink / raw)
To: pgsql-interfaces
I'm using ODBC-interface in Windows 200 to access data from PostgreSQL
database in Linux box. My query is like:
select id from records where name = 'How are you?'
I get errors from the ODBC:
SQLExecDirect: SQL Error: 1
SQL State: S1000
Error string: Error while executing the query;
ERROR: Unterminated quoted string
I've analyzed the problem to be the question mark. ODBC thinks that
I'm using ? as a parameter marker, which obviously isn't the problem.
I've tried replacing ? with \? with no success (like I have to use \'
instead of '). What can I do to get the question mark go thru driver?
Cheers,
Kari
^ permalink raw reply [nested|flat] 2+ messages in thread
* Re: How to use question mark in query thru ODBC from Windows
2000-06-24 18:47 How to use question mark in query thru ODBC from Windows Kari Lempiainen <kari@funky.pp.fi>
@ 2000-06-25 19:46 ` Byron Nikolaidis <byron.nikolaidis@home.com>
0 siblings, 0 replies; 2+ messages in thread
From: Byron Nikolaidis @ 2000-06-25 19:46 UTC (permalink / raw)
To: Kari Lempiainen <kari@funky.pp.fi>; pgsql-interfaces
Use single quotes around the question mark. All literal strings require
single quotes.
Byron
----- Original Message -----
From: Kari Lempiainen <kari@funky.pp.fi>
To: <pgsql-interfaces@postgresql.org>
Sent: Saturday, June 24, 2000 2:47 PM
Subject: [INTERFACES] How to use question mark in query thru ODBC from
Windows
> I'm using ODBC-interface in Windows 200 to access data from PostgreSQL
> database in Linux box. My query is like:
> select id from records where name = 'How are you?'
>
> I get errors from the ODBC:
> SQLExecDirect: SQL Error: 1
> SQL State: S1000
> Error string: Error while executing the query;
> ERROR: Unterminated quoted string
>
> I've analyzed the problem to be the question mark. ODBC thinks that
> I'm using ? as a parameter marker, which obviously isn't the problem.
> I've tried replacing ? with \? with no success (like I have to use \'
> instead of '). What can I do to get the question mark go thru driver?
>
> Cheers,
>
> Kari
^ permalink raw reply [nested|flat] 2+ messages in thread
end of thread, other threads:[~2000-06-25 19:46 UTC | newest]
Thread overview: 2+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2000-06-24 18:47 How to use question mark in query thru ODBC from Windows Kari Lempiainen <kari@funky.pp.fi>
2000-06-25 19:46 ` Byron Nikolaidis <byron.nikolaidis@home.com>
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox