Re: ENCLOSE QUOTE CHAR. IN SQL ?
From: Tim Shute <tshute_at_nisoft.co.uk>
Date: Wed, 29 Dec 1999 12:36:12 -0000
Message-ID: <32AA3B12B79DD311B0CB006097A4426B0AC519_at_ORION>
Date: Wed, 29 Dec 1999 12:36:12 -0000
Message-ID: <32AA3B12B79DD311B0CB006097A4426B0AC519_at_ORION>
Hi Joel,
Try this:-
select chr(39)|| table.refnbr || chr(39) from table;
HTH
-- Tim Shute Software Engineering Manager NiSoft (UK) Limited NiSoft House Ravenhill Business Park Ravenhill Road Belfast BT6 8AW UK www.nisoft.co.uk Joël Dessart <jocky_at_bigfoot.com> wrote in message news:3869C8D6.27ABBD6E_at_bigfoot.com...Received on Wed Dec 29 1999 - 13:36:12 CET
> Hi !
>
> I want to enclose the quote char before and
> after a reference number in a SQL statement.
>
> E.g. : ref. nbr= 0026121.07
> After SQL: '0026121.07'
>
> How could I do this in script since something
> like: select ''' || table.refnbr || ''' from table;
> does not work ?
>
> Is there a mean to say that the quote must be
> kept as character and not as limit of an
> explicit string in this query (kind of ESCAPE char
> for LIKE operator...) ?
>
> Thanks a lot !
>
> Joel
> mailto:jocky_at_bigfoot.com