[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: when I insert table, value is a string contains apostrophe - it throws an error there - how to fix
- From: Dirk Feytons <dirk.feytons@...>
- Date: Wed, 3 Feb 2010 14:22:21 +0100
On Wed, Feb 3, 2010 at 2:09 PM, Florian Weimer <fw@deneb.enyo.de> wrote:
> * Vasanta:
>
>> *When I do INSERT like below, value is a string with apastrophe (for ex:
>> "Checking for 'hlt' instruction"), insert throws an error - how to fix?*
>
> Most SQL database access layers contain functionality which allows you
> to separate data from the query. You should simply use that, and
> these problems go away.
And you are protected from SQL injection attacks when using prepared
statements...
--
Dirk