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

how to include header name for the fields in application server

Former Member
0 Likes
1,002

Hiiii Experts,

LOOP AT fp_i_wwcmp INTO fp_wa_wwcmp.

CONCATENATE fp_wa_wwcmp-pernr

fp_wa_wwcmp-etype

fp_wa_wwcmp-maxbt

fp_wa_wwcmp-epayperiod

fp_wa_wwcmp-currencyid

INTO l_v_data SEPARATED BY l_v_char_tab.

i need to insert header names for etype,maxbt,epayperiod,currencyid which are needed to be transfer to application server.

regards,

kasyap

Edited by: Harish Kasyap on Sep 18, 2009 2:49 PM

Hiiii Experts,

LOOP AT fp_i_wwcmp INTO fp_wa_wwcmp.

CONCATENATE fp_wa_wwcmp-pernr

fp_wa_wwcmp-etype

fp_wa_wwcmp-maxbt

fp_wa_wwcmp-epayperiod

fp_wa_wwcmp-currencyid

INTO l_v_data SEPARATED BY l_v_char_tab.

i need to insert header names for etype,maxbt,epayperiod,currencyid which are needed to be transfer to application server.

regards,

kasyap

Edited by: Harish Kasyap on Sep 18, 2009 2:49 PM

5 REPLIES 5
Read only

Clemenss
Active Contributor
0 Likes
951

Hi Harish,

before outputting the tables contents, you can build a header line.

If your table is based on a dictionary structure, then it is easy: There are lots of DDIC function modules to retrieve this information. If your Data is displayed in ALV (always best solution before file creation), you can get all you need from the field catalog.

Concatenate this separated by CL_ABAP_CHAR_UTILITIES=>HORIZONTAL_TAB as you do with the data.

Append to output table first.

Regards,

Clemens

Read only

Former Member
0 Likes
951

hiiiii clemens thanks a lot for ur reply,

this is not an alv report,the output is directly transfered into application server AL11.

and i have used this statement

CONCATENATE 'ID'

'EpayType'

'EpayAmount'

'EpayPeriod'

'CurrencyID'

INTO l_v_data SEPARATED BY l_v_char_tab.

transfer l_V_data.

is this the rite one

regards,

kasyap

Read only

Former Member
0 Likes
951

Hai Harish,

I hope you are using OPEN dataset, TRANSFER and CLOSE DATASET to transfer data to application server.

after open data set statement Prepare the header you want to send and then transfer it using transfer statement.

once after transfering the header loop at the internal table whose contents are to be sent to file and then use the transfer statement.

I think the code you have given serves the purpose.

Regards,

Sravan

Read only

Former Member
0 Likes
951

hiii thanks for ur reply sravan,anyway i sorry ,i want in the format which i mentioned above ok

regards,

harish

Read only

Former Member
0 Likes
951

solved