Assuming that column MY_TABLE.MY_NUMERIC_FIELD allows NULLs:
INSERT INTO MY_TABLE (MY_NUMERIC_FIELD, MY_OTHER_FIELD) VALUES ('',
'some_other_value')
will insert a 0 into the column MY_NUMERIC_FIELD in MySQL and many other
databases.
To insert NULL, the SQL must read
INSERT INTO MY_TABLE (MY_NUME
all.
>
> Kirk
>
>> -Original Message-
>> From: Michael Conley [mailto:[EMAIL PROTECTED]]
>> Sent: Thursday, March 15, 2001 1:01 PM
>> To: 'Chris Lee'; [EMAIL PROTECTED]
>> Subject: RE: [PHP] Variable value doesn't stay "Null"
>&g
The default value is null in the database.
-Original Message-
From: Johnson, Kirk [mailto:[EMAIL PROTECTED]]
Sent: Thursday, March 15, 2001 12:20 PM
To: [EMAIL PROTECTED]
Subject: RE: [PHP] Variable value doesn't stay "Null"
You may want to check the field definitions
t; From: Michael Conley [mailto:[EMAIL PROTECTED]]
> Sent: Thursday, March 15, 2001 1:01 PM
> To: 'Chris Lee'; [EMAIL PROTECTED]
> Subject: RE: [PHP] Variable value doesn't stay "Null"
>
>
> So how do I get the PHP script that stores the information in
;s for the fields that are not filled
in.
-Original Message-
From: Chris Lee [mailto:[EMAIL PROTECTED]]
Sent: Thursday, March 15, 2001 8:17 AM
To: [EMAIL PROTECTED]
Subject: Re: [PHP] Variable value doesn't stay "Null"
null is a bad idea. if a value is set to null in a ta
null is a bad idea. if a value is set to null in a table then that variable will not
be set.
namephonefaxemail
chris lee37710955541120NULL
$result['name'] is 'chris lee'
$result['phone'] is '3771095';
$result['fax'] is '5541120';
$result['email'] is an un
I put up an HTML page that allows a user to modify some previously entered
information. The information is taken from a MySQL database and displayed
on the page. The user can leave the data alone or modify it. If there is
no information in the database for one of the fields, the input box is
em
7 matches
Mail list logo