Results 1 to 3 of 3

Thread: Invalid use of null

  1. #1

    Thread Starter
    Addicted Member
    Join Date
    May 1999
    Posts
    161

    Question

    Looping through an ADO recordset, I get an Invalid use of null error when I try to add Null to an integer.

    Anyone know of a clean way to go around that ? I'd like to avoid If-Then-Else if possible.

    Thanks...

  2. #2
    _______ HeSaidJoe's Avatar
    Join Date
    Jun 1999
    Location
    Canada
    Posts
    3,946
    "A myth is not the succession of individual images,
    but an integerated meaningful entity,
    reflecting a distinct aspect of the real world."

    ___ Adolf Jensen

  3. #3

    Thread Starter
    Addicted Member
    Join Date
    May 1999
    Posts
    161

    Lightbulb Oracle solution

    Thank you !

    I also found a solution directly in the query I make. Here it is if anyone is interested...

    I am using an Oracle database and can use the nvl function. In the select statement, instead of doing: select field_1 from... you can do: select nvl(field_1,0) from...

    What this does is replace all instances of null values in that field by a 0, and that solves my problem...

Posting Permissions

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



Click Here to Expand Forum to Full Width