Convert double to varchar

  • I need to convert one old order table tOld to new table tNew.

    There is a column [OrderID] (data type is double) need to convert to varchar.

    I used code below but never work. Please help.

    SELECT cast(OrderID as varchar(20)) FROM tOld

    Result:

    9.30149e+007

    6.02773e+006

    5.36782e+008

  • adonetok (3/16/2012)There is a column [OrderID] (data type is double)

    ?

  • please post the table definition and a couple of sample data rows

Viewing 3 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic. Login to reply