Skip to Content
author's profile photo Former Member
Former Member

how to code this using FIELD SYMBOL ?

Hello All,

I never used field symbols before and I think this is where I should use field symbols in my program.

I have a selection parameter period (p_period) and based on the p_period value(XX), I need to display the HSLXX, KSLXX from table GLT0 using field symbols. Can anyboby help me?

Thanks,

Chandni Reddy

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

2 Answers

  • Best Answer
    Posted on Sep 28, 2006 at 07:10 PM

    Right, you can use field-symbols, here is a example.

    
    report zrich_0002.
    
    data: xGLT0  type  GLT0 .
    
    data: field_name(20) type c.
    
    field-symbols: <fs> .
    
    parameters: p_per(2) type n.
    
    
    * Read a line from table
    select Single * from glt0 into xglt0.
    
    * Build the field name that you want to access
    concatenate 'XGLT0-HSL' p_per into field_name.
    
    * Assign it
    assign (field_name) to <fs>.
    
    * Write it
    write:/ <fs>.
    
    

    Regards,

    Rich Heilman

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Sep 28, 2006 at 07:12 PM

    Hi,

    data: var type string.

    field-symbols: <fs>.

    CONCATENATE 'GLT0-HSL' p_period into var.

    ASSIGN (VAR) to <FS>.

    WRITE: / <FS>.

    Thanks,

    Naren

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.