Wat is the use of "DATA var-name LIKE SY-INDEX" statement

Hi to all,
       is there any use of "DATA <var-name> LIKE SY-INDEX"  statement in ABAP, do the variable <var-name> be changed with that of SY-INDEX when we declare like this.
         Could u give me a fast response,
                                        Thank you,
                                             Srinivasa Rao k.

hi check this example..
data: v_index type sy-index value 10 .
do 15 times .
if sy-index = v_index .
write:/ 'the system index is 10 '.
exit.
endif.
enddo.
the main use of the index is used in the hr programs..
the user wants the emp salary and previous months   salary then you need to use the index .
if the table had 10 records .then you need to catch the record of  index1(current) and index 2(for previous month)..
select pernr ansal  from pa0008 into table it_pa0008 where pernr in s_pernr and begda in s_begda .
loop at it_pa0008.
case sytabix.
when 1 .
it_final-cursal =  it_pa0008-ansal.
when 2 .
it_final-prevsal =  it_pa0008-ansal.
endcase .
endloop.
regards,
venkat.

Similar Messages

  • Wat is the use of occurs

    hi all
    wat is the use of occurs while declaring internal table.
    thankn in advance

    Hi
    The OCCURs Clause is used for declaring the SIZE of the Internal Table..
    For EG:
    Data: begin of itab occurs 0, means this will create an internal table with 8KB of memory.
    But if you are specifrying
    data:begin of itab occurs 10, this will create an internal table with 10 rows(according to the structure of the internal table)...
    Reward All Helpfull Answers........

  • Wat is the use of sid in extended star schema rather than linking masterdat

    hi bw gurus,
    wat is the use of sid in extended star schema rather than linking masterdata with dimention tables?
    thanx in advace,
    i will assign points,
    srinivas

    hi,
        the sid are used instead of the data in order to avoid the redunduncy of data.
    and reduce the datastorage size.
    the data will be present in the sid table and the data is linked used the corerponding sid in the dimension.
    regards

  • Wat is the use of casting in field symbols

    wat is the use of casting in field symbols?

    When you assign a data object to a field symbol, you can cast to any data type. This means that any area of memory can be viewed as having assumed a given type. You can then address parts of fields symbolically without having to use offset/length addressing.
    A cast is performed using the CASTINGaddition of the ASSIGN statement. The CASTINGaddition allows you to assign a data object to a field symbol where the type of the data object is incompatible with that of the field symbol. There are two types of casting: casting with an implicit type declaration and casting with an explicit type declaration.
    For details please have a look at below link:
    [Casting|http://help.sap.com/saphelp_nw70/helpdata/en/fc/eb3930358411d1829f0000e829fbfe/frameset.htm]
    I hope it helps.
    Thanks,
    Vibha
    Please mark all the useful answers

  • What happens if I switch off the "Use Cellular Data for Facetime"?

    So I got a notice saying that my phone's storage was almost full which makes no sense to me because I barely have about 300 pictures on my phone, barely any apps, but I do have music. I have mail turned OFF, and I am always on WIFI. I don't know how this is a problem.
    So what would happen if I pressed the switch off button for the "Use Cellular Data for: facetime"?
    I use facetime A LOT with my friends WHILE ON WIFI but if this is causing my storage to go so full, I will do it.
    Please heLP!

    Using cellular data has nothing to do with the storage capacity on your phone. By turning it off you will only be able to FaceTime when your connected to wifi, thus saving you on your data plan if you do not have unlimited data from your carrier.
    You can go to settings > usage to view what is filling up the capacity of your phone. You should import and back up your pictures to your computer following the directions here http://support.apple.com/kb/HT4083

  • I cannot find all my installed apps on the "use cellular data for" tab on the settings menu.

    I have a new iphone 5s and on the first day I've received it, I updated to IOS 8.0.2.
    Today, I've decided to turn my cellular data on and, in order to consume less data, I thought I would disable some of the apps. However, only a few were available/visible on the "use cellular data for" tab. However, when, with the cellular data turned on, I opened a missing app on the phone, it would start to appear on the list (where it wasn't previously). Also, when I go to the app on the settings menu, it would not have shown the option, "use cellular data" before I've opened the app and now it does. Do I need to turn on every single app before I can select my cellular data preferences? I know people with the same phone and their apps appear all, as expected.
    I don't know if this is a problem of my own carrier but I don't think so, because the people I mentioned earlier have the same carrier.
    Any help would be appreciated.
    Thank you.

    Did you try to reset the phone by holding the sleep and home button for about 10sec, until the Appel logo comes back again? You will not lose data by resetting.
    If this does not work, did you try to switch off Cellular Data, restart the phone and switch it back on again?

  • Where can i save the use's data of external application?

    where can i save the use's data of external application?and whether will it accumulate to some synchronic problem?
    The way i am doing by is to save the information in providersession by initSession() of ProviderInstance,then to get the information back by using session.getAttribute(),which is in jsp. is it right?and what problem will be caused?
    so i want to know what is the standard method to use the information in external application to page.

    Hi Alf,
    Please have a look at the POINT portlets. most of them are based on external apps. That could give you a fair enough idea of how to go about with your designs.
    http://www.oracle.com/technology/products/ias/portal/point.html
    thanks,
    Harsha

  • Connect to MS Access using NetBeans, data source name not found!

    Hi
    NetBeans IDE 7.3 and OS was Windows 7 (64-bit )
    When I run my program by NetBeans, it complain about the following errors.
    java.sql.SQLException: [Microsoft][ODBC Driver Manager] Data source name not found and no default driver specified
    In fact, the MS Access file had exist the specify path, I can run the jar file (not in IDE environment) and connect to MS Access DB successfully.
    And I had search from network, and found it said "the ODBC source was run by different server", one was C:\Windows\SysWOW64\odbcad32.exe for 32-bit and c:\windows\system32\odbcad32.exe for 64-bit.
    So the question is, why IDE cannot connect to MS Access DB, How to set NetBeans IDE to make it connectable to 32 bits or 64 bits ODBC, like the program run without IDE?
    Thanks!

    user13005878 wrote:
    java.sql.SQLException: [Microsoft][ODBC Driver Manager] Data source name not found and no default driver specifiedThat reads like "your datasource configuration is not good, fix it"
    And I had search from network, and found it said "the ODBC source was run by different server", one was C:\Windows\SysWOW64\odbcad32.exe for 32-bit and c:\windows\system32\odbcad32.exe for 64-bit. It would make a whole lot of sense if that was the other way around, don't you think? SysWOW64 for 64 bits and system32 for 32 bits.
    So the question is, why IDE cannot connect to MS Access DBBecause something is wrong
    How to set NetBeans IDE to make it connectable to 32 bits or 64 bits ODBC, like the program run without IDE?By setting the correct connection configuration properties.
    I'm not 100% positive, but I believe that doing ODBC connections from a 64 bits environment is not actually supported in Java. You may be outraged by that - in Java 8 the ODBC-JDBC bridge is going to be completely dropped, no more connecting to Access from Java without third party libraries (which tend to be commercial). In any case for now try to use a 32 bits Java runtime if you're using a 64 bits one.

  • How to use 'query data source Name '  property in a block

    I want to create a block using query and want to show the columns on a form.
    Could you please tell me how can I do this?
    Regards

    Hi!
    Create a new block manually.
    Set the Query Data Source Type Property to FROM clause query.
    In the Query Data Source Name Property write your query like you would
    write it in sql*plus or toad but without a order by clause.
    Set the DML Data Target Type Property to None.
    Create items for the columns in your query.
    May set the where clause and order by property of the block.
    Build the form and execute a query in your new block.
    Regards

  • What is the use of Data packet dim with Virtual cube with services

    Hi Friends,
    Could anybody tell me what is the use of Packet dimension in Virtual cube with services , It cannot contain data persistently ,Just fetch at runtime,Then there is no Physical load happening,Then why it should be automatically created for this??
    Message was edited by: Pradeep choudhari

    Hi Maik,
    Unit dimension will not be created automatically until and unless you have keyfigure referning units..
    But my question is : Why should we have data pack dimension , which is useless in this case of Virtual cube with services.It should not be created automatically!! What do you say??

  • What is the use of Position Column Name in USER_CONS_COLUMNS Table

    Please let me know the purpose of POSITION Column Name in USER_CONS_COLUMNS Table.
    Example :
    Created this below Table having two constraints 1.Primary Key 2.Check Constraint
    CREATE TABLE A(ID NUMBER PRIMARY KEY,NAME VARCHAR2(30),SAL NUMBER CHECK (SAL > 0))
    When i execute the below query
    SELECT POSITION,CONSTRAINT_NAME FROM USER_CONS_COLUMNS WHERE TABLE_NAME = 'A'
    it displays the data :
    POSITION CONSTRAINT_NAME
    1 SYS_C005488
    SYS_C005487
    Only for the first record it displays the POSITION but not for the second row.
    Kindly help me on this.

    SQL> CREATE TABLE A(
      2     ID1 NUMBER
      3   , ID2 NUMBER
      4   , NAME VARCHAR2(30)
      5   , SAL NUMBER CONSTRAINT A_SAL_POSITIVE CHECK (SAL > 0)
      6   , CONSTRAINT A_PRIMARY_KEY PRIMARY KEY (ID1, ID2)
      7  )
      8  /
    Table created.
    SQL> SELECT CONSTRAINT_NAME, POSITION, COLUMN_NAME
      2    FROM USER_CONS_COLUMNS
      3   WHERE TABLE_NAME = 'A'
      4   ORDER BY CONSTRAINT_NAME, POSITION
      5  /
    CONSTRAINT_NAME                  POSITION COLUMN_NAME
    A_PRIMARY_KEY                           1 ID1
    A_PRIMARY_KEY                           2 ID2
    A_SAL_POSITIVE                            SALA primary key constraint can have multiple columns - the position shows the order the columns are in the primary key definition (and thus also in the pk supporting index.)
    A check constraint does not have any such ordering of the columns involved, so therefore position is null.

  • Wat is the use of ports those are used for EMconsole

    hi all;,
    Could anyone please tell me
    1. the use of the agent,rmi and jms ports used for the dbconsole?
    2. if i block those ports can i use dbconsole?
    3. what are all the ports used for the database like listener, dbconsole http, dbconsole agent etc. and use of those.
    Thanks & Regards,
    Sagar Maram

    What is the use of the rmi and jms ports i mean how those are getting used internally. if block those ports with firewal then wat happend to dbconsole.?They are more appserver related components and to be clear..if the apps and DB are in the same server...then if you block these ports your DBConsole/Appconsole continues to work as long you have not blocked http DBconsole/Appconsole ports...
    But if you apps and DB are across network with a firewall between them then there is a possibility some of the functionality might not work but http console should work as long as http console port is opened in the firewall.....

  • Wat is the use of Advance tab in obiee

    hi all ,
    What is the use of advance tab , and that xml thing ..
    can any one tel me about it
    Thanks

    791907 wrote:
    hi all ,
    What is the use of advance tab , and that xml thing ..
    can any one tel me about it
    ThanksIf you actually go into the Advanced tab you will find some meaningful descriptions against everything on it.
    'That XML Thing' , its the definition of your report, criteria panel, views on the results tab.

  • HT201342 How can I change the USER of my i-cloud address? My 12 year old set up the e-mail account and used a silly user name (like: turtle!!). I would like to have an icloud e-mail account but under my own user name. The other /old name can be deleted?

    How can I change the USER name of my i-cloud e-mail account? It was set up by my son and he used a silly / embarrassing user name. I would like to change this name OR set up another i-cloud e-mail account under my own name / reference. Help?

    iCloud email addresses can't be changed or deleted, but you can set up an alias namethat he can use which will be linked to his current iCloud account and will receive email in the existing iCould inbox.  This guide explains how: http://support.apple.com/kb/PH2622.

  • Why won't some apps appear on the "Use cellular data for" list?

    When I enter settings then go to cellular, not all the apps I have on my phone are appearing on that list. In my case, I am trying to turn off data for Twitch.tv and Mlg.tv but they aren't there! These apps use ALOT of data so I don't want to be using my limited amount in case my wifi ever cuts out. Any help is appreciated.

    Many developers when they updated their apps to support iOS 5 and 6 dropped compatibility for iOS 4.2.1 and earlier.
    Your only way is if you have the version that was compatible on your computer such as in the recycle bin/trash or in a computer file backup. In that case delete the current version that is in your iTunes App library and replace it with the older version. Then sync.

