Query for list of specifications

Hi Experts,
We need to execute query which should contain list of specifications with and without material assignments.Selection criteria is based on generation variant.
Please let us know from which tables we can get the above list.
Thanks for your help!!
Regards,
Sivasankar
Message was edited by: Sivasankar P
Message was edited by: Sivasankar P

Hi Chris,
This issue is not related to consultant and it is related to end user. We have query which is already defined to pick up specifications with material.Now they have requested us to get the query even there is no material assigned to specifications.
So we have planned to remove material from query, so if we remove ESTMJ from query whether it will have impact on some other tables.(like ESTDJ,ESTRH,ESDTH,etc..)
Thanks for your help!!
Query:
*delete report if there is no material
SORT I_ESTRH BY RECNROOT.
   SORT I_ESTMJ BY RECNROOT.
   IF I_ZESTRHESTDJESTDH[] IS NOT INITIAL OR
      I_ZESTRHESTDJESTDH1[] IS NOT INITIAL.
     LOOP AT I_ESTRH INTO WA_ESTRH.
       MOVE SY-TABIX TO V_INDEX.
       READ TABLE I_ESTMJ INTO WA_ESTMJ WITH KEY RECNROOT = WA_ESTRH-RECNROOT
                                                               BINARY SEARCH.
       IF SY-SUBRC NE 0.
         READ TABLE I_ZESTRHESTDJESTDH WITH KEY SUBID_ESTRH = WA_ESTRH-SUBID
                                                              BINARY SEARCH.
         IF SY-SUBRC NE 0.
           READ TABLE I_ZESTRHESTDJESTDH WITH KEY SUBID = WA_ESTRH-SUBID
                                                          BINARY SEARCH.
           IF SY-SUBRC NE 0.
             READ TABLE I_ZESTRHESTDJESTDH1 WITH KEY SUBID = WA_ESTRH-SUBID
                                                             BINARY SEARCH.
             IF SY-SUBRC NE 0.
               READ TABLE I_ZESTRHESTDJESTDH1 WITH KEY SUBID_ESTRH = WA_ESTRH-SUBID
                                                                     BINARY SEARCH.
               IF SY-SUBRC NE 0.
                 DELETE I_ESTRH INDEX V_INDEX.
               ENDIF.
             ENDIF.
           ENDIF.
         ENDIF.
       ENDIF.
     ENDLOOP.
   ENDIF.
Regards,
Sivasankar

Similar Messages

  • Query for listing several values in same field

    Hi,
    is there a function for listing more than one value in the same field, only with comma seperation?
    For example, I want to group by cardcode from ORDR and list all docnum's like this:
    Cardcode    Docnum's
    21355          98765, 95498, 95164
    21564          95484, 54684, 95654, 98465
    21865          95484, 12486
    Kind regards
    Kjetil Sandvik

    HI,
    Thank for your replies.
    We need to update all old orders for sure, but my idea was to use this query:
    Select CardCode, COUNT(Address2) From ORDR Where Docstatus <> 'C' GROUP BY address2, cardcode order by cardcode, address2
    The results will give me two lines for each customer and count the addresses, so then I know that the count of one of the lines must me changed. Let's say there is 20 orders with new address and 20 orders with old address, my intention was to manually change the 20 orders that is old. Instead of checking all 40, It would help alot to list all order numbers in a column beside in the query.
    BR
    Kjetil

  • Query for list of supported auth mechanisms

    Is there a way to query a BO server for a list of supported authentication mechanisms such as secEnterprise or trusted secret or secWinAD, etc?

    I haven't tested but this should work:
    InfoObject oIfoObject = (IInfoObject) oInfoStore.query("select si_id from ci_systemobjects where si_name='Auth Plugins'").get(0);
    IInfoObjects authPlugins = oInfoStore.query("select * from ci_systemobjects where si_parentid=" + oInfoObject.getID());
    for(int i=0; i<authPlugins.size(); i++)
           IInfoObject authPlugin = (IInfoObject) authPlugins.get(i);
           // above returns a specific plugin object: secLDAP, secWinAD, secSAPR3, secEnterprise all what your installation supports
    //  cast the InfoObject to IsecWinAD if si_kind=' secWinAD' or si_name is secWinAD
    if(authPlugin.getTitle().equalsIgnoreCase("secWinAD"))
                  IsecWinAD winad = (IsecWinAD) authPlugin;
                  int availability =  winad.getAvailaility(); //0 - if plugin is not configured\ready to use, 1 if ready to use and configured.
                  String enabled =winad.properties().getProperty("SI_TRUSTED_AUTH_ENABLED").getValue().toString(); // returns true if trusted aut is enabled for this plugin, false otherwise.
    I don't think you can read any property to retrieve the trusted key. The above code will give the auth plugins that are available in your install, which ones are ready and configured ( I have checked only the AD ones above) and if trusted auth is enabled. Check query builder properties if you are trying to get additional info for the auth plugins.

  • Query for list of tables

    Hi Gurus,
    I have a requirement, i have one server on which i have got 20 DB and now i want to list those 20 DB and the count of total tables on each DB and the last login date on each DB. How can i do that? i was trying the below one but in vain.
    EXEC sp_databases;
    can you please provide your inputs for this.
    Thanks,
    RM

    Then I am speechless.
    In Oracle, for the table counts:
    select owner, count(*) from dba_tables group by owner;For last login date you need to enable auditing to track something like that.
    For SQL Server databases you should go here :
    http://social.msdn.microsoft.com/Forums/en/category/sqlserver
    Good luck!

  • Ridc query for list of WebSites

    I am just starting with RIDC and with UCM, developing a web app to allow access to UCM via IDC. I need to get back data for presenting lists to my users, like: list of websites maintained by UCM, list of sections within particular websites, etc. I am baffled and would appreciate tips as to service to use (GET_SEARCH_RESULTS ??) and parameters which need to go into the DataBinder to use with the service. At this point I can do simple queries to find content, but not much more.

    Hi.
    To filter Site Studio Sites in UCM you have tu execute GET_SEARCH_RESULTS filtering by: xWebsiteObjectType <matches> `Project`.
    You'll obtain the list of Site Studio Sites :).
    PD: It's a WebCenter Content Post not WebCente Portal ;).

  • TDS Amount on Vendor Advance Shows positive value in *QUERY* for TDS Report

    Hi Everybody,
    I have made a query for List of TDS Report with Vendor informations as required by my client. In which the value of TDS on Vendor Advance Payment appears as positive value instaead of negative value. Please suggest how to rectify.
    Thanks,
    Paul

    Dear,
    If you have cleared the advance in F-54, then this will reverse the tax amount. That could be the reason for tax amount in debit.

  • Sql query to list menus, submenus and function-names for all resp

    Hi,
    Please let me know one single sql query to list all the menus, submenus and user-function-names attached for all responsibilities
    Thanks...

    Hi,
    See the following threads.
    How to find All The Responsibilities with a specific Menu
    How to find All The Responsibilities with a specific Menu
    SQL query
    SQL query
    Regards,
    Hussein

  • ABAP Query, To list both, the PO created and PO modified for a given period

    Hi
    I want to create a query that list the purchasing orders created or modified during a given period. however, the creation date and the modification date are two different fields stored in differents tables.
    if I have these two fields in the selection creteria screen, the relationship between them will be the operator AND. so this will not enable me to have the information targeted.
    My quetion, is there a possibility to have the Operator OR in the first selection creteria screen , between these 2 fields.?
    the tables are:
    for the creation EKKO
    for the change :
    MECDGRID
    CDHDR Change document header
    CDPOS Change document items
    thanks

    Hello,
    Fetch data from EKKO and do a for all entries on the table CDHDR on the field OBJECTID and EBELN and t-code = ME21N OR ME21 ETC.
    Similarly between CDHDR and CDPOS tables based on objectid`s.
    Hope this helps you in solving your problem!
    Regards,
    Reetesh

  • Problem writing a sql query for a select list based on a static LOV

    Hi,
    I have the following table...
    VALIDATIONS
    ID          Number     (PK)
    APP_ID          Number     
    REQUESTED     Date          
    APPROVED     Date          
    VALID_TIL     Date
    DEPT_ID          Number     (FK)
    I have a search form with the following field item variables...
    P11_DEPT_ID (select list based on dynamic LOV from depts table)
    P11_VALID (select list based on static Yes/No LOV)
    A report on the columns of the Validations table is shown based on the values in the search form. So far, my sql query for the report is...
    SELECT v.APP_ID,
    v.REQUESTED,
    v.APPROVED,
    v.VALID_TIL,
    d.DEPT
    FROM DEPTS d, VALIDATIONS v
    WHERE d.DEPT_ID = v.DEPT_ID(+)
    AND (d.DEPT_ID = :P11_DEPT_ID OR :P11_DEPT_ID = -1)
    This query works so far. My problem is that I don't know how to do a search based on the P11_VALID item - if 'yes' is selected, then the VALID_TIL date is still valid. If 'no' is selected then the VALID_TIL date has passed.
    Can anyone help me to extend my query to include this situation?
    Thanks.

    Hello !
    Let's have a look at my example:create table test
    id        number
    ,valid_til date
    insert into test values( 1, sysdate-3 );
    insert into test values( 2, sysdate-2 );
    insert into test values( 3, sysdate-1 );
    insert into test values( 4, sysdate );
    insert into test values( 5, sysdate+1 );
    insert into test values( 6, sysdate+2 );
    commit;
    select * from test;
    def til=yes
    select *
      from test
      where decode(sign(trunc(valid_til)-trunc(sysdate)),1,1,0,1,-1)
           =decode('&til','yes',1,-1);
    def til=no
    select *                                                                               
      from test                                                                            
      where decode(sign(trunc(valid_til)-trunc(sysdate)),1,1,0,1,-1)
           =decode('&til','yes',1,-1);  
    drop table test;  It's working fine, I've tested it.
    The above changes to my first idea I did because of time portion of the DATE datatype in Oracle and therefore the wrong result for today.
    For understandings:
    1.) TRUNC removes the time part of DATE
    2.) The difference of to date-values is the number of days between.
    3.) SIGN is the mathematical function and gives -1,0 or +1 according to an negative, zero or positiv argument.
    4.) DECODE is like an IF.
    Inspect your LOV for the returning values. According to my example they shoul be 'yes' and 'no'. If your values are different, you may have to modify the DECODE.
    Good luck,
    Heinz

  • How to query for specific filename

    I'm using a modified folder_action script to ftp files up to a server once they're finished being created.
    Is there a way to query for a specific filename to be present in the folder prior to passing it to the actual ftp function? The catch is that the filename will always be in the format of <mmddyy>.mp4. During the process that is creating the actual file to be ftp'd, various temp files are created prior. I'd like to ensure that only the final version of the mp4 is acted upon, which is the one with the mmddyy as the filename.

    The folder action already has the folder and the item paths passed to it, so you can get the individual file name by using something like:
    <pre style="
    font-family: Monaco, 'Courier New', Courier, monospace;
    font-size: 10px;
    margin: 0px;
    padding: 5px;
    border: 1px solid #000000;
    width: 720px;
    color: #000000;
    background-color: #FFDDFF;
    overflow: auto;"
    title="this text can be pasted into the Script Editor">
    on adding folder items to this_folder after receiving added_items
    repeat with AnItem in added_items
    if text (count (this_folder as text)) thru -1 of (AnItem as text) is "<mmddyy>.mp4" then
    -- whatever
    end if
    end repeat
    end adding folder items to
    </pre>
    There are also temporary folders that the system provides, so you shouldn't have to use the folder with the attached action at all:
    get path to temporary items
    get path to temporary items from user domain

  • SQL query to list the "Administrative category" field for all applications

    yesterday i started a thread to list the "Optional reference" field for all cm applications in a SSRS report. I've got the query with the help of Torsten.
    https://social.technet.microsoft.com/Forums/en-US/00419e6e-e3c2-4b80-b6af-2a24ced1032d/sql-query-to-list-the-optional-reference-field-of-all-packages-in-cm-2012?forum=configmanagersdk
    But again today, i'm looking for a way to get "Administrative category" field in a SSRS report. Could someone point me to the right direction ?
    Kindly mark as answer/Vote as helpful if a reply from anybody helped you in this forum. Delphin

    Hi,
    You could monitor the SMSProv.log when you check the category of an application. It shows that SQL query the SCCM provider used is related to function fn_ListCategoryInstances.
    Best Regards,
    Joyce

  • Query for price list

    Experts,
    Can you please tell me what will be the query for
    for all prices which are u201C0u201D empty  (products)
    Thanks a lot in advance

    Thanks a lot Rahul and Gordon
    I am trying like as per the need
    SELECT T0.ItemCode, T0.ItemName, T0.ItmsGrpCod, T2.ListNum, T2.ListName,
    Sum (T1.[Price]) FROM OITM T0 INNER JOIN ITM1 T1 ON T0.ItemCode = T1.ItemCode INNER
    JOIN OPLN T2 ON T1.PriceList = T2.ListNum GROUP BY  T0.[ItemCode] HAVING Sum (T1.[Price]) <=0
    But error comes like
    1). [Microsoft][SQL Native Client][SQL Server]Column 'OITM.ItemCode' is invalid in the select list because it is not contained in either an aggregate function or the GROUP BY clause. 2). [Microsoft][SQL Native Client][SQL Server]Statement 'Received Alerts' (OAIB) (s) could not be prepared.
    Please Help

  • Creating a query for task list operations

    hello all
    I checked the forum for similar questions but could not find any.
    I am trying to create a task list for the following:
    1) specific plant
    2) generic task list
    3) specific group counter
    4) specific operations type (filtered by control keys)
    in the display I also include the dependencies of the operations.
    I also need to link the task list to a specific class and extract the characteristics value from the class, based on the task list (I think this is better with infoset: if so, in a second stage).
    I am using tables
    1)PLKO and PLPO joined by PLNTY and PLNNR
    2) CUOB, joined to PLPO by KNOBJ and CUKB joined to CUOB by KNNUMfor the dependencies
    the results tho, gave me operations that did not exist in the task list so I discovered that there were change masters to the task lists and I added table AENR, outer joined to PLKO by AENNR where I excluded inactive changes.
    I still do not get correct results.
    I do not get all the active change masters related to a task list, I do not manage to get the task list without changes and also the related operations and dependencies are not correct.
    can someone help?

    Hi alisa,
    Onethng was not yet touched upon in the discussion sofar. If you are not getting all the records those should come, then you need to try LEFT OUTER JOIN  between tables by trial. (Trial means LOJ is not accepted on adjacent tables.) I hope you know that the default connection between fields of 2 tables in through INNER JOIN.  You need to right click on this line and select LOJ for making it LOJ. This brings you all the records which are being filtered due to IJ (if any).
    Try this, if you haven't done already.
    KJogeswaraRao

  • An EUL query to list out All the Columns  (Fileds) for each Workbook

    Hi,
    I'm using Discoverer 10.1.2.2 on an Oracle 9.2.0.6.
    Does anyone have the EUL query that lists out all the names of Workbook/Worksheets and the names of their fields/columns. I would greatly appreciate it.
    Thanks

    Hi
    While it is not possible to read the workbook itself, whenever Discoverer runs a worksheet so long as you have enabled the gathering of statistics then a row is written to the EUL5_QPP_STATS table. In that table the column called DOC_NAME is the workbook, the column called DOC_DETAILS is the worksheet, with the CREATED_DATE being the date the worksheet was run. There are other encrypted columns in that table that contain the EUL items that were queried.
    Look at this code:
    SELECT
    QS.QS_DOC_OWNER    USER_NAME,
    QS.QS_DOC_NAME     WORKBOOK,
    QS.QS_DOC_DETAILS  WORKSHEET,
    TRUNC(QS.QS_CREATED_DATE) DOC_DATE,
    *(LENGTH(TO_CHAR(EUL5_GET_ITEM_NAME(QS.QS_ID)))+1)/9 ITEMS,*
    EUL5_GET_ITEM(SUBSTR(EUL5_GET_ITEM_NAME(QS.QS_ID),1,  6)) ITEM1,
    EUL5_GET_ITEM(SUBSTR(EUL5_GET_ITEM_NAME(QS.QS_ID),10, 6)) ITEM2,
    EUL5_GET_ITEM(SUBSTR(EUL5_GET_ITEM_NAME(QS.QS_ID),19, 6)) ITEM3,
    EUL5_GET_ITEM(SUBSTR(EUL5_GET_ITEM_NAME(QS.QS_ID),28, 6)) ITEM4,
    EUL5_GET_ITEM(SUBSTR(EUL5_GET_ITEM_NAME(QS.QS_ID),37, 6)) ITEM5,
    EUL5_GET_ITEM(SUBSTR(EUL5_GET_ITEM_NAME(QS.QS_ID),46, 6)) ITEM6,
    EUL5_GET_ITEM(SUBSTR(EUL5_GET_ITEM_NAME(QS.QS_ID),55, 6)) ITEM7,
    EUL5_GET_ITEM(SUBSTR(EUL5_GET_ITEM_NAME(QS.QS_ID),64, 6)) ITEM8,
    EUL5_GET_ITEM(SUBSTR(EUL5_GET_ITEM_NAME(QS.QS_ID),73, 6)) ITEM9,
    EUL5_GET_ITEM(SUBSTR(EUL5_GET_ITEM_NAME(QS.QS_ID),82, 6)) ITEM10,
    EUL5_GET_ITEM(SUBSTR(EUL5_GET_ITEM_NAME(QS.QS_ID),91, 6)) ITEM11,
    EUL5_GET_ITEM(SUBSTR(EUL5_GET_ITEM_NAME(QS.QS_ID),100,6)) ITEM12,
    EUL5_GET_ITEM(SUBSTR(EUL5_GET_ITEM_NAME(QS.QS_ID),109,6)) ITEM13,
    EUL5_GET_ITEM(SUBSTR(EUL5_GET_ITEM_NAME(QS.QS_ID),118,6)) ITEM14,
    EUL5_GET_ITEM(SUBSTR(EUL5_GET_ITEM_NAME(QS.QS_ID),127,6)) ITEM15,
    EUL5_GET_ITEM(SUBSTR(EUL5_GET_ITEM_NAME(QS.QS_ID),136,6)) ITEM16,
    EUL5_GET_ITEM(SUBSTR(EUL5_GET_ITEM_NAME(QS.QS_ID),145,6)) ITEM17,
    EUL5_GET_ITEM(SUBSTR(EUL5_GET_ITEM_NAME(QS.QS_ID),154,6)) ITEM18,
    EUL5_GET_ITEM(SUBSTR(EUL5_GET_ITEM_NAME(QS.QS_ID),163,6)) ITEM19,
    EUL5_GET_ITEM(SUBSTR(EUL5_GET_ITEM_NAME(QS.QS_ID),172,6)) ITEM20
    FROM
    EUL5_QPP_STATS QS--,
    --   APPS.FND_USER          USR
    WHERE
    --   QS.QS_DOC_OWNER = '#' || USR.USER_ID AND
    *(LENGTH(TO_CHAR(EUL5_GET_ITEM_NAME(QS.QS_ID)))+1)/9 < 21*
    AND QS.QS_CREATED_DATE > '01-JAN-2009';
    In order to run this you must have run the EUL5.SQL when connected as the owner of the EUL. This script can be found in the $ORACLE_HOME\Discoverer\Util folder of the machine where the Discoverer Administrator tool is installed.
    Try it out for yourself and you will see how it works.
    Best wishes
    Michael

  • JPQL Query for specific usecase, help needed

    Does anyone knows how to write the JPQL query for this specific use case.
    Take 3 tables,
    Table 1 contains bids for many auctions (Bid table)
    Table 2 Contains many auctions (Auction Table)
    Table 3 contains many users (User Table)
    I need a query to retrieve all the highest bids per auction for a particular user.
    For example if the user has bidded on 10 auctions., but for each auctions has placed 3 bids each. Following the query, I would expect to get 10 bids back, each being the highest per auction.
    A Bid has a bid value that can be used for filtering.
    Thanks
    Peter

    It would be something like the JPQL version of 'select * from bids join auctions using (auction_id) where bids.userid = ? group by auctions.auction_id order by bids.amount desc'. But this is primarily an SQL question, and only secondarily a question as to how to translate that into JPQL, which should be straightforward.

Maybe you are looking for

  • How to Configure the Buttons on the QAF for Mobile UI Screens...

    Hi Experts, I am in a serious need of help from the experts who already designed the Mobile UI screens. I have built a add-on where now we are looking this add-on to be available to use in mobile applications also. Now here what I did is I have devel

  • Outlook 2013: I can't find the folder where a message is stored

    In old versions of Outlook I could right click and go to the properties of the message to see what folder it is in, but that seems to be missing in Outlook 2013. Anyone know how I can enable this functionality? Thanks!

  • How to add a excel driver in the Adminstrator tools

    how to add a excel driver in the adminstrator tools > odbc Datasource, I have to add the name and excel sheet location in the SystemDsn but whiling finishing the stups i will get the error like error found could not found the registery. ,So is there

  • My iPod touch keeps freezing when I play music?

    So yesterday I notcied my 2nd gen itouch that whenever I played a song and change it the next button would do that glowing it usually does when you switch but it stays like that for awhile and the song doesnt change my ipod just force quits out of mu

  • Regarding Exit/IDOC Related TD

    Hi, Can anybody tell me what is the code required to be written folowing TD points. Before below TD i have populated one internal table in userexit_save_document exit and submitted following new program need to be written as below: SUBMIT gv_prog WIT