none
Invalid data for type "numeric" on link Server with Oracle

    Question

  • Hi,

    i had created a link server with oracle using "Oracle provider for OLE DB". i  am running a simple Select * from table x  statement which gives me error "Invalid data for type "numeric" . Any idea why. same statement when i am running in Oracle PL/SQL its running fine.

    Thanks and TC

    Sunday, May 25, 2014 8:10 AM

Answers

  • Hello,

    The error occurs due to numeric precision or numeric definition mismatch. Please refer to the following query to workaround this issue:

    select Convert(Int, numID) as numID
    from   Openquery(LinkedServer, 'select To_Char(numID) as numID from OracleTable');

    Regards,
    Fanny Liu


    Fanny Liu
    TechNet Community Support

    Monday, May 26, 2014 9:46 AM