Maybe you are looking for

  • Typing tool exits once I start typing -- Photoshop CS4

    I'd say 70% of the time this happens: I select the type tool start a new text box or select a pre-existing textbox start typing by the time I get to the second letter the text box deactivates and I just end up changing tools as I type their correspon

  • I can't use my iCloud

    Hello to every one. I have a probleme using my iCloud on my iPhone. I buy it yesterday, i linked it with my icloud account. When i arrived at home i updated the iOS, and now it requires me to sign in whith another user and another password. Did know

  • Error Creating VM on 2011 iMac - The Hyper-V Virtual Machine Management service encountered an unexpected error: The remote procedure call failed. (0x800706BE).

    I am running Hyper-V in Windows 8.1 on a late 2011 27 inch iMac. Whenever I try to create a virtual machine I get the error below and Windows warns that it will restart in 1 minute. I tried a clean install of Windows, but my PC still crashes ever tim

  • Wanboot issues

    Trying to configure wanboot, have gone over the config several times and tired various changes to no avail. Here is the error I receive, and some config is below. Any assistance is greatly appreciated. {40} ok boot net - install Boot device: /pci@5c,

  • Help needed for SAP Tables Relationships

    Hi All, I am new to ERP and need help regarding standard SAP Tables. Please share the document that contains the details of SAP Tables and Standard SAP FM that are provided by SAP. All helpful answers will be rewarded. Regards, Udaya.