cancel
Showing results for 
Search instead for 
Did you mean: 

EXEC SQL with SELECT long field

patty_1982
Contributor
0 Kudos

HI

I have a external oracle table with a type LONG field. I read this table with dblink.

I declared my sap variable type STRING:

DATA v_test TYPE STRING.

EXEC SQL.

SELECT test_long

into :v_test

FROM srvweb.test@mag

where id_name = '0'

ENDEXEC.

Test_long is 39000 characters for example, but my variable v_test is truncated (32000 characters)!

Why? How can I resolve this problem? I can't use TYPE C because it support only from 1 to 65535 characters.

Thank you

Accepted Solutions (0)

Answers (2)

Answers (2)

volker_borowski2
Active Contributor
0 Kudos

Hi,

I think LONG was always messy.

Can you create a view which converts the LONG to CLOB

(View might be either remote or local)

and see if selecting the view then changes anything?

Volker

patty_1982
Contributor
0 Kudos

CLOB is not supported by DBLink

Thanks

Patrizia

stefan_koehler
Active Contributor
0 Kudos

Hello Patrizia,

just an idea: http://help.sap.com/abapdocu_70/en/ABENBUILT_IN_TYPES_COMPLETE.htm

The predefined data types string and xstring describe data objects of variable length (dynamic data objects). While the length of data objects in all other elementary data types is determined for its whole lifetime, the length of text and byte strings varies according to their content (the maximum size of a string is determined by profile parameter ztta/max_memreq_MB, see Maximum size of dynamic data objects).

Regards

Stefan

patty_1982
Contributor
0 Kudos

Thank you!