Received: from mail.rdc1.md.home.com (imail@ha1.rdc1.md.home.com [24.2.2.66]) by hub.org (8.10.1/8.10.1) with ESMTP id e5PJnw146902 for ; Sun, 25 Jun 2000 15:49:58 -0400 (EDT) Received: from byron ([24.4.141.52]) by mail.rdc1.md.home.com (InterMail vM.4.01.02.00 201-229-116) with SMTP id <20000625194958.IHMQ26205.mail.rdc1.md.home.com@byron>; Sun, 25 Jun 2000 12:49:58 -0700 Message-ID: <000a01bfdede$174706e0$6401a8c0@byron> From: "Byron Nikolaidis" To: "Kari Lempiainen" , References: Subject: Re: How to use question mark in query thru ODBC from Windows Date: Sun, 25 Jun 2000 15:46:43 -0400 MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 5.00.2615.200 X-MimeOLE: Produced By Microsoft MimeOLE V5.00.2615.200 X-Archive-Number: 200006/99 Use single quotes around the question mark. All literal strings require single quotes. Byron ----- Original Message ----- From: Kari Lempiainen To: 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