Query generation basic documentation

Dear Friends,
Is there any documentation for query writing.
Ex.
How to use inner join , why?
what is T0 (normally we observed in query)
Syntax and its use.
Overall, i want fundamentals of making query.
Regards,
MAhesh.

Hi,
   The document u r looking for might not be available in sap documents but u can better search for sql tutorials.
As far as u asked about T0 , its nothing else but just a alias name used for the first table used in a query.
I.E.
   if we want a report using two tables then either we can write
select ordr.docnum,ordr.docdate,rdr1.itemcode from ordr innerjoin Rdr1 on ordr.docentry= rdr1.docentry
or else u can replace  ordr with T0 Nd rdr1 with T1
and the query wud look like
Select T0.docnum,T0.docdate,T1.itemcode from  ordr T0 innerjoin Rdr1 T1 on  T0.DocEntry = T1.DocEntry .
and as u asked about the basic syntax
then a simple query format is
Select columnname from tablename where 'specify ur conditions'
Hope this might be helpful to u .
Thanks
Abhishek

Similar Messages

  • Please send me CRM middle ware basics documentation

    Hi Gurus,
            Please send me middleware basics documentation. my id [email protected]
    Regards,
    Ramakrishna.

    Hi Tulasi,
      Look at <a href="http://help.sap.com/bp_crmv250/CRM_DE/index.htm">SAP Best Practices for Customer Relationship Management - V2.50</a> -> Technical Information ->Building Block :
    B01: CRM Generation
    C71: CRM Connectivity
    B09: CRM Customizing Replication
    Regards.
    Manuel

  • Ad-hoc query generation question

    I have a LTS which has 5 tables -
    Item,
    Purchase_Categories,
    Order_Management_Categories,
    Inventory_Categories,
    Costing_Categories
    Now each %_categories table is joined to Item table in physical layer. In the LTS however, each %_Categories table has an outer join with the Item table so that if a category does not exist, the item is still displayed.
    When I run a query where I select a column from Item and a column from Purchase_Categories, OBIEE still generates a query
    SELECT ITEM.COLUMN1,
    PURCHASE_CATEGORIES.COLUMN2
    FROM ITEM left outer join purchase_categories ON ...
    left outer join order_management_categories ON ...
    left outer join inventory_categories ON...
    left outer join costing_categories ON ....
    I was expecting that OBIEE would generate a query select only the tables which were need i.e. the expected query was -
    SELECT ITEM.COLUMN1,
    PURCHASE_CATEGORIES.COLUMN2
    FROM ITEM left outer join purchase_categories ON ...
    I have seen that in some cases, OBIEE selects only the table that is required to generate the join based on the column selected, even though there are multiple tables in the joined in the LTS i.e. if the query is selecting columns from only 1 table and there are 2 tables in the LTS, OBIEE generates a query with only one table which has the column being selected.
    Why this difference in behavior during query generation ? Why does OBIEE intelligently select a specific table from the LTS definition some case and in other cases does not ?

    In case of outer join oracle applied all the join conditions defined among LTes. In normal joins it is able to figure out the correct source for column and does the trimming.
    Edited by: user596996 on Mar 20, 2009 6:33 AM

  • Query Generation for no apparent reason??

    When looking at the statistics in 0TCT_C02, we have noted that our queries regenerate or optimize multiple times each day.  I have tested this with a single query and I was sure to go into RSRT and turn off the optimization option.  Exceedingly longs times in 0TCT_C02 for event 3010 (OLAP: Query Generation).  We are talking times on the order of 45 seconds. I know that each query is supposed to be regenerated once every 31 days by default.  What else could be triggering this behavior?
    Examples:
    Date Time (HH:MM)   OLAP Gen Time (3010) from view RSDDSTAT_OLAP
    11/10/08  00:00     0.207153
    11/10/08  01:06     46.295823
    11/10/08  02:17     0.382898
    11/10/08  02:22     0.047491
    11/10/08  03:00     0.527515
    11/10/08  03:00     0.037425
    11/10/08  03:00     0.031306
    11/10/08  03:00     0.031065
    11/10/08  03:00     0.030289
    11/10/08  12:26     27.802359
    11/10/08  12:56     0.148548
    11/10/08  13:04     0.255053
    11/10/08  13:08     0.345807
    11/10/08  13:08     0.033123
    11/10/08  13:08     0.032887
    11/10/08  13:14     0.448533
    11/10/08  13:14     0.074349
    11/10/08  13:14     0.043456
    11/10/08  13:14     0.040294
    Why would it regenerate multiple times a day?  How do we get this to stop or at least control it better?
    (The query itself has not been changed since August of this year).
    Thanks for any info:
    Mitchell

    Hi there.
    The reasons why a query is regenerated :
       - Template changed                                     
       - Does generated report exist                          
       - Infoprovider changed                                 
       - Key figure / chararacteristic changed or deleted     
       - Report definition changed                
    If you are loading data regularly during the day, this may cause the regeneration to occur. SAP Note 1137994 should be helpful for this. SAP Note 1056259 talks about query generation and has further Notes for optimization. See section 4.
    Hope this helps,
    Karen

  • Report for query generation

    Hi,
    Is there any report available in BI for Query generation based on particular cube/multiprovider/ods.
    One way to do so is to go to RSRT & type in query name and generate it.
    But we have a large number of query's defined on a particular cube so we want a report that can help is to achieve the same for mass query generation.
    I have seen the report but i am missing the report name, can anyone help me to achieve the same.
    thanks
    dipika

    HI Sreekanth S :
    Thank for your giving , If  the operation  When i excute u201CRSR_GEN_DIRECT_ALL_QUERIESu201Dand input the name of my query equal to the function which i  generate reports in "RSRT"?
    Hope for your help.
    Thanks.

  • Re: query generation

    Hi there. Just something really quick. I am currently in the process of implementing automatic query generation. Oracle Spatial provides the Spatial Index Advisor as a relatively simple mechanism for viewing spatial data. When you make a spatial query you can view the structure of the query you just made in an SQL syntax. Is the sample code for generating these different queries in SQL made available anywhere on the Oracle site. Thanks Joe

    Hi
    In R/3 first you need to create the query in any of the below as you wanted it.
    Tcodes:
    quick query creation:  sqvi
    sq01--user group creation
    sq02--info set
    sq03--query creation
    Then after creating the query now create an generic data source, while creating
    give the option as SAPquery and now your data source is ready
    Hope this would be help ful
    Many thanks
    kiran
    Edited by: Kirun k on Jul 8, 2009 12:20 PM

  • Property "Query" for basic search iView - documentation needed

    the iView com.sap.km.cm.basicsearch has a property called Query. I need to know what are all the possible values for this property (SearchPluginName, SearchComponentName etc... and what do these values represent?! ). Are these documented somewhere?

    Hi Tiberiu,
    check this:
    https://www.sdn.sap.com/irj/sdn/thread?threadID=197279
    Regards, Karsten

  • Automation of Query generation and Conversion to Flat File CSV

    I have a requirement for Generating / Executing the refresh for the existing Query IN BEX automatically on 3 rd Business day of Every Quarter in BEX Analyzer AND also to convert it to flat file after generation. Please give me some documents or exact steps on how to go about this
    automation. Please reply me in detail and soon
    Thanks
    Soniya

    Hi Sir, I will be very grateful if u can clarify
    1. User want the flat  file on the Company Server, which means there are folder on my company BMW server , and he wants to see the flat file there so that he can review it
    2. I saw some AL11 and directories how can I create my directory or Create the file in DIR_HOME and see the file in flat file format it shows like a screen which my user do not want, he just want a flat file.
    3.Please suggest me if this method rscrm_bapi will work or should u suggest download scheduler or report agent and how.
    4. Sorry for the question but my problem and requirement of user is not solved
    please reply soon
    thanks
    soniya

  • Oracle BI Vs Sievel Analytics 7.8.x in Query Generation.

    Hi All,
    In Siebel Analytics 7.8.x if you have 10 columns in the Criteria and if you are using only two columns in the Pivot table view, the query is generated to using only columns used in Pivot view. Where as in Oracle BI it uses all 10 columns in the criteria.
    Is this a bug? Or any instanceconfig.xml parameter exists to control this behavior?
    Our Aim have different view (each view uses 2 or 3 columns) and use View Selector
    This is causing major issue in our project. Please let me know if any one faced this issue and how to resolve this.
    Thank you.

    Yes, you can you can keep your apps at 7.8 but use OBI EE 10g. For OBI EE the DWH created through the BI Apps is just a data source.
    One thing though: in order to be able to make full use of the 10g funtionalities regarding time series funcitons (todate and ago), you will need to fit your W_DAY_D dimension to the 7.9 standard. For that, please open anew post in the Apps forum since this discussion doesn't belong here. Business Intelligence Applications
    I'll post my documentation on the upgrade steps there then.
    As for upgrading Infa, this is a bit more tricky. You need to make suzre that DAC 7.8 can still fire all its commands at a 8.1.1. instance of Infa. (Haven't tried that one yet).
    Cheers,
    C.

  • Need basic documentation for Adobe Reader X

    Can anyone point me to documentation that will explain what document properties are needed to be able to highlight text in a document?  The document "Adobe_reader_x_help.pdf" does not discuss this at all.  I need to highlight text in an academic document, and all permissions are enabled except Document Asembly, Signing, and Creation of Template Pages.
    "Commenting" permission is available, and an ordinary person of a basic level of intelligence would assume that includes highlighting of text. At the same time, "Content Copying" is set to Allowed but I can't seem to do that either, so I am left wondering whether this is an idiotic feature designed by an idiot or merely an idiotic bug.
    FWIW Adobe is BEGGING to be slapped with an unfair trade practices class action based on its blatant attempts to leverage its monopoly over the PDF file format into sales of expensive-*** Acrobat just to perform basic features, like highlighting text, that actually WORK without having to purchase a product for hundreds of dollars.

    Adobe Reader X (on the desktop) can highlight text in any PDF file provided it is not directly forbidden by a security setting - so any unsecured PDF can be highlighted, as can any secured PDF with "commenting" allowed in the security properties. Highlights are just another form of comment.
    Previous versions of Adobe Reader could not apply highlights without Reader-extended permissions set by Acrobat or LiveCycle, but Adobe decided with version X to allow comments and sticky notes by default.
    ...and FWIW, the PDF format is an open ISO standard, used by hundreds of software developers besides Adobe. Yes of course the Acrobat Family sets the standard for working with PDF content, as Adobe invented the thing; but they don't have a monopoly by any means except in specific areas of DRM, rich media and very advanced document editing. For example OS X can read and write PDFs natively, but to create files with scripting and interactivity you need a commercial application such as Acrobat.

  • Multiple Query Generation from Discoverer?

    Is there anyway we can generate multiple query reports in discoverer plus? I have a daily dashboard which we send out on daily basis which has multiple queries to generate certain numbers. And I have a stored procedure for this. Is it possible to have multiple queries in 1 workbook to generate the report? If yes, then how? If not then, can we have this stored procedure in disco admin tool in a specific business area which basically kicks the SQL and stores the data in a table within that business area and in disco plus tool we can then simply select all the data from that table to generate the report? I would really appreciate if anyone could answer this.
    Thanks,
    K

    Another interesting way you can prepare a table is a method I've just seen using Disco 4.x.
    We've made such a big deal on using triggers recently, that this was so simple, I must admit I never thought of it.
    What the user did was have a function that called a pl/sql routine that did all the work and created the table.
    Then in the Disco workbook, they specified workbook 1 - the first workbook that took in parameters from the users, and passed the parameters into the function (ie: a from date and to date).
    The workbook didn't return any column from any folders, etc. but just presented the calculation that called the function.
    So, in a nutshell, the user runs the first worksheet where 2 parameters are asked for. Then when finished, it means the table is now ready for the real action so they go to the 2nd. worksheet and it just runs without any parameters but refers to the table set up by the first worksheet.
    No parameter passing to the EUL, nothing fancy, but all done in the function that called the pl/sql routine. Very easy.
    So, for you, you should be able to use the same concept, but in batch, run the first worksheet (ie: putting in the 2 parameters), and then just run the 2nd. worksheet once the first is finished and the table setup.
    Hope it helps.
    Russ

  • Physical query generation: unneeded dimension tables get joined to the fact

    Hi there!
    The setup is the following:
    There is a logical fact table which is joined to 7 logical dimensions, it has 4 table sources which correspond to different time dimension levels (all other dimensions are mapped to Detail level).
    Time dimension logical table also has 4 different table sources (for days, months, quarters, and years).
    The data source is an Oracle Database 11gR2.
    The problem is:
    No matter what the logical query is, in the physical query all 7 joins are performed, even if the resulting data is then simply discarded. This results in very bad query performance.
    I feel that it is somehow related to the level-based fragmentation (since, for instance, inclusion of time dimension columns in SELECT list (not in WHERE) seems to affect physical queries), but lack sufficient knowledge to solve this problem or put up with it.
    My questions are the following:
    1) Have you ever encountered such a situation?
    2) Can unneeded joins be eliminated?
    2.1) If yes, how?
    2.2) If not, then why are they needed?
    Thanks in advance!

    Physical level:
    D01-D06 - ordinary physical tables.
    D_DATES - all time levels from dates to years, D_MONTHS - time levels from months to years, also D_QUARTERS and D_YEARS.
    F_DAILY - fact table joined to all of the D01-D06 and to D_DATES, F_MONTHLY - joined to D01-D06 and D_MONTHS, also F_QUARTERLY and F_YEARLY. All measure columns are the same.
    Logical level:
    D01-D06 correspond to ordinary logical tables with a single table source. Logical dimensions are created.
    D_TIME is a logical time dimension with four levels (dates, months, quarters, and years) and four table sources ( D_DATES, D_MONTHS, D_QUARTERS, and D_YEARS ).
    F is a fact table with four logical table sources ( F_DAILY, F_MONTHLY, F_QUARTERLY, and F_YEARLY ) with aggregation content levels set correspondingly.
    OBIEE correctly picks physical table sources for different time levels, but generates extremely inefficient SQL (joining all dimension sources in a WITH-subquery, doing ROW_NUMBER over a result set, and then discarding half the columns, which were not needed to start with).

  • Query tuning basics..

    Friends and gurus...
    OS: Linux
    DB: 11gR2
    Recently I have found myself trapped into many sql query tuning with and without bind variables and main aim of all tuning is to reduce total elapsed time displayed in AWR report.
    I found myself run all over the places just to identify problem and then try to solve it..
    with near to zero experience in query tuning I'm trying to learn this art and have below questions...
    Q.
    1. Identify problem: could somebody please list what all internal oracle tools available just to identify problem and what should be best approach?
    like sqltrace, explain plan, tkprof etc... list goes on so wanting to know which to follow and when...
    2. any idea how to get all details of steps listed in explain plan? since predicate information only list few steps where filter is used but some steps which takes long (hash join, nested loops) I don't know what caused it...
    3. how to identify problems in queries with bind variable?
    please note I don't have any 3rd party tool and all I work on is sqlplus session.
    thanks,

    khallas301, beside SB's reference to the Performance and Tuning Guide I want to point out that use of the AWR requires purchase of the extra cost EM Diagnositc and potentially also the Performance Pack License.
    You can use statspack if you do not have the EM liceses.
    How you approach what to tune depends a bit on the envornment. If only a few processes are having issues then you can look into customer complaints and tune what people are complaigning about. On the other hand if the entire system is having issues then you might want to identify critical processes and start with them.
    One approach would be to run sql trace on a critical process. Review the traces and tune the SQL statements you find having issues. Record the results and move on to the next critical process.
    Another approach would be to query the dynamic performance views for SQL with high logical IO counts, determine what processes the SQL is coming from, and tune that SQL.
    HTH -- Mark D Powell --

  • Query Generation error

    Hi,
    I am getting following error when running query on browser
    "Error in generating dataprovider"
    This happened after I created a Bex request to edit query in Bex Designer. I edited query in designer and saved it. Then when i clicked on execute query I am getting the above error.
    Thanks in advance.

    hi raj..
    chk these links..
    these are same as that of urs.. hope this will help you to get a clue...
    Error when generating dataProvider
    Error generating Dataprovider
    all the best..

  • Rso2 infoset query  generation procedure

    How to generate data source in rso2 using infoset query to get distinct record

    Hi,
       Generating Datasource from Infoset is not different from Generating DataSource from View or Function Module.
    Create infoset in the source system from SQ02.
    go to RSO2. Provide the Datasource Name. go wiht create.
    Select the Infoset Push Button, provide description.
    provide the infoset Name. Let me know if you have any Issue.
    Save the DataSource. check RSA3 for Data.
    Regards,
    Nagesh Ganisetti.

Maybe you are looking for

  • Copy oracle server data to remote system over internet

    Hi, I am using Redhat 4 linux system as Oracle 10g server. My database is in archivelog mode. I am not good at data guard so i am not using it. But i want to copy my archive log file to another linux system over internet. so that in case of server cr

  • Slow MacBook, what should I do? EtreCheck listed

    Problem description: MacBook is extremely slow and not functioning as fast as it did last year. I have sufficient storage so I’m not sure what the problem is. EtreCheck version: 2.1.6 (109) Report generated January 27, 2015 at 7:48:43 PM PST Download

  • How to display image in view

    Hi ,           I want to display an image in my one of the views?? How to do it??

  • Problem Moving XCode Project From iMac to MacBook

    I have been working with an Objective C library for iPhone apps using XCode on a iMac running OS X Lion 10.7.5 (11G63). My project builds fine on this system. I need to relocate the project to a MacBook Pro running OS X 10.8.4 (12E55). I have XCode 4

  • BoxLayout & Borders

    Hi ! I'm trying to add a JPanel to a panel using BoxLayout. When I set a border to the subPanel, it deasapear ! Here is the code : // Inside a class extending JPanel      private void initComponents()           setLayout(new BoxLayout(this, BoxLayout