Results 1 to 2 of 2

Thread: ADO guru question: different datatypes in same column?

  1. #1
    Guest

    Talking

    Hi there all ye

    I have an Excel spreadsheet with different datatypes in the same column i.e.
    numeric values like 123 456.789
    string values like "abc"
    date values like 2001-01-01
    etc.

    When I create a ADODB.recorset from this spreadsheet all
    values with different datatype from the data type of the
    value in the second row is set to NULL. (First row defines
    column names.)

    This sucks.

    I can get around it by making all data into strings by
    adding a ' before the actual data on the the spreadsheet.
    I can then convert the data back with VB to whatever
    type it is supposed to be. However, this is not a very neat
    solution since the spreadsheet will be less user friendly.

    So my question is:
    Is it possible to create a ADODB.recordset form an Excel
    spreadsheet with different datatypes in the same column
    without data beeing converted to NULL values?

    If so - how do you do it?

    Thanks heaps to anyone who can help me.

    /JT

  2. #2
    Guest

    Smile

    Just a thought

    Since all data types in VB Script is variants, is it
    possible to do it with an ADOBD.recorset created from an
    asp page?

    /JT

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