Negative Number in Query Incorrect When Returned to WorksheetLast reviewed: September 12, 1996Article ID: Q117313 |
The information in this article applies to:
SYMPTOMSIn Microsoft Excel, when you return data from a query in Microsoft Query, negative numbers are returned as positive numbers. For example, the value - 1 in Microsoft Query is returned as 65535, the value -2 is returned as 65534, and so on.
CAUSEThis error occurs when you return data from a column of field type TINYINT or SMALLINT (SQL table), or SHORT (Paradox table). The error occurs because Microsoft Excel assumes these INT data types are unsigned, but Microsoft Query assumes they are signed. You cannot return negative numbers in Microsoft Excel from columns of type TINYINT, SMALLINT, or SHORT.
WORKAROUNDSTo return negative values from Microsoft Query to a Microsoft Excel worksheet, do either of the following:
STATUSMicrosoft has confirmed this to be a problem in the Microsoft products listed at the beginning of this article. This problem was corrected in Microsoft Excel version 5.0c for Windows.
MORE INFORMATIONIn Microsoft Excel, you can link to data in an external database by choosing Get External Data from the Data menu. This command starts Microsoft Query, and allows you to use a data source to build a query. You can then choose the Return Data To Microsoft Excel command on the File menu in Microsoft Query to return the query data to your worksheet.
|
KBCategory: kbother
© 1998 Microsoft Corporation. All rights reserved. Terms of Use. |