Results 1 to 8 of 8
  1. #1
    New Lounger
    Join Date
    Jan 2003
    Posts
    10
    Thanks
    0
    Thanked 0 Times in 0 Posts

    export problem- invalid use of null (2000/sp4)

    I've been attempting to export queries to a .txt file, and have been getting this message repeatedly. Advised to convert any nen text fields using cstr(), cdbl(), cInt(), but am still running into this problem. The faulty fields are filled with a '#error' value. Any suggestions?

    thanks

  2. #2
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: export problem- invalid use of null (2000/sp4)

    Using CStr, CDbl etc. is precisely what you shouldn't do! All these conversion functions return #Error for Null arguments. You shouldn't have problems if you don't use these functions - null values will be exported to blanks.

  3. #3
    New Lounger
    Join Date
    Jan 2003
    Posts
    10
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: export problem- invalid use of null (2000/sp4)

    thanks HansV- this would be great except for invalid argument errors w.o. the conversions. Should I resort to other formatting functions?

    thanks again

  4. #4
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: export problem- invalid use of null (2000/sp4)

    You'll have to provide some details; "invalid argument errors" is not enough to be able to give advice.

  5. #5
    New Lounger
    Join Date
    Jan 2003
    Posts
    10
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: export problem- invalid use of null (2000/sp4)

    yup, which is why i'm at a loss. that's literally all it says, "invalid argument".

  6. #6
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: export problem- invalid use of null (2000/sp4)

    Perhaps you could give us some details about the query and the underlying tables. For instance, what is the SQL of the query, what kind of fields are involved?

  7. #7
    New Lounger
    Join Date
    Jan 2003
    Posts
    10
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: export problem- invalid use of null (2000/sp4)

    alright, these are really simple queries, I don't even know the 1st thing about sql- straight access queries pulling for date format and numeric fields. Everything's entered into cells as criteria for records selection, not as code. Not sure if this is relevant, but the queries themselves run within 5 minutes, the export procedure itself about an hour. Is this a bad sign?

    thanks Hans

  8. #8
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: export problem- invalid use of null (2000/sp4)

    It is unusual, but it depends on the complexity of the queries, the size of the tables, the speed of the PC, the available memory, etc.

    If you open a query in design view, you can select View | SQL to see the SQL statement of the query. You can copy this to the clipboard (Ctrl+C) and paste it into a reply in this thread (Ctrl+V).

    If you are not willing or able to provide any details, we won't be able to help you.

Posting Permissions

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