What DataColumn.DataType do each of the SQL types map to?

Discussion in 'Microsoft ASP .NET' started by Nathan Sokalski, Dec 24, 2007.

  1. When a DataTable is filled using something such as a DataAdapter, what
    values are assigned to each of the DataColumns' DataType property for the
    different SQL types? Thanks.
    --
    Nathan Sokalski

    http://www.nathansokalski.com/
     
    Nathan Sokalski, Dec 24, 2007
    #1
    1. Advertisements

  2. Nathan Sokalski

    Guest Guest

    Hi,

    the .NET data types are asigned, because if you load data by adapter,
    it's all loaded to an ordinary DataTable, so int is converted to
    System.Int32, char, varchar and text are converted to string, bit to bool
    and so on.

    Regards,

    Lukas Holota

    "Nathan Sokalski" <> wrote in message
    news:...
    > When a DataTable is filled using something such as a DataAdapter, what
    > values are assigned to each of the DataColumns' DataType property for the
    > different SQL types? Thanks.
    > --
    > Nathan Sokalski
    >
    > http://www.nathansokalski.com/
    >
     
    Guest, Dec 26, 2007
    #2
    1. Advertisements

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Matt Mercer

    Re: Search SQL image datatype

    Matt Mercer, Sep 22, 2004, in forum: Microsoft ASP .NET
    Replies:
    4
    Views:
    327
    Steve C. Orr [MVP, MCSD]
    Sep 22, 2004
  2. Replies:
    1
    Views:
    368
    =?iso-8859-1?Q?Guillermo_Gonz=E1lez_A.?=
    Jul 21, 2005
  3. Textarea to sql 2000 text datatype

    , Aug 17, 2005, in forum: Microsoft ASP .NET
    Replies:
    2
    Views:
    242
  4. Jay Balapa

    Check to see DataColumn DataType is Boolean?

    Jay Balapa, May 3, 2006, in forum: Microsoft ASP .NET
    Replies:
    1
    Views:
    234
    Bjorn Abelli
    May 4, 2006
  5. Jeff

    database datatype bit what is the C# datatype?

    Jeff, Apr 16, 2007, in forum: Microsoft ASP .NET
    Replies:
    2
    Views:
    864
    Steve C. Orr [MCSD, MVP, CSM, ASP Insider]
    Apr 16, 2007
Loading...

Share This Page