freetds AT lists.ibiblio.org
Subject: FreeTDS Development Group
List archive
- From: Francis Smit <francis AT oztel.com>
- To: TDS Development Group <freetds AT franklin.oit.unc.edu>
- Subject: Re: Adding Strings with quote's in?
- Date: Sat, 12 Feb 2000 11:49:51 +1100
Karl Pielorz wrote:
> Hi All,
>
> OK - We've now got PHP + FreeTDS + SQL V7 to talk quite nicely to each
> other... The problem I'm stuck with now is how to insert the following text
> into a database field...
>
> The Wolve's are coming
>
> Obviously, an
>
> INSERT INTO test VALUES( 'The Wolve's are coming' );
you need to insert
INSERT INTO test VALUES( 'The Wolve''s are coming')
>
> Isn't going to cut it, so I used PHP's "AddSlashes" function, which does the
> equivalent of:
>
> INSERT INTO test VALUES( 'The Wolve\'s are coming' );
>
> Which it doesn't seem to like either...
there doesn't appear to be a function of this sort yet,
maybe if I find the time I'll write text2SQLServertext,
hopefully with a better name.
>
>
> Any suggestions? - Is there a problem doing this with FreeTDS? (We have
> another system running MySQL which I do manage to use AddSlashes to protect
> embedded quotes etc. in field data with)...
no this is a MS-SQL Server prob, or rather a prob with their SQL, I used to
get
this with ASP before I moved to PHP.
>
>
> Thanks,
>
> -Karl
>
> ---
> You are currently subscribed to freetds as: francis AT oztel.com
> To unsubscribe, forward this message to $subst('Email.Unsub')
--
Grisly . oo
`oO
Francis Smit
Knowledge By Design/OzTel
Suite 201, 683 George st
Sydney 2000 NSW
mailto:francis AT kbd.com.au
Tel: +61 2 9212 1399
Fax: +61 2 9212 5727
___________________________________
m$: How can we stuff you up today?
-
Adding Strings with quote's in?,
Karl Pielorz, 02/11/2000
- <Possible follow-up(s)>
- Re: Adding Strings with quote's in?, Mark Schaal, 02/11/2000
- Re: Adding Strings with quote's in?, Bob Kline, 02/11/2000
- Re: Adding Strings with quote's in?, Francis Smit, 02/11/2000
- Re: Adding Strings with quote's in?, Karl Pielorz, 02/12/2000
- Re: Adding Strings with quote's in?, brlewis, 02/14/2000
Archive powered by MHonArc 2.6.24.