INSERT INTO: string with apostrophe

From: Rich Shepard <rshepard(at)appl-ecosys(dot)com>
To: pgsql-general(at)postgresql(dot)org
Subject: INSERT INTO: string with apostrophe
Date: 2017-06-29 20:05:06
Message-ID: alpine.LNX.2.11.1706291259071.846@localhost
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

The syntax for inserting data into a table uses single quotes to identify
strings. When I have a string such as O'Brien do I double the single quotes
within the string (i.e., 'O''Brien') or is there another way to include such
strings?

Rich

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Devrim Gündüz 2017-06-29 20:13:48 Re: Download 9.6.3 Binaries
Previous Message Ilya Roublev 2017-06-29 20:03:59 Connecting matlab with postgresql