Accessing a field from a structure with out header line

Hi Guys,
             I am trying to assign a field from a structure type line of data to another field.
This structure type line don't have a header line.
here is the example.
IT_EKKNU TYPE  MMPUR_EKKNU.
when I use following statement..
move IT_EKKNU-kostl to e_cekko-kostl.
Iam getting error "IT_ENKKNU is not a structure or Internal table with header line.
How to access the fields in structure IT_EKKNU.
Thank U for ur time.
Cheers
S Kumar

Here IT_EKKNU is an internal table without Header line.
You can use a structure for assignment.
DATA: IT_EKKNU TYPE MMPUR_EKKNU,
           wa_ekknu type    ekknu.
read table it_ekknu into wa_ekknu........
move wa_EKKNU-kostl to e_cekko-kostl.
*modify the code for your conditions*.

Similar Messages

  • Internal table with out header line

    Hi friends,
    Can u send me code for internal table with out header line : how to declare ,how to populate data and how to access the data
    Regards,
    vijay

    Hi Vijay
    There are several ways to declare an internal table without header line:
    A) You can define a type table
    TYPES: BEGIN OF TY_ITAB OCCURS 0,
            INCLUDE STRUCTURE ZTABLE.
    TYPES: END   OF TY_ITAB.
    and then your intrnal table:
    DATA: ITAB TYPE TY_ITAB.
    B) DATA: ITAB TYPE/LIKE STANDARD TABLE OF ZTABLE.
    C) DATA: ITAB TYPE/LIKE ZTABLE OCCURS 0.
    All these ways create a STANDARD TABLE
    You can create other types of internal table, for example SORTED TABLE or HASHED TABLE.
    These kinds of table can allow to improve the performance because they use different rules to read the data.
    When it wants to manage a table without header line, it need a work area, it has to have the same structure of table.
    DATA: WA LIKE ZTABLE.
    DATA: T_ZTABLE LIKE STANDARD TABLE OF ZTABLE.
    A) To insert the record:
    If you use INTO TABLE option you don't need workarea
    SELECT * FROM ZTABLE INTO TABLE T_ZTABLE
                                      WHERE FIELD1 = 'Z001'
                                        AND FIELD2 = '2006'.
    but if you want to append a single record:
    SELECT * FROM ZTABLE INTO wa WHERE FIELD1 = 'Z001'
                                   AND FIELD2 = '2006'.
    APPEND WA TO T_ZTABLE.
    ENDSELECT.
    Now you need workarea.
    B) To read data: you need always a workarea:
    LOOP AT T_ZTABLE INTO WA WHERE ....
      WRITE: / WA-FIELD1, WA-FIELD2, WA-FIELD3.
    ENDLOOP.
    or
    READ T_ZTABLE INTO WA WITH KEY FIELD3 = '0000000001'.
    IF SY-SUBRC = 0.
    WRITE: / WA-FIELD1, WA-FIELD2, WA-FIELD3.
    ENDIF.
    Anyway if you want to know only if a record exists, you can use the TRANSPORTING NO FIELDS option, in this case it doesn't need a workarea.
    READ T_ZTABLE WITH KEY FIELD3 = '0000000001'
                                      TRANSPORTING NO FIELDS.
    IF SY-SUBRC = 0.
    WRITE 'OK'.
    ENDIF.
    C) To update the data: it always needs a workarea
    LOOP AT T_ZTABLE INTO WA WHERE FIELD3 = '0000000001'.
    WA-FIELD3 = '0000000002'.
    MODIF T_ZTABLE FROM WA.
    ENDLOOP.
    or
    READ T_ZTABLE INTO WA WITH KEY FIELD3 = '0000000001'.
    IF SY-SUBRC = 0.
    WA-FIELD3 = '0000000002'.
    MODIF T_ZTABLE FROM WA INDEX SY-TABIX
    ENDIF.
    AT the end you can use the internal table to update database:
    MODIFY/UPDATE/INSERT ZTABLE FROM T_ZTABLE.
    See Help online for key words DATA, you can find out more details.
    Max
    Message was edited by: max bianchi

  • Download alv report output to excel format with out header line

    Hi experts,
    i want to download a alv report output into excel formatt with out the header line but it has to download including field description. as this output will fed into another transaction, the downloaded excel file should be with out header line.
    fro eg:
    Report   : Zabc                      ABAP Development          Page  :     1
    Run Date : 12/14/06                                                     System: UD400 
    Run Time : 08:45:37
    this header details should not be downloaded into the excel file.
    could somebody help me please.
    thanks
    deepu

    hi jayanti,
    thanks for your response.
    i have delclared all the field types as character but still it is not downloading and it 's sy-subrc is 4... the code is as below.
    *field names
      lt_fieldnames-value = 'Material Number'.
      APPEND lt_fieldnames.
      lt_fieldnames-value = 'Plant'.
      APPEND lt_fieldnames.
      lt_fieldnames-value = 'Material Group'.
      APPEND lt_fieldnames.
      lt_fieldnames-value = 'Material Description'.
      APPEND lt_fieldnames.
      lt_fieldnames-value = 'UOM'.
      APPEND lt_fieldnames.
      lt_fieldnames-value = 'Price Unit'.
      APPEND lt_fieldnames.
      lt_fieldnames-value = 'Material Type'.
      APPEND lt_fieldnames.
      lt_fieldnames-value = 'X-Plant Status'.
      APPEND lt_fieldnames.
      lt_fieldnames-value = 'Valuation Class'.
      APPEND lt_fieldnames.
      lt_fieldnames-value = lw_avmng.
      APPEND lt_fieldnames.
      lt_fieldnames-value = lw_avntp.
      APPEND lt_fieldnames.
      lt_fieldnames-value = 'Latest PO Qty'.
      APPEND lt_fieldnames.
      lt_fieldnames-value = 'Latest PO Cost'.
      APPEND lt_fieldnames.
      lt_fieldnames-value = 'PO Creation Date'.
      APPEND lt_fieldnames.
      lt_fieldnames-value = lw_fcaqt.
      APPEND lt_fieldnames.
      lt_fieldnames-value = 'Prev. Yr. Std. Cost'.
      APPEND lt_fieldnames.
      lt_fieldnames-value = lw_stcst.
      APPEND lt_fieldnames.
      CALL FUNCTION 'MS_EXCEL_OLE_STANDARD_DAT'
        EXPORTING
          file_name                       = 'XLSHEET'
        CREATE_PIVOT                    = 0
        DATA_SHEET_NAME                 = ' '
        PIVOT_SHEET_NAME                = ' '
        PASSWORD                        = ' '
        PASSWORD_OPTION                 = 0
        TABLES
        PIVOT_FIELD_TAB                 =
          data_tab                        = t_output1
          fieldnames                      = lt_fieldnames
        EXCEPTIONS
          file_not_exist                  = 1
          filename_expected               = 2
          communication_error             = 3
          ole_object_method_error         = 4
          ole_object_property_error       = 5
          invalid_pivot_fields            = 6
          download_problem                = 7
          OTHERS                          = 8
      IF sy-subrc <> 0.
        MESSAGE e001 WITH 'Data could not be downloaded'.
      ENDIF.
    ENDFORM.                               " z_dwn_xl
    thanks
    deepu

  • How to access a field of a structure with a field symbol?

    Dear all,
    Currently I'm trying to access the fields of a structure (called "ls_tbl") dynamicly. The code looks as follows (of course the field symbols are defined correctly ;-):
        ASSIGN lv_f1 TO <lv_f1>.
        ASSIGN lv_f2 TO <lv_f2>.
        lv_pp = ls_tbl-(<lv_f1>).
        lv_pt = ls_tbl-(<lv_f2>).
    Unfortunatly I get the following error message:
    <<The data object "LS_TBL" does not have a component called "".>>          
    I really do not understand why ABAP is trying to interpret the field symbol name as a string. Does anybody have a clue how to access the field of ls_tbl with the help of a field symbol?
    Many thanks!!!

    Hi ,
    Please check the below sample code .
    data : begin of st_table,
                myfiledname type c value '1',
                myfiledname1 type c value '2',
           end of st_table .
    data : lv_filedname(11) type c value 'MYFILEDNAME'
    filed-symbols : <fs> type any,
                    <fs_table> type any.
    assign st_table to <fs_table>.
    Assign lv_filedname to <fs> .
    assign component <fs> of structure <fs_table> to lv_pp.
    Regards,
    Ratheesh BS

  • With header line & with out header line ?

    what is difference between with header line & without header line ?

    When you create an internal table object you can also declare a header line with the same name. You can use the header line as a work area when you process the internal table. The ABAP statements that you use with internal tables have short forms that you can use if your internal table has a header line. These statements automatically assume the header line as an implicit work area. The following table shows the statements that you must use for internal tables without a header line, and the equivalent statements that you can use for internal tables with a header line:
    Operations without header line
    Operations with header line
    Operations for all Table Types
    INSERT <wa> INTO TABLE <itab>.
    INSERT TABLE ITAB.
    COLLECT <wa> INTO <itab>.
    COLLECT <itab>.
    READ TABLE <itab> ... INTO <wa>.
    READ TABLE <itab> ...
    MODIFY TABLE <itab> FROM <wa> ...
    MODIFY TABLE <itab> ...
    MODIFY <itab> FROM <wa> ...WHERE ...
    MODIFY <itab> ... WHERE ...
    DELETE TABLE <itab> FROM <wa>.
    DELETE TABLE <itab>.
    LOOP AT ITAB INTO <wa> ...
    LOOP AT ITAB ...
    Operations for Index Tables
    APPEND <wa> TO <itab>.
    APPEND <itab>.
    INSERT <wa> INTO <itab> ...
    INSERT <itab> ...
    MODIFY <itab> FROM <wa> ...
    MODIFY <itab> ...
    Using the header line as a work area means that you can use shorter statements; however, they are not necessarily easier to understand, since you cannot immediately recognize the origin and target of the assignment. Furthermore, the fact that the table and its header line have the same name can cause confusion in operations with entire internal tables. To avoid confusion, you should use internal tables with differently-named work areas.
    The following example shows two programs with the same function. One uses a header line, the other does not.
    With header line:
    TYPES: BEGIN OF LINE,
    COL1 TYPE I,
    COL2 TYPE I,
    END OF LINE.
    DATA ITAB TYPE HASHED TABLE OF LINE WITH UNIQUE KEY COL1
    WITH HEADER LINE.
    DO 4 TIMES.
    ITAB-COL1 = SY-INDEX.
    ITAB-COL2 = SY-INDEX ** 2.
    INSERT TABLE ITAB.
    ENDDO.
    ITAB-COL1 = 2.
    READ TABLE ITAB FROM ITAB.
    ITAB-COL2 = 100.
    MODIFY TABLE ITAB.
    ITAB-COL1 = 4.
    DELETE TABLE ITAB.
    LOOP AT ITAB.
    WRITE: / ITAB-COL1, ITAB-COL2.
    ENDLOOP.
    Without header line:
    TYPES: BEGIN OF LINE,
    COL1 TYPE I,
    COL2 TYPE I,
    END OF LINE.
    DATA: ITAB TYPE HASHED TABLE OF LINE WITH UNIQUE KEY COL1,
    WA LIKE LINE OF ITAB.
    DO 4 TIMES.
    WA-COL1 = SY-INDEX.
    WA-COL2 = SY-INDEX ** 2.
    INSERT WA INTO TABLE ITAB.
    ENDDO.
    WA-COL1 = 2.
    READ TABLE ITAB FROM WA INTO WA.
    WA-COL2 = 100.
    MODIFY TABLE ITAB FROM WA.
    WA-COL1 = 4.
    DELETE TABLE ITAB FROM WA.
    LOOP AT ITAB INTO WA.
    WRITE: / WA-COL1, WA-COL2.
    ENDLOOP.
    The list, in both cases, appears as follows:
    1 1
    2 100
    3 9
    The statements in the program that does not use a header line are easier to understand. As a further measure, you could have a further work area just to specify the key of the internal table, but to which no other values from the table are assigned.
    Internal table with header line
    you can use anywhere except obkect oriented concept.
    Internal table without header line :
    You should use in Object oriented concept..
    Always try to use without header line,performance point of view it is best..
    Example :
    Without header line.
    Structure
    types : begin of ty_itab ,
    matnr type mara-matnr,
    end of ty_itab.
    Internal table
    data i_itab type standard table of ty_itab .
    Work area
    data wa_itab like line of i_itab
    With header line
    data : begin of i_itab occurs 0,
    matnr like mara-matnr,
    end of i_itab
    itab with header lines are obsolete, anyway it will work but not recommended. instead use work area or more effiecient is field symbols. so donot use itab with header line.
    i will explain use of itab w/o header line.
    Data: itab1 type standard table of mara with header line occurs 0,
            itab2 type standard table of mara,
            wa_itab2 type mara.
    loop at itab1.
    "This will work fine.
    endloop.
    loop at itab2.
    "This will give erro that itabd does not hav workarea
    endloop.
    "so write
    loop at itab2 into wa_itab2.
    "This will work
    endloop.
    <b>The difference between
    whih header line and with out heater line of internal table.
    ex:-
    a) Data : itab like mara occurs 0 with header line.
    b) Data: itab like mara occurs 0.
    -While adding or retrieving records to / from internal table we have to keep the record temporarily.
    -The area where this record is kept is called as work area for the internal table.
    -The area must have the same structure as that of internal table. An internal table consists of a body and an optional header line.
    -Header line is a implicit work area for the internal table. It depends on how the internal table is declared that the itab will have the header line or not.
    a) Data : itab like mara occurs 0 with header line.
    table is with header line
    b) Data: itab like mara occurs 0.
    table is without header line</b>
    regards,
    srinivas
    <b>*reward for useful answers*</b>

  • Lt_item_type is a table with out header line and therefore has no component

    Dear frnds,
    I am new to webdynpro i got this error while creating a tree .can any body tell me what is the mistake i have done.
    Regards.
    siva

    Hi,
    As you are new to the tree concepts.Try to do this tutorial.It will give a idea.
    [Tree|http://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/d075dbc5-3b33-2c10-5f9f-99bf2738fe6a?QuickLink=index&overridelayout=true]
    Regards,
    Karthik.R

  • Adding fields from KOMK structure to screen painter.

    Hello Everyone,
    i have created an Extra tab(like ADDITIONAL DATA B) using BADI, i have added fields from VBAP table, its working fine. But when i add fields from KOMK structure(KOMK-STCEG) only empty field is showing. Do i need to code something in PBO or PAI?
    Thanks & Regards,
    NarsiReddy Cheruku.

    Hello NarsiReddy,
    I assume that you have linked the field KOMK-STCEG using "Get from Dictionary" option from your above screenshot.
    In PBO section, make sure to write the logic to update the value in the field. The logic which you would build, would be based on your requirement. For instance, you can use BELNR to check and its corresponding STCEG could be found in the structure KOMK.
    But if the KOMK structure itself is not filled with any value, then there is some problem with your code. Try to check your BADI and its corresponding structures which would get updated at runtime and use them appropriately.
    Thank you.
    Regards,
    Naresh

  • Can I export from Muse cc with out java script coding?

    How can I export from Muse CC with out Java Script Coding?
    I'm trying to create an custom email but email won't recognize Java Script, Only HTML.
    How do I export my tample from Muse CC using only HTML coding?
    Thanks in advance.

    Hello,
    It is not possible to selectively export only part of the code for the exported page(s). The pages that are exported, all the code for them is exported, and there's no way to export only the HTML and leave out the rest of it.
    Cheers
    Parikshit

  • If i sync'd songs to my ipod from a computer that i didnt have my accout on, is there a way to download songs from my account with out erasing the songs from the other account

    if i sync'd songs to my ipod from a computer that i didnt have my account on, is there a way to download songs from my account with out erasing the songs from the other accounts

    go to iTunes>Help>iTunes Help>Sync your iPod....>Sync You Device>Set up Syncing>Sync your device manually and follow the instructions.

  • Fucntion module to reterieve ANFDT field from the structure RM06E

    hi,
    I need Function module to reterieve ANFDT field from the structure RM06E or is there any other table for this field.
    Regards,
    anitha

    Anitha,
    That looks like the date on which the RFQ is created. What you can do is to get this date from EKKO table for a given RFQ, however you need to check the document category and type to A and AN respecitvely.
    Regards,
    Ravi
    Note : Please mark all the helpful answers

  • Good Morning.  How do I delete directly from the iPhone, with out synching, movies and/or tvshows?

    Good Morning.  How do I delete directly from the iPhone, with out synching, movies and/or tvshows?

    I had the same problem with Iphone 5 iOS 8, none of the methods described above were successful.
    Finally, Iexplorer helped to solve my problem.
    http://iexplorer-support.macroplant.com/customer/portal/articles/1325738-how-to- delete-all-photos-from-an-iphone-or-ipad
    best regards,
    salad

  • How to disable certain form fields from a calculation with a check mark fields.

    How to disable certain form fields from a calculation with a check mark fields.
    In Canada we have to taxes
    I create a form that calculate them to a total
    I need to be able to turn off any of those to taxes to participate to the calculation and their visibile field should become 0
    I was thinking using a checkbox (when checkbox is on (Yes) the tax is calculated, Not ticked (Off) the tax is not calculated and the visible field should show 0 or nothing....
    I really need help on this one — I’m a complete newbie....
    Remark that the second tax is calculated on the sum of what the first tax add (first tax is pan-canadian tax (all provinces).
    The second tax is never use alone (Quebec only (on top of the Canadian one)
    Sometime for outside Canada sell - No tax at all is calculated....
    What should I do?

    I want to tank you to help, really appreciate —>
    This is the code and order... I just trow the checkbox in there (they have, so far, no purpose...)
    The code use is
    var a = this.getField("pricehorstx");
    event.value = Math.round (a.value * 7.25) / 100
    I guess -If the checkBox are check - The tax should be calculate — If “Off” the tax should be not calculated and PriceHST and /or PriceQST should show zero or be empty — The HST is always calculated in Canada, but the QST is added only in Quebec.
    I need to turn both to Zero for international sale.
    Message was edited by: Chacapamac

  • Does iTunes use Internet Explorer to access the internet from a PC with Windows Vista?

    Does iTunes use Internet Explorer to access the internet from a PC with Windows Vista?

    Are you using Windows XP or Windows Vista?
    Did you remove iTunes and the other Apple software also, and then reinstall iTunes.
    Removing and Reinstalling iTunes, QuickTime, and other software components for Windows XP
    Removing and reinstalling iTunes, QuickTime, and other software components for Windows Vista or Windows 7
    Did you try to put the iPhone into recovery mode?

  • 2 questions, what do i do when a audio book i purchased is not in purchased menu for re downloading for my account, or why cant i re download the book from iTunes store with out paying for it after support they told me i could.

    what do i do when a audio book i purchased is not in purchased menu for re downloading for my account, or why cant i re download the book from iTunes store with out paying for it after support they told me i could.
    i tried to re download a purchased audio book after i contacted apple support team for iTunes they said it would be ready for re download or they said id have to re download it from iTunes store i cant remember, so i tried both couldn't re download it from purchased menu and the book id have to re download from iTunes store costs money as if i have never purchased what do i do? I don't have any warranty any more or money to purchase another warranty.

    Babowa
    Thank you for your prompt reply.  I have bought 1 MacbookPor 17, 1 Macbook air, 1 MacbookPro 15 , 2 ipads, 3 iphones, and this iMac27 and 2 of iMAC24 or 20 not sure   but I do not recall ever doing what you are telling me in your reply.   When you get a extended car warranty, you don't   sign up for it.. it is just there and is included in the sale.   You don't buy this warranty to use it.. You buy it, in case something happens.   Here a perfect iMAC with minimum 100 hour useage has a dead drive.  That is not normal and I should not have to even be requesting anything since most MFG offer a 3-5 year warranty on their disc drives and I believe that is probably passed on to Apple regardless if an extended warranty is purchased or not.   Customer service dictates a more flexible approach to make sure the lifetime value of a customer is not lost due to some misunderstanding.
    I was in the MacStore that I purchased the unit..and they found and pulled the invoice and confirmed
    the purchase of it in front of me.  I had paid with credit card and fortunately it was there in their system.   I do not also recall recieving any box or paper although most everything I ever get remains sealed.. I am not in the habit of opening anything since I have never encountered any serious issues before.
       I have used my Macbookpro warranty 1 time  and that is all throughout the years I have been investing in Apple equipment.
    I just recieved a letter from the store asking me to get the paper to them so they can register it... I don't recall getting any paper actually.  But I do have several boxes sealed here..  On this iMAC27, it was a hurry up and get it done thing and I don't remember taking anything extra with it.   Regardless,  my request does not seem unreasonable.
    Thank you

  • Anyone know which render format I should use, my film will be used on a video wall (12 screens) and I need super quality. My footage format is 1080p HD resolution 1920x1080. I will be running the project from a mac with a direct line to video wall. Thanks

    Anyone know which render format I should use, my film will be used on a video wall (12 screens) and I need super quality. My footage format is 1080p HD resolution 1920x1080. I will be running the project from a mac with a direct line to video wall. Thanks in advance.

    I do some VJ-type work, involving playback of QuickTime files from the computer to projections, and I get good results using ProRes 422. That's convenient, because ProRes 422 is such a great editing codec, too.
    Traditionally, VJs use PhotoJPEG codec, which also works well, but it's a bad editing codec. So you would have to export an edited master, then convert.
    If you want it to look as good as possible, definitely schedule some time to test the footage on the wall. You may want to change the color correction of your footage to match the projectors. And if you feed the video wall some flat gray, you can see if any of the projectors need to be  adjusted.
    I'm not sure what application you're using for playback, but QuickTime Player 7 works well. It has an option to play fullscreen on an external monitor (View > Present Movie…).

Maybe you are looking for

  • [SOLVED]how to change the size of default font ?

    , hellow everyone. I am newbie here and I recently installed Archlinux with Awesome WM,the default size of font is too small, in some cases,the characters even can not be clearly seen,I want to change the size of fonts so that I can read words comfor

  • Dump on screen when configuring Process controlled workflow

    Hi Experts, I am facing 1 problem in SAP SRM 7 ehp1.  I am configuring Process controlled workflow. Previous workflow settings was Application controlled workflow as its been upgraded from SRM 5. If i run a RFX (BUS2200) cycle in application controll

  • ITunes Producer Won't Launch

    Greets, When I try to run iTunes Producer 2.9 I get the following error message: "You can't open the application iTunes Producer because it is not supported on this type of Mac." I've checked the system requirements and it states: "iTunes Producer 2.

  • [SOLVED] FTP install (in MS Virtual PC 2007)

    Hi all, I'm new to Archlinux, coming from Debian and Ubuntu distros. I'm attempting to install Archlinux in an MS Virtual PC 2007 VM at my work. Everything seems to have gone fine so far until I get to select my packages. It says on any server I choo

  • Help with locating my Mac with find my iPhone

    My Mac was stolen and I uploaded find my iPhone to my phone. It has not located my computer yet and I am concerned that since I had to reset my password for icloud which obviously was not reset on my stolen computer, that find my Mac will not be able