cancel
Showing results for 
Search instead for 
Did you mean: 

General error;339 invalid number: [6930] attribute value is not a number

arsalkhan909
Explorer
0 Kudos

Hey Experts!

I am seeking assitantance against the provided error:

1). [SAP AG][LIBODBCHDB DLL][HDBODBC] General error;339 invalid number: [6930] attribute value is not a number;exception 70006930: attribute value is not a number;[here]int 'Received Alerts' (OAIB) ("BaseRef"), BaseRef = ''[string] ,Exception in executor plan815464@sapb1:30203 while

The above mentioned error is produced when this query is applied:

SELECT

a."DocEntry",

a."DocNum",

(SELECT MAX(x."LineTotal") FROM "INV1" x WHERE INT(x."BaseRef")= INT(a."DocNum") AND b."ItemCode" = x."ItemCode" AND b."LineNum" = x."LineNum") AS "LineTotal",

b."ItemCode",

d."ItemName",

f."ItmsGrpNam",

b."LineNum",

a."ObjType",

a."DocDate",

b."Quantity" AS "qty",

COALESCE(b."U_Ctn", 0) AS "U_ctn",

d."U_Main_Category"

FROM

"ODLN" a

INNER JOIN

"DLN1" b ON a."DocEntry" = b."DocEntry"

INNER JOIN

"OITM" d ON b."ItemCode" = d."ItemCode"

INNER JOIN

"OITB" f ON d."ItmsGrpCod" = f."ItmsGrpCod"

WHERE

a."CANCELED" = 'N' AND b."ItemCode" NOT LIKE 'WST%'

It would be great if you guys could help me resolve this issue.

Looking forward to some great solutions.

Accepted Solutions (0)

Answers (2)

Answers (2)

DellSC
Active Contributor
0 Kudos

Does the full query run in Hana Studio? That would be the best place to debug it - Crystal is only passing along the error from the database.

Also, does the Hana INT function work with null values? Does your BaseRef field contain text other than numbers? What are the data types of BaseRef and DocNum? If they're not the same data type, you'll need to convert one to match the data type of the other. For example, if DocNum is an integer and BaseRef is a string, you'll want to convert DocNum to a string before comparing it to BaseRef. That would eliminate the issue if there is non-numeric text in BaseRef.

-Dell

zsolt_zoldi
Advisor
Advisor
0 Kudos

Hello,

Based on the error message a number was expected but string was found.

It happened at column BaseRef of table INV1.

In the internal select statement it was converted to INT but it seems there are some values in that column that cannot be converted to integers.
Please check the values in that column in more detail.

I hope it helps.

Best Regards,
Zsolt

arsalkhan909
Explorer
0 Kudos

Sorry the actual Query of "LineTotal" is below: and it shows that above error

(SELECT MAX(x."LineTotal") FROM "INV1" x WHERE x."BaseRef"= a."DocNum" AND b."ItemCode" = x."ItemCode" AND b."LineNum" = x."LineNum") AS "LineTotal"