Negative 2 Billion Error Code

Chippy 0 Reputation points
2024-08-13T18:06:01.0033333+00:00

billionec.PNG Hi, when working through SQL statements in Power Query I saw this error code pop up even when the actual error changed (ie syntax vs arithmetic error). I downloaded and searched through the Windows_Protocols error documentation, but it only goes up to 50,000 and mine is -2,146,232,060. Can't download SSMS or the SQL Checker as seen here (https://learn.microsoft.com/en-us/troubleshoot/sql/database-engine/connect/network-related-or-instance-specific-error-occurred-while-establishing-connection?view=sql-server-ver15)

I've attached a screenshot as well, danks.

SQL Server
SQL Server
A family of Microsoft relational database management and analysis systems for e-commerce, line-of-business, and data warehousing solutions.
13,861 questions
Transact-SQL
Transact-SQL
A Microsoft extension to the ANSI SQL language that includes procedural programming, local variables, and various support functions.
4,640 questions
{count} votes

2 answers

Sort by: Most helpful
  1. Erland Sommarskog 111.8K Reputation points MVP
    2024-08-13T21:23:32.5166667+00:00

    That negative error code looks like something that comes from the Windows/Excel side of things. The error number from SQL Server is 102 (Incorrect syntax.)

    I would just ignore that negative number.

    0 comments No comments

  2. LiHongMSFT-4306 27,101 Reputation points
    2024-08-14T01:25:21.0633333+00:00

    Hi @Chippy

    As the error message says, there is syntax error in your SQL statement.

    Try this modification:

    SELECT 
    AUFNR AS [Order Number],
    PLNBEZ AS [Material Number],
    GLTRP_SIMP_DT AS [Basic Finish Dat],
    GAMNG AS [Order Quantity]
    FROM bv.AFKO
    

    Best regards,

    Cosmog


    If the answer is the right solution, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".


Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.