Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Data retreaving for LRAW data type

Former Member
0 Likes
2,328

Hi Guys,

I would like to retreave CLUSTD Field from the table STXL. but the field is in LRAW type. When i am trying to retreaving it th eoutput is all ZERO's. Below is my code. Can u chk and help me on this.

REPORT ZFUNTEST.

DATA: V_C(7902) TYPE C. "STXLDUMMY2. "STXL-CLUSTD.

*DATA: CLUSTD TYPE STXLDUMMY2.

SELECT SINGLE CLUSTD FROM STXL INTO V_C

WHERE TDOBJECT = 'CRM_ORDERH'

AND TDID = 'S001'

AND TDNAME = '45F0E182C5EE27B6E1000000AC100217'.

IF SY-SUBRC = 0.

write:/ v_c

endif.

In v_c the output is Zeros. But in table TSXL for the field CLUSTD value is there. How can i retreace LRAW data.

If helpfull reward points will be given.

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
1,388

hi hifrom, can you try type Xstring for ur variable v_C. thanks!

hi hifrom, can you try type Xstring for ur variable v_C. thanks!

6 REPLIES 6
Read only

Former Member
0 Likes
1,389

hi hifrom, can you try type Xstring for ur variable v_C. thanks!

Read only

0 Likes
1,388

Yes, i have tried like that also. But output is same asd zero's.

Read only

0 Likes
1,388

.hi,

i tried this code and it displayed clustd

DATA: V_C TYPE X. "STXLDUMMY2. "STXL-CLUSTD.

data: v_st type standard table of stxl with header line.

*DATA: CLUSTD TYPE STXLDUMMY2.

SELECT * FROM STXL INTO table V_st up to 10 rows.

*WHERE TDOBJECT = 'CRM_ORDERH'

*AND TDID = 'S001'.

IF SY-SUBRC = 0.

read table v_st index 3. " just to make sure to read not zero entries from debuging

write:/ v_st-clustd.

endif.

> be sure what you retrieved really has a value, and maybe you can referenced it to the data type of clustd.

thanks

Read only

0 Likes
1,388

Thank u very much. U r obselutely right. Code is working fine.

And points also rewarded.

Read only

0 Likes
1,388

Hi, But when i am using where condition again the output is ZERO;s canu plz chk it. I need where cindition.

Read only

Former Member
0 Likes
1,388

HI

Instead of only one field you should take wa as table

DATA: V_C TYPE STXL.

and

SELECT SINGLE * FROM STXL INTO corresponding fields of V_C

WHERE TDOBJECT = 'CRM_ORDERH'

AND TDID = 'S001'

AND TDNAME = '45F0E182C5EE27B6E1000000AC100217'.

Regards

Yossi