Re: [PHP-DB] Inserting NULL values does not work

2002-02-02 Thread Andrés Felipe Hernández
] Subject: [PHP-DB] Inserting NULL values does not work Hi guys, I am trying to insert a NULL value into a DB field. The value is not always NULL so the statement is given. Unfortunatelly it is inserting 0 instead of NULL. How can I get the thing going with NULL??? Here

[PHP-DB] Inserting NULL values does not work

2002-02-01 Thread Andy
Hi guys, I am trying to insert a NULL value into a DB field. The value is not always NULL so the statement is given. Unfortunatelly it is inserting 0 instead of NULL. How can I get the thing going with NULL??? Here is the code I am using: if ($park == 'false'){ $park = NULL; } $stmt =

RE: [PHP-DB] Inserting NULL values does not work

2002-02-01 Thread Rick Emery
'){ $park = NULL; } else{ $park = \$park\; }; in you INSERT statement change: '$park',to $park, -Original Message- From: Andy [mailto:[EMAIL PROTECTED]] Sent: Friday, February 01, 2002 9:43 AM To: [EMAIL PROTECTED] Subject: [PHP-DB] Inserting NULL values does not work Hi guys, I am

Re: [PHP-DB] Inserting NULL values does not work

2002-02-01 Thread Oliver Cronk
{ $park = \$park\; }; in you INSERT statement change: '$park',to $park, -Original Message- From: Andy [mailto:[EMAIL PROTECTED]] Sent: Friday, February 01, 2002 9:43 AM To: [EMAIL PROTECTED] Subject: [PHP-DB] Inserting NULL values does not work Hi guys, I am trying to insert

RE: [PHP-DB] Inserting NULL values does not work

2002-02-01 Thread Rick Emery
It's not failing on the single-quotes. MYSQL can use single-quotes. -Original Message- From: Oliver Cronk [mailto:[EMAIL PROTECTED]] Sent: Friday, February 01, 2002 10:01 AM To: Php-Db ML; [EMAIL PROTECTED] Subject: Re: [PHP-DB] Inserting NULL values does not work Why not make

RE: [PHP-DB] Inserting NULL values does not work

2002-02-01 Thread Oliver Cronk
Like this for example: http://www.phpbuilder.com/snippet/download.php?type=snippetid=378 -Original Message- From: Oliver Cronk [mailto:[EMAIL PROTECTED]] Sent: 01 February 2002 16:01 To: Php-Db ML; [EMAIL PROTECTED] Subject: Re: [PHP-DB] Inserting NULL values does not work Why

RE: [PHP-DB] Inserting NULL values does not work

2002-02-01 Thread Oliver Cronk
: [PHP-DB] Inserting NULL values does not work It's not failing on the single-quotes. MYSQL can use single-quotes. -Original Message- From: Oliver Cronk [mailto:[EMAIL PROTECTED]] Sent: Friday, February 01, 2002 10:01 AM To: Php-Db ML; [EMAIL PROTECTED] Subject: Re: [PHP-DB] Inserting NULL

RE: [PHP-DB] Inserting NULL values does not work

2002-02-01 Thread Rick Emery
PROTECTED]'; Php-Db ML Subject: RE: [PHP-DB] Inserting NULL values does not work It's not failing on the single-quotes. MYSQL can use single-quotes. -Original Message- From: Oliver Cronk [mailto:[EMAIL PROTECTED]] Sent: Friday, February 01, 2002 10:01 AM To: Php-Db ML; [EMAIL PROTECTED

Re: [PHP-DB] Inserting NULL values does not work

2002-02-01 Thread Oliver Cronk
:[EMAIL PROTECTED]] Sent: Friday, February 01, 2002 10:41 AM To: Rick Emery; [EMAIL PROTECTED]; Php-Db ML Subject: RE: [PHP-DB] Inserting NULL values does not work I know its not failing on YOUR example but if there is a single quote in the data eg someones name is O'leary then the SQL will fail