Re: ERROR: unterminated quoted string... help - Mailing list pgsql-sql

From Scott Marlowe
Subject Re: ERROR: unterminated quoted string... help
Date
Msg-id 1116354432.22291.136.camel@state.g2switchworks.com
Whole thread Raw
In response to ERROR: unterminated quoted string... help  (Postgres Admin <postgres@productivitymedia.com>)
Responses Re: ERROR: unterminated quoted string... help  (Postgres Admin <postgres@productivitymedia.com>)
List pgsql-sql
On Tue, 2005-05-17 at 13:15, Postgres Admin wrote:
> Hi
>
> I'm trying to insert encrypted data into the database and I'm noticing
> error dealing with quotes. Below is the error print out...
>
> suggestions and/or at least point me in the direction to find a solution,
>
> Thanks,
> J
>
>
>
> INSERT INTO sample.users (user_name, first_name) VALUES
> ('jokers', '=ïµiF!¶6(ÖŸã¾óˆÌ‘'-Iw‰iDÖiJÐÿ† %')
>
> Warning: pg_query() [function.pg-query]: Query failed: ERROR:
> unterminated quoted string at or near "'=ïµi" at character 68 in
> /usr/local/apache2/htdocs/php/5/Theirry_DB.php on line 162

Use a bytea field and use pg_escape_bytea() to prepare the data for
insertion.


pgsql-sql by date:

Previous
From: Jay Parker
Date:
Subject: Re: triggering an external action
Next
From: Postgres Admin
Date:
Subject: Re: ERROR: unterminated quoted string... help