on 2020 Jul 17 3:38 AM
Hello all,
I created a simple XSJSLIB with oData custom exit in HANA XS Classic and write a code to insert the date into database.
Date type in table is defined as:
{name = "CREATTION_DATE"; sqlType = DATE; comment = "Creation Date- YYYYMMDD";},
Here is the code in XSJSLIB:
query = "INSERT INTO \"COMMON\".\"PROD.TEST.TABLE::TEST\" (DATE) VALUES(DATE) ";
pStmt = param.connection.prepareStatement(query);
pStmt.setString(1, '2020-07-16');
pStmt.executeUpdate();
pStmt.close();
I am getting this error :
Create Entity failed: :Service exception: [2] InternalError: dberror(setString): 339 - invalid number: not a valid number string '2020-07-16' (line 73 position 1 in /TEST_SUBMITDATA.xsjslib)
Any idea how to fix it? Appreciate.
User | Count |
---|---|
68 | |
8 | |
8 | |
6 | |
6 | |
6 | |
6 | |
6 | |
5 | |
5 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.