When to use SELECT and END SELECT in the query.

hi all,
When to use SELECT and END SELECT in the query.
regads,
Venkata Suresh Penke.

Hi Suresh..
When do we need to use SELECT .. ENDSELECT
Usually we will never use SELECT .. ENDSELECT as it gives very poor performance.
But whenever we read a single Record we will use it as an alternative for SELECT SINGLE in some scenarios.
Eg: When the Full primary key is not specified in the WHERE clause.
SELECT * FROM MARC INTO WA_MARC UP TO 1 ROWS WHERE MATNR = P_MATNR.
ENDSELECT.
And other scenario is when we perform AGGREGATE OPERATIONS.when the Result is only one row.
SELECT SUM( LABST ) FROM MARD INTO V_LABST UP TO 1 ROWS
WHERE MATNR = P_MATNR.
ENDSELECT.
Note: In The Above scenario we cannot use SELECT SINGLE..
<b>REWARD IF HELPFUL.</b>

Similar Messages

  • When I use Premiere and After Effects at the same time, it causes my computer to restart. Why does it do that?

    When I create a dynamic link to after effects it will work for a couple seconds, but then I get a black screen saying error and that I need to restart my computer. I can use the programs independently, but not together.

    *** Panic Report ***
    panic(cpu 4 caller 0xffffff8002c1a46e): Kernel trap at 0xffffff8002bd1f96, type 14=page fault, registers:
    CR0: 0x0000000080010033, CR2: 0xffffffbf40000028, CR3: 0x000000040ac56010, CR4: 0x00000000001627e0
    RAX: 0xffffff7f80000000, RBX: 0xffffff8021b84100, RCX: 0xffffff7f80000028, RDX: 0x0000003fc0000000
    RSP: 0xffffff81ed203cd0, RBP: 0xffffff81ed203d00, RSI: 0x000000004169e77f, RDI: 0xffffff8007fa2da8
    R8:  0xffffff8022b77130, R9:  0xffffff81ed203e90, R10: 0x0000000000000001, R11: 0x0000000000000206
    R12: 0xffffff8007fa2da8, R13: 0xffffff8006ec4000, R14: 0x0000000000038000, R15: 0xffffff802cf46b40
    RFL: 0x0000000000010206, RIP: 0xffffff8002bd1f96, CS:  0x0000000000000008, SS:  0x0000000000000000
    Fault CR2: 0xffffffbf40000028, Error code: 0x0000000000000000, Fault CPU: 0x4
    Backtrace (CPU 4), Frame : Return Address
    0xffffff81ed203980 : 0xffffff8002b2fe41
    0xffffff81ed203a00 : 0xffffff8002c1a46e
    0xffffff81ed203bc0 : 0xffffff8002c36683
    0xffffff81ed203be0 : 0xffffff8002bd1f96
    0xffffff81ed203d00 : 0xffffff8002b9cc0d
    0xffffff81ed203f20 : 0xffffff8002c1a974
    0xffffff81ed203fb0 : 0xffffff8002c36595
    BSD process name corresponding to current thread: After Effects

  • After loading the internet using Firefox AND then selecting NEWS and a delay the Error "The MSN toolbar has encountered an error. etc" occurs. Also, when browsing some searches are "REDIRECTED"!

    After loading the internet using Firefox AND then selecting NEWS and a delay the Error "The MSN toolbar has encountered an error. etc" occurs. Also, when browsing some searches are "REDIRECTED"!
    == This happened ==
    Every time Firefox opened
    == Hard to say but have been trying to diagnose for at least a week.

    Original message wouldnt post with attachments - trying again....
    Attachments:
    secondclickheredialog.jpg ‏40 KB
    FirstDialog.jpg ‏19 KB
    Firstclickheredialog.jpg ‏16 KB

  • About start-of-selection and end-of-selection

    Hi all,
      what is the functionality of start-of-selection and end-of-selection events in reports.

    Here we go :
    Start-of-selection is the event where you will code ur sql statements, this is the event which will be triggered automatically even for normal programs, not only for reports even if you dont specify this event in the program.
    At Selection screen is the event to validate the input values given in the selection screen using initialization event.
    First in the sequence AT SELECTION SCREEN event will be triggered and then START-OF-SELECTION.
    END-OF-SELECTION, will fire only when you actually write it after the selection of the data is over. Usually between the START and END OF SELECTION you fetch the data and after the END OF SELECTION, you process the data and write that as output as display the same as ALV.
    If helpful pl reward.
    Cheers.

  • I have restore my ipone, but after that when i restart it and after selecting language and country. when i conntect to itunes, it display this message. We're sorry, we are unable to continue with your activation at this time

    i have restore my ipone, but after that when i restart it and after selecting language and country. when i conntect to itunes, it display this message. We're sorry, we are unable to continue with your activation at this timre

    Hello mzpartia,
    I found an article from Apple that specifically outlines how to try and troubleshoot this issue. It's called iPhone: Troubleshooting activation issues found here: http://support.apple.com/kb/ts3424.
    Resolution
    Perform the following steps if you receive one of the messages above:
    Restart the iPhone.
    Try another means of reaching the activation server and attempt to activate.
    Try connecting to Wi-Fi if you're unable to activate using a cellular data connection.
    Try connecting to iTunes if you're unable to activate using Wi-Fi.
    Restore the iPhone.
    If you receive an alert message when you attempt to activate your iPhone, try to place the iPhone in recovery mode and perform a restore. If you're still unable to complete the setup assistant due to an activation error, contact Applefor assistance.
    Take care,
    Sterling

  • I am still having issues when visiting a website and then selecting the back icon and going to days old data instead of current. How do I fix this?

    I am still having issues when visiting a website and then selecting the back icon and browsers is returning old data instead of current. How do I fix this?

    found a solution thank you firefox live chat!!!

  • Hi All, difference btwen data selection and person selection period in ldb

    Hi All, difference btwen data selection and person selection period in ldb -pnp
    If possible provide with an example .Its Urgent pls.

    Hi,
    Difference:--
    Data Selection Period
    The data selection period enables you to specify the period in which employee data records are read. Only records which overlap with the specified period by at least one day are selected. To define an interval, enter the start date in the left column and the end date in the right column
    Person Selection Period
    When you enter a person selection period, the system selects only those employees who are members of the enterprise on at least one day in the specified period. These are persons with a valid Organizational Assignment (0001) record. Entries in the standard selection options fields limit the personnel numbers that are selected. You can specify an interval by entering the start and end dates in the left and right columns respectively.
    Selection criteria in PNP are just used to determine the pernrs which meet them. For these pernrs then all wanted data is selected. This data then is not checked against this criterias.
    An Example:
    Pernr 4711 has benn assigned to costcenter 10 from 01.01.2004 until 31.12.2004. On 01.01.2005 costcenter changes to 20.
    If you now select all employees with costcenter 10 and list their costcenters, you will get both costcenters 10 and 20.
    Most reports which use PNP have to sets of date-ranges:
    - Person selection period that controls selection of pernr.
    - Other period that controls selection of data.
    If you set person selection period in above example to 01.01.2004 and other period to 01.01.2005 and select costcenter 10 you will in fact get employee 4711 with costcenter 20 shown.
    Same effect with org-unit or any other selection criteria.
    Regards
    Vasu

  • When I use Home sharing, I can see the library I want to copy, but when I highlight the library, the import button does not show up. Also, it will not let me drop and drag. How do I get music from one computer to the other computer?

    When I use Home Sharing, I can see the library I want to copy under Shared, but I can't get it save on the computer under the regular library. I go to edit and "select all" but there is no import button that is in the right hand corner. Also, it will not let me click and drag the music. How do I get it from one computer to the other?

    Since both computers are connected via the network, you could simply copy the ENTIRE iTunes folder from one computer to another via the network.
    If both computers are running Windows, use the Easy File Transfer Utility built into Windows to move iTunes and all other user media/data.

  • XMLP 5.6.2 - Parameters -  Both Multi-Select and All-Select  Do Not Work

    Both Multi-Select and All-Select Do Not Work.
    What's up with this behavior?
    And when might it be fixed?
    BG...

    The Multi-Select is now working, not sure what I did wrong earlier. However the "Can select all" option when building the parameter does not work as advertised, though I was able to get around that as well.
    Create a Data Model
    select LAST_NAME, FIRST_NAME from SOME_TABLE where SOME_COLUMN =:SOME_VALUE
    OR
    select LAST_NAME, FIRST_NAME from SOME_TABLE where SOME_COLUMN in (:SOME_VALUE)
    Create a LOV
    Name = LOV_SOME_COLUMN
    Type = SQL Query
    select distinct SOME_TABLE.SOME_COLUMN as SOME_COLUMN from SCHEMA.TABLE
    Create a Parameter
    Identifier = PARM_SOME_COLUMN
    Data Type = String
    Default Value = NULL
    Parameter Type = Menu
    Display Label = LOV_SOME_COLUMN
    List Of Value = LOV_SOME_COLUMN
    Option
    Multiple Selection - Checked
    Can select all - Checked
    Refresh other parameters on change - Checked
    Then test your report. Select "All" from the LOV and click view. Result - No Rows Returned.
    Selecting a "Single" or "Multiple Values" values from the LOV does work.
    The way I am getting around the problem is to uncheck the "Can select all" and then manually select all the values in the LOV in order to get the "All".
    BG...

  • Data selection and Person selection

    Hi all,
    What is the difference between 'Data selection' and 'Person selection' in PNP screen.(PNP logical database)
    I searched so many . But couldn't find appropriate one. Still confusing.
    Can any one explain me with example?
    must use both at a time or any one selection is enough?
    Which situation use 'Data selection' and which situation use  'Person selection' ?
    Thanks in advance.

    thanks for all reply.
    I have one pernr 700098
    Hiring date : 01.01.2008 - 16.08.2008
    firing date : 17.08.2008 - 31.12.9999
    I developed a customized report using PNP LDB.
    If , I entered 01.01.2008 - 31.12.2008 in 'Data selection'
                  3 in employee status( active)
    or
    I entered 01.01.2008 - 31.12.2008 in 'Person selection'
                  3 in employee status( active)
    If , I entered 01.01.2008 - 31.12.2008 in 'Data selection'
                  0 in employee status( active)
    or
    I entered 01.01.2008 - 31.12.2008 in 'Person selection'
                  0 in employee status( active).
    In above all cases picking the same record. what is the use of PNP screen?
    after 'GET PERNR' pernr structure get the value of latest record from infotype P0000.ie firing record. Because it doesn't bother the status.
    For below case picking the proper one.
    If , I entered 01.01.2008 - 16.08.2008 in 'Data selection'
                  3 in employee status( active)
    or
    I entered 01.01.2008 - 16.08.2008 in 'Person selection'
                  3 in employee status( active)
    If , I entered 17.08.2008 - 31.12.2008in 'Data selection'
                  0 in employee status( active)
    or
    I entered 17.08.2008 - 31.12.2008 in 'Person selection'
                  0 in employee status( active).
    Plz any one clear me.
    Thanks.

  • WHEN TO USE SYS_REFCURSOR AND WHEN NOT TO USE REFCURSOR

    SYS_REFCURSOR is a Weakly Defined Cursor
    DECLARE emp_refcur SYS_REFCURSOR;
    when this is so simple
    why this
    DECLARE TYPE emp_cur_type IS REF CURSOR RETURN emp%ROWTYPE; my_rec emp_cur_type; ?
    Can anyone explain in what situations we should prefer among these ..when both can give same result set .

    > WHEN TO USE SYS_REFCURSOR AND WHEN NOT TO USE REFCURSOR
    When the requirements define that one is better suited than the other.
    There are no hard and fast rules about when to use a specific tool. There are however basic concepts of what the purpose of the tool is, and what typical problems the tool can address.
    Ref cursors in PL/SQL.. usually not the best of ideas. Ref cursors are designed for client-server processing.
    1) The client makes a request for data/information.
    2) PL applies the back-end server logic and construct a SQL statement for the client.
    3) PL passes the SQL to the SQL engine where it is parsed and a SQL cursor created.
    4) PL passes a reference handle to SQL cursor back to the client
    5) The client can now fetch the rows output from the cursor.
    Advantages.
    - The client does not need to know SQL, db structures, business logic, etc
    - The PL code can be improved, modified, new business logic added, without even touching a single byte of client code
    So what are the advantages where the "client" in the above is another PL/SQL program? None really.
    A "real" client (an external one like Java, C#, Delphi, etc) can receive the ref cursor handle and dynamically at run-time determine the projection (output) of the cursor.
    PL code cannot (unless using the latest 11g features). In PL code, a ref cursor is actually implemented as a DBMS_SQL cursor. A DBMS_SQL cursor is to PL code what ref cursor is to Java/C#/etc.
    So whether you define a strongly typed or weakly typed ref cursor in PL/SQL code... typical response is "so what?" as ref cursors are not really intended for PL code. Not that there are exceptions - they do come in handy at times.. but as exceptions to the rule.
    So my response is "so what?" - it is more important to *correctly" chose what type of client cursor data type you want to use to interact with the back-end SQL cursor. Once that decision has been made (based on technical sound logic), then one can look at  (minor) issues such as weak vs. strong ref cursors.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               

  • I am running MS Office for Mac 2008 on my MacBook Pro.  I do not have the Standard and Formatting toolbar fixed into position, as I would expect and would like.  I can access them via the View menu, where I have to select and de-select them before I can g

    I am running MS Office for Mac 2008 on my MacBook Pro.  I do not have the Standard and Formatting toolbar fixed into position, as I would expect and would like.  I can access them via the View menu, where I have to select and de-select them before I can get them to display, but lose them when I log off. Can anyone help?  I have tried all the usual and supplied help facilities to no avail.  Thanks

    Post the question in Microsoft's own Office for Mac forum.

  • When I use my IPhone 4S to view the Shaw Go Movie Central App when I am at home I only use WiFi which is automatic, I start watching a show and sometimes I will get a message like "you can not use your cellular for video playback" or something close to th

    When I use my IPhone 4S to view the Shaw Go Movie Central App when I am at home I only use WiFi which is automatic, I start watching a show and sometimes I will get a message like "you can not use your cellular for video playback" or something close to that. Then I received an email from Telus saying I had used my 3G instead of Wi-Fi  using 75% of my data. How can this happen when I'm on Wi-Fi at home? If it switched to 3G for some reason I should have been disconnected and not just transferred to 3G network using up my data. What is the fix for this??

    It doesn't have to be that complicated, Verizon iPhones come unlocked, just tell VZ you're going on Holiday/Traveling and suspend the service, no need to pay for service if you're not going to be using it. Pick up local SIM cards in the countries of your choosing, pop them in, re-activate iMessage and you're set!
    I recommend getting a SIM card from the Three network in England, they have great EU roaming rates and free like-home roaming in Italy.
    Set your phone's region to match the country you're in, it'll save from some headaches when calling local/international numbers.
    To answer your questions,
    1. If you choose not to have a local SIM card, it is good to keep your phone in Airplane mode to save battery.
    2. Make sure the two iPhones have different names to reduce sync/restore issues.
    3. If husband has an iPhone also, you can chat with iMessage/Facetime, just give him heads up about the new number you'll have. Otherwise, use Whatsapp if he's got an Android. You can activate Whatsapp with your American number or the international number if you choose to get a SIM in Europe.
    Also, Get the MagicJack app and/or Google Hangouts, both of those apps provide you with free calling to the USA and Canada using any internet connection. Google Voice is another good way to SMS across the seas.
    Let me know if you need any more tips for iPhoning across the pond.

  • Anyone know how to use a 'home' and 'end' key on the Macbook pro keyboard?

    I had a pc before, and the keyboard had home and end keys on the keyboard for quickly moving cursor to end or beginning of word or sentence.  I can't figure out if there is something like that on the Macbook pro.  It would be really helpful.  So does anyone know if there is those keys and if so what do i use?
    I'd appreciate any help. 
    Thanks

    see if any of this works for you
    On a smaller keyboard, such as the wireless, or on portables, you can use fn- left arrow for home and fn- right arrow for end.
    On a Mac, 'home and 'end' take you to the beginning and the end of document, respectively. Getting to the beginning or end of a line is done with cmd- leftarrow and cmd- rightarrow. Emacs shortcuts, such a ctrl-a and ctrl- e also work in most places, where the app is done right.

  • How do I delete my old iMessage email and change to my current one, that Im using when I buy apps and so on. The old one wont go away when I turn iMessage on and of again. pls help

    How do I delete my old iMessage email and change to my current one, that Im using when I buy apps and so on. The old one wont go away when I turn iMessage on and of again. pls help
    Anyone had the same?

    How do I delete my old iMessage email and change to my current one, that Im using when I buy apps and so on. The old one wont go away when I turn iMessage on and of again. pls help
    Anyone had the same?

Maybe you are looking for

  • Using scripting with networking equipment under Windows

    It can be a challenge to use scripting to automate working with Cisco devices. The Cisco IOS does not seem to directly provide a command line interface. You are forced to find a way to automate interaction with a telnet or ssh session. The PERL langu

  • New g/l account

    hi experts pls give tell me abt new g/l

  • How to delete standard text in SO10

    Hi, We have lot of data in SO10 ,whcih we don't need now. How can we delete it?

  • Dynamic values for column header / "AS" using XMLFOREST

    Hello, I was wondering if it was possible to show data from a select statement into an AS column, e.g. SELECT col.a AS col.b. The reason I need this is for XMLFOREST, as I need the value of a SELECT statement to be the column name, so that it will be

  • Infotype 0008 Wage type Issue(Urgent)

    Hi all, An hiring action was run for a new employee and subsequent information was input in PA30.Along with other information wage-type was filled in Infotype 0008. Problem: When we check the corresponding transparent table PA0008 we are unable to fi