Re: how to Escape single quotes with PreparedStatment

From: Chris Wareham <cwareham(at)londonandpartners(dot)com>
To: JavaNoobie <vivek(dot)mv(at)enzentech(dot)com>
Cc: <pgsql-jdbc(at)postgresql(dot)org>
Subject: Re: how to Escape single quotes with PreparedStatment
Date: 2011-08-22 10:32:48
Message-ID: 4E523050.10000@londonandpartners.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-jdbc

On 22/08/11 11:04, Chris Wareham wrote:
>
> stmt = con.prepareStatement(query);
>

Should of course be:

stmt = con.prepareStatement(query.toString());

Chris

In response to

Browse pgsql-jdbc by date

  From Date Subject
Next Message Chris Wareham 2011-08-22 10:35:19 Re: how to Escape single quotes with PreparedStatment
Previous Message JavaNoobie 2011-08-22 10:26:06 Re: how to Escape single quotes with PreparedStatment