Results 1 to 4 of 4

Thread: How to insert null

  1. #1
    Harish Guest

    How to insert null

    How can we insert the null vales into the table..?
    insert into test (4,NULL)
    or
    insert into test (4,'&#39

    is this the right format..?

  2. #2
    Guest

    How to insert null (reply)

    first one is correct.

    ------------
    Harish at 9/20/01 2:44:58 PM

    How can we insert the null vales into the table..?
    insert into test (4,NULL)
    or
    insert into test (4,'&#39

    is this the right format..?

  3. #3
    venkat Guest

    How to insert null (reply)


    I think second one is right



    ------------
    Harish at 9/20/01 2:44:58 PM

    How can we insert the null vales into the table..?
    insert into test (4,NULL)
    or
    insert into test (4,'&#39

    is this the right format..?

  4. #4
    Yads Guest

    How to insert null (reply)

    Dear venkat

    Second one will insert a empty string. (empty string is not a null value)

    try the following thing:

    create table test1 (
    col1 char(5) null
    )
    insert test1 values('&#39
    insert test1 values(null)
    insert test1 values('1&#39

    select * from test1 where col1 is null

    Thanks
    Yads


    ------------
    venkat at 10/12/01 7:45:20 PM


    I think second one is right



    ------------
    Harish at 9/20/01 2:44:58 PM

    How can we insert the null vales into the table..?
    insert into test (4,NULL)
    or
    insert into test (4,'&#39

    is this the right format..?

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •