I just migrated my SQL server from MSSQL 2005 to 2008 and now DBI::ODBC is returning all the INTs as decimals! Even boolean columns that used to return just 1 or 0, now return 0.00. Just the data moved; the server running the scripts hasn't changed since the move, aside from me pointing my DBI connections to the new server, literally only updating the "Server=oldserver;" to "Server=newserver". Both of my servers are Windows Server 64 2008.

When I get back a result with an ID (primary key) it will respond with "15.00" instead of "15", for example. This makes using that number in hundreds of already written and previously working queries not work at all.

Perl is using: "dbi:ODBC:Driver={SQL Server};" as the connection string to talk to the server and PHP is using "Driver={SQL Server};". PHP seems to be doing it too.

Any DBI or ODBC expert super monks out there who could shed light on why this is happening now and never before? Maybe a tip or configuration change that may fix it?

Solved, See reply below.


In reply to Need DBI/ODBC advice. by Brak

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.