Skip to Content
avatar image
Former Member

how to convert streaming data type on SDS?

Hi experts,

I have tried to insert streaming data by using SDS.

When I have converted String type to Decimal type on SDS through WebSocket, error occurred.

I wrote “to_decimal ( to_integer ( SENSORDATA.SENSOR_VALUE ) , 6 , 0 )”.

When SENSORDATA.SENSOR_VALUE is “1” , its OK.

When SENSORDATA.SENSOR_VALUE is “0” , the error occurs on SDS as follows:

----

[27005]{-1}[-1/-1] 2016-10-26 09:20:51.179000 e Streaming UNKNOWN : [SP-3-148015] (23.367) sp(26931) ConnectionWriter(JoinData) error writing to Connection(HANA_Output1): 2016-10-26 09:20:51 An error occurred when setting the value for a decimal database column. Table: IOT.T_SENSOR_VAL_SECOND; Column: SENSOR_VAL_DECIMAL; Original error code: -1.. 1 records posted, 1 processed, 1 bad, 0 good.

----

Regards,

---Added informations

Hi Masayuki,

Thank you for your response.

I attache the files when I found the error.

socket2dbadapterccrfile.txt

socket2dbadapterccxfile.txt

* I wrote the code on text file sinse I couldn't attache the ccr file and ccx file.

Regards,

Marie Moro

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

3 Answers

  • avatar image
    Former Member
    Oct 29, 2016 at 08:07 PM

    I'm sorry,

    I attache the files again.

    socket2dbadapterccrfile.txt

    socket2dbadapterccxfile.txt

    Regards,

    Marie Moro

    Add comment
    10|10000 characters needed characters exceeded

  • Nov 07, 2016 at 03:49 AM

    Hi Marie,

    You can create a customer incident, if it is a bug.

    Is there anyway for adding a workaround code to skip the issue if the value is 0?

    Regards,

    Masa / SAP Technology RIG

    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    Nov 08, 2016 at 11:24 AM

    Hi Masayuki,

    Thank you for your response.

    I understand that you said.

    In terms of how to skip the issue, I have tried the code as follows, but it couldn't skip the issue:

    case when SENSORDATA.SENSOR_VAL_CHAR = '0' then 0 else to_decimal(to_integer(SENSORDATA.SENSOR_VAL_CHAR), 6, 0)) end

    When I input JoinData to File/Hadoop CSV Output, "0" was output. So with JoinData, we could insert "0" as decimal value.

    But, with Hana Output, if we insert "0", it would call the error...

    If you have any idea, I would like you to give us your advice.

    Sorry to bother you again.

    Regards,

    Marie Moro

    Add comment
    10|10000 characters needed characters exceeded