Table join and Logical databasein a same query

Hi Experts,
I have an existing query which is created using table join. I now want to add a logical database in the same infoset.
Is it possible to add a logical database in the same infoset?
Regards,
Prakhar

Hi Prakhar,
If you see the  below scren,  you can use data source either Table join using basis table or Logical database.
but if you need ldb with some addition table field then you can data retrieval by program step or you can use LDB with doing some code in inside  your infoset.
Regards,
Prasenjit

Similar Messages

  • Ad Hoc Query - reporting on both PA and OM data in same query.

    Is it really not possible to report on both PA and OM in the same query?  Does the two different infosets prevent you from doing this? 
    As a workaround I can run two separate queries and just join the data using Excel.  However - I'm having some trouble using the OM infoset.  I have a list of job ID's and I'm trying to report on the job short text and the "duty code" which is a custom OM object.  Is there a way to add this custom object to the infoset? 
    Also, I'm finding it difficult to report on the relationships as "Object" is always listed as an output ONLY.  Is there a way to make it available as an input?

    If you are using logical database PNP, then you can try to add infotype and check the option 'Infotype of related objects' .
    This will allow you various HRP tables to add to your query by the relationship.
    If you check responsiblity you can use relationship B007 and selecting 1000 would give you the short text and long text of the ID.
    This is a very good option available for PNP database.
    Regards,
    SC

  • Difference between physical join and logical join

    Hi Gurus,
    Can anyone tell me what is the difference between physical join and logical join
    Thanks,
    Chandra

    Hi,
    A physical join is at the physical layer and defines the join between two physical tables. Logical joins live at the BMM (logical) layer and define a join between two logical tables.
    The important differentiation is that at the BMM layer you do not tell the OBIEE server how to do the join, you just tell it that there is a relationship between these two logical entities. When the server comes to this logical join it will use the information in the physical joins and decides how the two logical tables are joined together.
    In BMM you use complex joins to establish which logical tables are joined which another, the OBI EE server will go to the physical level to search the physical join to make the query. You can also use physical joins in the BMM to override the join in the physical layer but only in very specific conditions.
    If you also set complex join in the physical layer OBI EE won't be able to construct the physical query.
    Hope this answers your question.
    Award points if helpful.
    Thanks,
    -Amith.

  • Tables/Joins for logical tables being combined

    I have 2 logical tables set up that have multiple physical table sources (using map to these tables). Some of the physical sources are the same in each logical table. It seems that when I make selections from Answers and look at the SQL, it is picking tables from both logical tables (instead of just the one I used). It is also grabbing the content (additional 'where condition') from the other logical table as well. Why is it doing that?

    Yes it is kind of limitation in obiee. But there are some solutions which might deviate from best practices.
    Sol 1. Snowflake the dimensions in Business Model. Rather than merging both of them into single logical table, separate them into two different logical tables.
    Sol 2. For the logical table , have two LTSs. First LTS will have both tables and all columns mapped to both tables. Second LTS will have only main table, Columns belong to that table only mapped. In this way when you selected columns related to first source system will use second LTS which has only only one table.
    - Madan Thota

  • Item and service invoices in same query

    Hi All,
    i want item based and service based invoices in same query but in this query when user individuality select item or service it shows records how can i get both in same query
    SELECT
    1 as sr,'Invoice' [Document Type],
    t0.docentry,
    T0.[CardCode] as 'BP Number',
    T0.[CardName] as 'BP name',
    t0.numatcard as 'Vendor reference No.',
    t0.u_loc as 'Location name' ,
    t4.state ,--'Null')  as 'State' ,
    T0.[DocNum] as 'Document Number',
    --T0.[DocType],
    t0.docdate,
    ISNULL(T1.ItemCode,'Service Item') AS 'Item Code',
    T1.[Dscription],
    T1.[Quantity],
    t3.name as 'MAG',
    t1.linetotal as 'Net Amount',
    t1.vatsum as 'Tax Amount',
    (t1.linetotal + t1.vatsum) as 'Invoice Value'
    FROM [dbo].[OINV]  T0
    INNER JOIN [dbo].[INV1]  T1 ON T0.DocEntry = T1.DocEntry
    left outer join owhs t4 on t1.whscode = t4.whscode
    LEFT JOIN [dbo].[OITM] T2 ON T1.ItemCode = T2.ItemCode
    LEFT JOIN [dbo].[@ITMG]  T3 ON T2.U_itmg = T3.Code
    WHERE
    T0.[DocType] = '[%0]' and t0.cardcode between [%3] and [%4] and t0.docdate >= [%1]and t0.docdate <=[%2]
    union
    SELECT 2,'Credit Memo' [Document Type],
    t0.docentry,
    T0.[CardCode] as 'BP Number',
    T0.[CardName] as 'BP Name',
    t0.numatcard as 'Vendor reference No.',
    t0.u_loc as 'Location name' ,
    t4.state ,--'Null')  as 'State' ,
    T0.[DocNum] as 'Document Number',
    --T0.[DocType],
    t0.docdate,
    ISNULL(T1.ItemCode,'Service Item') AS 'Item Code',
    T1.[Dscription],
    -T1.[Quantity],
    t3.name as 'MAG',
    -t1.linetotal as 'Net Amount',
    -t1.vatsum as 'Tax Amount',
    (t1.linetotal + t1.vatsum) as 'Invoice Value'
    FROM [dbo].[ORIN]  T0
    INNER JOIN [dbo].[RIN1]  T1 ON T0.DocEntry = T1.DocEntry
    left outer join owhs t4 on t1.whscode = t4.whscode
    LEFT JOIN [dbo].[OITM] T2 ON T1.ItemCode = T2.ItemCode
    LEFT JOIN [dbo].[@ITMG]  T3 ON T2.U_itmg = T3.Code
    WHERE
    T0.[DocType] = '[%0]' and t0.cardcode between [%3] and [%4] and t0.docdate >= [%1]and t0.docdate <=[%2]
    pls help me
    ketan..........

    Hi Ketan,
    You don't need to add anything to this query.  When you select service type documents, the State would automatically become NULL.
    Thanks.
    Gordon

  • How to collect physical and logical disk counters using query?

    Hai friends, i want to view physical and logical disk counters in sql server like Avg. Disk sec/Read, Avg.
    Disk Bytes/Read, Avg. Disk sec/Write, Avg.
    Disk Bytes/Write, etc.,  Can anyone tell me how to vies this by using query?
    Thanks in advance..

    Hai friends, i want to view physical and logical disk counters in sql server like Avg. Disk sec/Read, Avg.
    Disk Bytes/Read, Avg. Disk sec/Write, Avg.
    Disk Bytes/Write, etc.,  Can anyone tell me how to vies this by using query?
    Thanks in advance..
    Hello,
    Sys.dm_os_performance counter will only show counters related to SQL server not Physical disk if you run below query in SQL server it will not return any value so no disk counter is present.You will have to see it using perfmon.
    select * from sys.dm_os_performance_counters where counter_name like '%disk%'
    This can also be done through power shell but I dont have experience with that.You can search net for power shell query to see Windows perfmon counters
    Please mark this reply as the answer or vote as helpful, as appropriate, to make it useful for other readers

  • Printing a Table Control AND ALV grid from same report

    Hello,
    I am trying to figure out how to print the output of my report, which consist of a table control and a OO-driven ALV grid under it. i tried several possibilities but I only get the ALV in my spool....?
    Answers will be rewarded !

    Keep a break point in that method. Press print in the ALV, check it stops in the break point. If yes then you can use write statement, the values what ever u r writing it come in the print-out. If the control doesn't stop in the break point then there is some problem in the method declartion.
    Check my code - I written every thing in the global declaration.
                          ALV Class Definition
    CLASS lcl_event_receiver DEFINITION.
      PUBLIC SECTION.
        METHODS:
            handle_top_of_list
                FOR EVENT print_top_of_list OF cl_gui_alv_grid,
            handle_end_of_list
                FOR EVENT print_end_of_list OF cl_gui_alv_grid.
    ENDCLASS.                    "lcl_event_receiver DEFINITION
    DATA: o_event_receiver   TYPE REF TO lcl_event_receiver.
                          ALV Class Implementation
    CLASS lcl_event_receiver IMPLEMENTATION.
      METHOD handle_top_of_list.
        DATA: lws_top1(20) TYPE c,
              lws_top2(150) TYPE c,
              lws_top3(150) TYPE c,
              lws_len_file TYPE i,
              lws_file(80) TYPE c,
              lws_file1(100) TYPE c,
              lws_file2(100) TYPE c,
              lws_file3(100) TYPE c.
        WRITE: / text-001.
    *Date
        CONCATENATE text-008 ws_date INTO lws_top1 SEPARATED BY space.
        WRITE : /1 lws_top1.
    Source File Name
        WRITE: / text-009.
        lws_len_file = STRLEN( p_upload ).
        IF lws_len_file < 80.
          MOVE p_upload TO lws_top2.
          WRITE : /1 lws_top2.
        ELSE.
          MOVE p_upload TO lws_file.
          MOVE p_upload+80(48) TO lws_file1.
          DO.
            IF lws_file+79(1) EQ '\'.
              EXIT.
            ELSE.
              CONCATENATE lws_file+79(1) lws_file2 INTO lws_file2.
              SHIFT lws_file RIGHT.
            ENDIF.
          ENDDO.
          IF lws_file2 IS INITIAL.
            MOVE lws_file TO lws_top2.
            WRITE : /1 lws_top2.
            WRITE : /1 lws_file1.
          ELSE.
            CONDENSE lws_file.
            MOVE lws_file TO lws_top2.
            WRITE : /1  lws_top2.
            CONCATENATE lws_file2 lws_file1 INTO lws_file3.
            WRITE : /1  lws_file3.
          ENDIF.
        ENDIF.
      ENDMETHOD.                           "handle_top_of_list
    ENDCLASS.                    "lcl_event_receiver IMPLEMENTATION
    Regards,
    Prakash.

  • Retrieving spatial and non spatial in same query.

    I have hacked out queries that retrieve and display GEOM Vertices in a JSP using sdoapi.
    I have hacked out queries that retrieve standard format data types and display them in JSP using jdbc, java.sql and oracle.sql.
    I cannot figure out an easy way to blend the two. It seems as though there is no choice but to make two separate queries to the same table in the database in order to present all the columns of an entire row result if a row contains both spatial and standard data.
    Does anyone have any ideas of how this can be done without making two separate calls??

    I'm not sure why you need to print to a file or why you feel you need to do multiple queries to fetch spatial and non spatial attributes. Here are some snippets of SDOAPI based code that may help or may end up confusing matters even more. Hopefully they'll help. I assume you can modify the code to print coordinates to whichever output stream you require for displaying them. "..." indicates that some other code goes here.
    DriverManager.registerDriver(new OracleDriver());
    m_conn = DriverManager.getConnection(url, user, password);
    m_adapter = OraSpatialManager.getGeometryAdapter("SDO", "9.0.1", STRUCT.class, STRUCT.class, null, m_conn);
    Statement stmt = null;
    ResultSet rs = null;
    stmt = m_conn.createStatement();
    String query = "SELECT " + idName + ", " + columnName + " FROM " + tableName;
    rs = stmt.executeQuery(query);
    while (rs.next())
    Object id = rs.getObject(1);
    Object sdoGeom = rs.getObject(2);
    Geometry geometry = ((AdapterSDO)m_adapter).importGeometry(sdoGeom, nDim);
    // do something with the ID column
    // print the geometry's coordinates
    processGeometry(geometry);
    public void processGeometry(Geometry geometry)
    if (geometry instanceof Point)
    Point point = (Point) geometry;
    System.out.println("Point: SRID = " + point.getSpatialReference().getID()+ " (" + point.getX() + ", " + point.getY() + ")");
    else if (geometry instanceof LineString)
    LineString lineString = (LineString) geometry;
    System.out.println(lineString.getNumPoints() + "-point LineString: ");
    for (Enumeration pointEnum = lineString.getPoints(); pointEnum.hasMoreElements();)
    CoordPoint point = (CoordPoint) pointEnum.nextElement();
    System.out.println("\t\t(" + point.getX() + ", " + point.getY() + ")");
    else if (geometry instanceof Polygon)
    Polygon polygon = (Polygon) geometry;
    System.out.println((polygon.getNumRings()) + "-ring Polygon: ");
    LineString exteriorRing = (LineString) polygon.getExteriorRing();
    System.out.println("\t" + exteriorRing.getNumPoints() + "-point exterior ring:");
    for (Enumeration pointEnum = exteriorRing.getPoints(); pointEnum.hasMoreElements();)
    CoordPoint point = (CoordPoint) pointEnum.nextElement();
    System.out.println("\t\t(" + point.getX() + ", " + point.getY() + ")");
    for (Enumeration ringEnum = polygon.getInteriorRings(); ringEnum.hasMoreElements();)
    LineString interiorRing = (LineString) ringEnum.nextElement();
    System.out.println("\t" + interiorRing.getNumPoints() + "-point interior ring:");
    for (Enumeration pointEnum = interiorRing.getPoints(); pointEnum.hasMoreElements();)
    CoordPoint point = (CoordPoint) pointEnum.nextElement();
    System.out.println("\t\t(" + point.getX() + ", " + point.getY() + ")");
    ...

  • Using lag and rank in the same query

    Hi
    I am trying to find out the difference in time between peoples memberships and also the order that these memberships are taken out in. So far I have added in a rank statement to work out the order the memberships were created in, but now want to look at the difference between the dates returned. The SQL I used is:
    SELECT owner_party_id,
    mem_number,
    support_id,
    mem_start_date,
    RANK() OVER (PARTITION BY owner_party_id ORDER BY mem_start_date ASC) MEMBERSHIP_SEQUENCE
    FROM membership_all
    WHERE version_type = 'CUR'
    AND owner_party_id IN ('65051', '65051', '65348', '65348', '65607', '65607', '65607')
    to get:
    "OWNER_PARTY_ID"|"MEM_NUMBER"|"SUPPORT_ID"|"MEM_START_DATE"|"MEMBERSHIP_SEQUENCE"
    65051|318874751|8014747|01-MAR-10|1
    65051|412311060|21502883|15-AUG-12|2
    65348|308672459|3526913|01-MAY-10|1
    65348|409951130|20950524|18-JUN-12|2
    65607|315830192|7510133|17-MAY-10|1
    65607|406448110|20024246|16-MAR-12|2
    65607|409738130|20903556|14-JUN-12|3
    Now I would like to calculate the difference between the start dates of each of the owner_party_id groups, so to get something like this:
    OWNER_PARTY_ID|MEM_NUMBER     |SUPPORT_ID|MEM_START_DATE     |MEMBERSHIP_SEQUENCE|Diff
    65051|318874751|8014747|01-Mar-10|1|     
    65051|412311060|21502883|15-Aug-12|2|898
    65348|308672459|3526913|01-May-10|1     
    65348|409951130|20950524|18-Jun-12|2|779
    65607|315830192|7510133|17-May-10|1     
    65607|406448110|20024246|16-Mar-12|2|669
    65607|409738130|20903556|14-Jun-12|3|90
    I think that I need to use the Lag function in, but I am not too sure if it can be linkited to look at the data within a grouping of owner party id, as it would make no sense to calculate the difference in dates for two different owner party ids.
    Any advice much appreciated.
    Thanks
    Edited by: 992871 on 09-Mar-2013 23:34

    Couple notes:
    1. You wrote you want to get order that these memberships are taken out in, however, both your and Etbin's queries calculate order within each owner_party_id and not across all members. If you want to get rank and difference in time regardless of member's owner_party_id remove PARTITION BY caluse.
    2. You might want to use DENSE_RANK and not RANK depending how you want to display rank. If two people joined at the same time and were second in rank, analytic RANK will be:
    RANK
    1
    2
    2
    4
    5
    .while DENSE_RANK:
    DENSE_RANK
    1
    2
    2
    3
    4
    .SY.

  • FCP Studio and Logic Pro on same rig?

    Can Logic and FCP be used on the same system? I originally bought my rig to use both programs, but I have had HUGE issues with my rig crashing since I bought it. Logic (w/ Video Track) crashed when using 3rd party plug-ins or when just using internal sounds. Tried all sorts of fixes, and had my pro tech-xpert investigate these issues a few times over 3 months. Right now, I have to totally shut down every 20-30 mins. to insure smooth operation of Logic w/o plug-ins, or very minor plug-in use (less than 3 tracks) w/ or w/o Video Track.
    I've heard that Logic 7.2 can only use up to 2 GB RAM, and previous to the .2 rev Logic couldn't access my Quad processors. Is this true? The latest solution to these issues is to remove 4GB RAM and just use my rig for Logic. Is this the only solution anyone knows of? (my tech-xpert says my issues all seem to be memory-related)
    I hadn't tried to start FCP Studio on my rig at all. In fact, my tech-xpert uninstalled FCP Studio during a 48-hr repair/test. I did have issues w/ DVD Studio Pro crashing my rig when I tried to burn a DVD.
    Any and all help/suggestions appreciated in advance.
    Quad G5 DD   Mac OS X (10.4.6)   6.5 GB RAM

    Do you have the newest driver for the mobile pre?
    I sometimes use a Fast Track Pro and it works on 10.8 But sometimes have problems right after selecting it as input.
    I like M-Audio gear but if you are having trouble with two of there interfaces now, maybe you should look into another brand.

  • Using main stage and Logic Pro at same time?

    Hi all,
    Is it possible to use Mainstage to play sounds and at the same time take the sounds and with a Firewire mixer record the out of mainstage into Logic Pro? I'd like to do this internally without using an additional soundcard.
    I could use my FastTrack Pro to control the sounds in Mainstage and then use the Outputs of the FastTrack Pro to feed into the Firewire Mixer and then Record the performance in Logic Pro.
    Any ideas?
    Thanks
    Earl Green

    yep ... I do it like that all the time.
    Soundflower is your friend for piping audio out of mainstage into an audio track in Logic.
    http://cycling74.com/products/soundflower/
    To capture midi, just create an empty software instrument in logic and leave it record enabled (i.e. uncheck "open library" when creating it, and then just never select a software instrument to go on the track). This will record all the midi messages you send to mainstage.
    Granted, that only gets you so far. Playing that midi track in Logic isn't going to make any sound until you assign a software instrument to it, but it can be handy.
    A lot of times I'll record jam sessions with my band this way. Usually I'm playing pretty simple patches. 90% of the time it's just the Steinway samples, or NI B42 for organ stuff. If we do something particularly brilliant, but I flubbed the keys, I'll go into logic and manually assign whatever patch I was using in mainstage to it, then edit the midi.
    You could, in theory use something like the IAC device to route midi back OUT of Logic, into MainStage (and then capture the audio out of mainstage back into logic with soundflower). Essentially making MainStage into one big software instrument in Logic. I've never tried it, but others on this board have posted about doing this before, and I don't see why it wouldn't work.
    I really wish Apple would just setup Mainstage to work this way out of the box. It'd be an incredibly powerful tool.

  • Has Anyone tried to Launch GB and Logic at the same time?

    I launch both of the and GB causes logic to freeze
    when i quite GB logic works fine
    is this a bug?
    or whats the work around
    stash

    Well I was Tryna See About this AUnetSEND and AUnetRECEIVE thing
    between Logic and GB so i can work with my boddy on the other side
    1) I manage to launch both by switching GB to Internal Sound Card and leaving logic on ma M-Audio
    2) Down side is for some reason i can only get access to AuNetSend and not AuNetRecieve
    why ?
    it doesn't appear in logic, GB, or even Waveburner
    but it appears as ticked in the Logic/Waveburner AU manager setup
    whats the deal
    can anyone try this this is just experiment just to see if it'll work
    and the real thing will happen on the other side over networking
    stash

  • Group by order by in same query

    Hi,
    I am wondering whether it is possible to use group by and order by in same query
    For example if i have a table like the one below
    Col1 Col2 col3
    C 36 2
    A 25 5
    B 12 8
    A 25 6
    B 12 9
    C 36 1
    A 25 7
    I need a result like below
    A 25 5
    A 25 6
    A 25 7
    B 12 8
    B 12 9
    C 36 1
    C 36 2
    can the select statement with group by and order by solve this? How?

    Yes you can - though I am not sure that it is what you want. In your example you do not need to group the data, you just need to order by the first column, then the third. If required, you could also throw in the second column;
    SQL> with t as  ( 
       select 'C' col1, 36 col2, 2 col3 from dual union all 
       select 'A', 25 ,5 from dual union all 
       select 'B', 12 ,8 from dual union all 
       select 'A', 25 ,6 from dual union all 
       select 'B', 12 ,9 from dual union all 
       select 'C', 36 ,1 from dual union all   
       select 'A', 25 ,7 from dual)  
    select col1,col2,col3  
    from t
    order by col1,col3
    COL1       COL2       COL3
    A            25          5
    A            25          6
    A            25          7
    B            12          8
    B            12          9
    C            36          1
    C            36          2

  • Regarding table join in SQVI

    Experts,
    I  want to develop one query in SQVI.
    My requirement is as below.
    I want to develop a query in SQVI, which will show me for which materials( of material type ZPRT in my case) for which source list doesn't exist.
    For this, I am developing a query in SQVI by joining table MARA& EORD, please guide me how to proceed?
    Regards,
    Shailendra
    Edited by: Shailendra Sabale on Jul 8, 2009 4:52 AM

    Hi
    It is no problem if you decide to use table MARA and EORD only, then just go to SQVI.
    but for the better result you may add MARC table, since EORD table is plant specific as well as MARC table.
    here we go:
    - name your quick viewer --> choose "Create" button
    - specify the title as you like, data source: Table Join, and choose "Basis mode" option
    - insert table MARA, and EORD subsequently (check your join condition as MARA-MATNR and EORD-MATNR)
    - press Back button
    - on the "List. fld. select" tab, you may select field Material Type, Material Number, Account number of Vendor (EORD-LIFNR)
    - on the "Selection field" you may select Material type, Material number --> as a parameter in your selection screen.
    - choose Save, and Back button, and Save again if prompted.
    - then you can test it (execute)
    hope it helps,
    rob

  • Self Join and Aggregate Functions

    Hi all,
    I am trying a query in TOAD where I need to use an aggregate function MAX and a self join using a subquery. Its working fine when there is no aggregate function but when I tried to use the MAX function then its running for infi time. Is it because of the invalid joins? or because of the usage of the self join and aggregate func?
    The query contains some other tables too....
    Any one please help....
    Thanks in advance,
    G

    Toad will bring back a limited set of rows and present them to you giving the impression that the work is done. Adding an aggregate function requires the entire resultset to be traversed.
    Yes, post the 2 queries to verify what I am saying.

Maybe you are looking for