Update with inner-left-right joins

On the net I find much confusing information. I am searching for examples about oracle update with joins.
Someone knows where I can find running examples? (especially Oracle 8i 9i)
Thanks
Gaetano Recchi

867873 wrote:
On the net I find much confusing information. I am searching for examples about oracle update with joins.
Someone knows where I can find running examples? (especially Oracle 8i 9i)
Thanks
Gaetano RecchiThere are lots of examples on-line if you just search for them. In particular search for a primer on ANSI SQL since "normal" SQL doen't use the inner terminology as much (though outer joins are still talked about).
Use your favorite search engine and look for ORACLE and ANSI SQL

Similar Messages

  • SQL statement that includes LEFT & RIGHT JOIN in the same statement??? Help

    Hi,
    How an I write an SQL statement with a GROUP BY that will both (a) include the NULL value from the left hand table, but also (b) include ALL columns from the right hand table. It's like I need a LEFT JOIN and a RIGHT JOIN in the query at the same time.
    Here's an example of the 2 tables I have and the result I'm after. As you can see I want the NULL's from Expenses Table summed, as well as include all categories from the right hand table (i.e. even if there are no expenses against them)
    Table = Expenses
    Amount Category
    $10 1
    $20 2
    $30 1
    $40 NULL {i.e. not yet categorised}
    Table = Categories
    ID Title
    1 Food
    2 Entertainment
    3 Travel
    4 Personal
    REQUIRED RESULT
    Category Total
    Food 40
    Entertainment 20
    Travel 0
    Personal 0
    NULL 40
    Thanks

    SQL> create table expenses (amount,category)
      2  as
      3  select 10, 1 from dual union all
      4  select 20, 2 from dual union all
      5  select 30, 1 from dual union all
      6  select 40, null from dual
      7  /
    Table created.
    SQL> create table categories (id,title)
      2  as
      3  select 1, 'Food' from dual union all
      4  select 2, 'Entertainment' from dual union all
      5  select 3, 'Travel' from dual union all
      6  select 4, 'Personal' from dual
      7  /
    Table created.
    SQL> select c.title category
      2       , nvl(sum(e.amount),0) total
      3    from expenses e
      4         full outer join categories c on (e.category = c.id)
      5   group by c.id
      6       , c.title
      7   order by c.id
      8  /
    CATEGORY                                       TOTAL
    Food                                              40
    Entertainment                                     20
    Travel                                             0
    Personal                                           0
                                                      40
    5 rows selected.Regards,
    Rob.

  • Trying to update 2 tables using right join (UPDATE Registrations RIGHT JOIN Registrations2)

    I am trying to update [01-POs] from [01-POs1]
    They both have the same fields and both have a primary field of [PO Number]
    The code below does not work:
    Update [01-POs] right join [01-POs1]
    On Registrations.[01-POs].[PO Number] = [01-POs].[PO Number]
    SET Registrations.TEXT_REGISTRANT_ID = Registrations2.TEXT_REGISTRANT_ID,Registrations.[Name] = Registrations2.[Name]
    REF:  https://social.msdn.microsoft.com/Forums/office/en-US/bea031e1-46cc-41b7-a8de-8c897c52019d/update-registrations-right-join-registrations2?forum=accessdev

    That is the problem, I don't understand this code at all, but I know what I hope it will do.
    I have one table that pulls from an oracle database the way I want it, then uploads to the live database.  At this time I delete all records from the main table, then import all new records (10,000+ each time).  This causes my database to grow
    in size very quickly (I have 7 of these type of tables).  My hope is that this will update the existing records, and append the new ones.  Bonus would be if it will delete the ones that are no longer valid (no longer on the oracle pull).
    [01-POs] is the main table that I want to pull from
    [01-POs1] is the live table, that I want to sync to [01-POs]
    [PO Number] is the key field (not auto number)
    The rest of the fields are all the same and need to be updated
    I hope this explanation helps.
    Note:  Registrations and Registrations2 are from the original code that I didn't know how I should change.

  • Disable switch to another virtual console with Alt-Left/Right

    I'm a Fish shell user, and the Alt-Left/Right keys are very useful for me. But in the virtual terminals those shortcuts are captured and cause a switch between the different terminals (like Alt-F1, F2 etc). My question is, how can I disable that Alt-Left/Right behaviour, since Alt-F1, F2... is more than enough for me.

    SanskritFritz wrote:
    I got one step closer to my goal:
    dumpkeys > my_console_keymap.txt
    vim my_console_keymap.txt # deleting the lines with Decr_Console and Incr_Console
    loadkeys my_console_keymap.txt
    really turns off the switching of consoles, but fish still doesnt get the Alt-Left|Right keys. At least nothing happens, so the situation got better, but I wonder how to pursuade the console to pass on the Alt-Left|Right combo. Any thoughts?
    I have the same problem. I can disable the default shortcut but the combination (Alt+arrows) has no effect at all then and I can't use it with any application. Any ideas?

  • Working through David's book - trouble with Control-Left/Right Arrow

    I have worked my way through David Nahmani's book in the Apple Pro Training series and it is EXCELLENT! It's the best investment I've made in a long time. The investment I made in the new computer and software would be so much less AWESOME had I not found this little gem. I do have a question, though...
    When it comes to the command keys, I can't get the Control-Left/Right Arrow commands to work. They are supposed to be zoom keys - but they just wipe my window left and right. I'm probably doing something wrong. Anyone know what it is?
    Thanks in advance for your help.
    Gina

    Gina,
    The problem is that Control + Arrow Keys is the default key command to switch between Spaces (window sets) in Leopard. So, here's what you do:
    1. Open System Preferences
    2. Click on "Exposé & Spaces" (top row, fourth icon from the left)
    3. Click on the "Spaces" tab
    4. In the bottom portion of the window you'll see a section for "Keyboard and Mouse Shortcuts", in the second pulldown menu change the setting from "^ Arrow Keys" to another of the choices. I personally use the second choice, which is Command + Option + Arrow Keys.
    Now, back in Logic your Control + Arrow Keys should be controlling your Arrange window zoom.
    Hope this helps!

  • Trouble With Left Outer Join

    I'm kind of new to using left outer joins, so I don't know if I'm doing it quite right. Right now there's only one table that may or may not have a corresponding record, so I'm only using left outer join on it. I get the error ORA-00904: "A"."SGBSTDN_PIDM": invalid identifier right now when I try to run my query. This gives me the impression that I need to use left outer join on all the tables in my FROM clause. Any suggestions on what I need to do?
    /*Get those students not awarded ACG1 yet with an entry in shrlgpa*/
    SELECT spriden_id id, spriden_last_name||', '||spriden_first_name name, sgbstdn_styp_code student_type,
    sorhsch_graduation_date hsch_grad_date,shrlgpa_hours_earned hours_earned,rorenrl_finaid_adj_hr hours_enrolled,
    0 AS disbursement_to_date, 0 AS offer_amt, 0 AS current_disbursement,
    rnvand0_unmet_need unmet_need, 'N' AS awarded
    FROM RCRESAR,RCRAPP1,SORHSCH,RORHSDT,SGBSTDN A,SORLCUR, shrlgpa, rorstat, ROBINST, spriden
    ,rnvand0
    LEFT OUTER JOIN rorenrl ON (A.sgbstdn_pidm = rorenrl_pidm)
    WHERE (RCRESAR_PELL_ELGBL = 'Y')
        AND  SORHSCH_GRADUATION_DATE>'01-JAN-2006'
        AND  RCRAPP1_CITZ_IND IN ('1','2')
        AND  RCRAPP1_CURR_REC_IND='Y'
        /*Possible change once rigorous curr. decided AND (RORHSDT_AP_IB_COURSES = 'Y' OR RORHSDT_REQ_COURSES='Y')*/
        AND RORHSDT_REQ_COURSES='Y'
        AND sgbstdn_stst_code = 'AS'
        AND  SGBSTDN_STYP_CODE IN ('F','H','T')
        AND (SORLCUR_DEGC_CODE LIKE 'B%' OR SORLCUR_DEGC_CODE LIKE 'A%'
        OR SORLCUR_DEGC_CODE = 'UND')
        AND sorlcur_seqno = (SELECT MAX(sorlcur_seqno)
                              FROM sorlcur
                              WHERE sorlcur_pidm = A.sgbstdn_pidm
                              AND sorlcur_term_code = &enrollment_term)
        AND  SORLCUR_CACT_CODE='ACTIVE' 
        AND rorenrl_term_code = &enrollment_term
        AND shrlgpa_hours_earned BETWEEN 0 AND 29
        AND shrlgpa_gpa_type_ind = 'O'
        AND rorstat_pckg_comp_date IS NOT NULL
        AND  A.SGBSTDN_TERM_CODE_EFF = (SELECT MAX(B.SGBSTDN_TERM_CODE_EFF)
                                                                            FROM SGBSTDN B
                                                                             WHERE B.SGBSTDN_PIDM = A.SGBSTDN_PIDM
                                                                             AND sgbstdn_term_code_eff <= &enrollment_term
        AND NOT EXISTS (SELECT 'X'
                                        FROM RPRAWRD
                                      WHERE RCRESAR_PIDM = RPRAWRD_PIDM
                                          AND RCRESAR_AIDY_CODE = RPRAWRD_AIDY_CODE
                                          AND RPRAWRD_FUND_CODE = 'ACG1')
         AND rorstat_pidm = rcresar_pidm
        AND spriden_pidm = rcresar_pidm
        AND  RCRAPP1_PIDM    = RCRESAR_PIDM 
        AND shrlgpa_pidm = rcresar_pidm
        AND  SORHSCH_PIDM   = RCRESAR_PIDM 
        AND  RORHSDT_PIDM   = RCRESAR_PIDM 
        AND  SGBSTDN_PIDM   = RCRESAR_PIDM    
        AND  SORLCUR_PIDM   = RCRESAR_PIDM 
        AND rnvand0_pidm = rorstat_pidm
        AND  RCRESAR_INFC_CODE = RCRAPP1_INFC_CODE 
        AND  RCRESAR_SEQ_NO      = RCRAPP1_SEQ_NO  
        AND  RCRAPP1_AIDY_CODE = RCRESAR_AIDY_CODE
        AND ROBINST_AIDY_CODE = RCRESAR_AIDY_CODE
        AND  RCRESAR_AIDY_CODE = '&AIDY_CODE'
        AND rorstat_aidy_code = rcresar_aidy_code
        AND rnvand0_aidy_code = rcresar_aidy_code
        AND spriden_change_ind IS NULL
        ORDER BY name

    Frank Kulash wrote:
    Hi
    blackhole82 wrote:
    Yeah I realized that I was probably mixing styles after it wouldn't work. What you suggested does execute, so I assume it's right even though I'm not getting any rows at the moment. Don't assume it's correct: verify it
    I suggest re-writing the query using all ANSI syntax.
    Start with just two tables. Make sure that join is working.
    When you have something that works perfectly with just those tables, then add one more table.
    So if I wanted to left outer join onto shrlgpa too I would just need to add that underneath the join for rorenrl before the , and SORLCUR?In your existing query, it looks like shrlgpa is only connected to rcresar, using an inner join. Do you want to change that?At any rate, the order of tables using the old doesn't matter. Using ANSI notation, however, a join condition can only reference tables that have already been named in the same group of ANSI-joined tables.
    So you would probably would have to re-arrange the FROM clause.
    Sorry, I don't understand exactly what you want to do, so I can't tell you exactly how to do it.
    Make you best guess, and try it.
    If it doesn't produce the results you want, and you can't figure out how to fix it, then post the query, some sample data, and the desired results. If you post just the revised query, and a description of the problem, I'll try to answer, but without the sample data and desired results I can't guarantee that I can.Well I'm getting rows and the data seems to go with the query I had before using the outer join except for the records that have no record on shrlgpa. It appears that by having the clauses
    AND shrlgpa_hours_earned BETWEEN 0 AND 29
    AND shrlgpa_gpa_type_ind = 'O'that those I'm trying to pull in with the left outer join are being eliminated. Is it possible to still limit the hours earned while pulling in those who do not have a record on shrlgpa? Before I was just using a UNION to accomplish this, but I thought that I might be able to fine tune the query to eliminate the need for another UNION.

  • Translate JOIN syntax from LEFT JOIN, RIGHT JOIN to (+)

    I have looked through a lot of documentation, but have yet to see some concreate examples of how to code a JOIN when you are used to LEFT, RIGHT JOIN, etc.
    Could someone translate these, removing the LEFT OUTER JOIN, etc. and replace with the (+). I am fairly new to Oracle and have been using the others all along?
    SELECT *
    FROM LOCATION L
    LEFT OUTER JOIN DEPT D
    ON (L.LocationID = D.LocationID)
    LEFT OUTER JOIN EMPLOYEE E
    ON (D.DeptID = E.DeptID);
    SELECT *
    FROM EMPLOYEE E
    RIGHT OUTER JOIN DEPT D
    ON (D.DeptID = E.DeptID)
    RIGHT OUTER JOIN LOCATION L
    ON (L.LocationID = D.LocationID);
    SELECT *
    FROM LOCATION L
    FULL JOIN DEPT D
    ON (L.LocationID = D.LocationID)
    FULL JOIN EMPLOYEE E
    ON (D.DeptID = E.DeptID);
    Thank you.

    However,
    select  b.*
    from    table_a a
    ,       table_b b
    where   a.user_id = b.userid(+);<=>
    select          b.*
    from            table_a a
    left outer join table_b b
    on              b.user_id = a.user_idand
    select  b.*
    from    table_a a
    ,       table_b b
    where   a.user_id(+) = b.userid;<=>
    select            b.*
    from              table_a a
    right outer join  table_b b
    on                b.user_id = a.user_idI'm not sure about the full join.
    Edit:
    Ah, yes, I remember. The only way to do a full outer join with Oracle syntax (that I'm aware of) is to use UNION:
    select  b.*
    from    table_a a
    ,       table_b b
    where   a.user_id(+) = b.userid;
    union
    select  b.*
    from    table_a a
    ,       table_b b
    where   a.user_id = b.userid(+);

  • Crystal Report with 2 oracle datasources (left outer join) very slow

    I've made a crystal report with 2 oracle datasources (2 commands). I'm using crystal 10.
    These 2 data sources are linked with a left outer join.
    The report takes a while to run (more then one hour).
    i can run Both query's in a couple of seconds/minutes, but it looks like crystal is runniing the second query for each record in the first query.
    When i make the same report in BO. Just 2 queries with merged dimensions in the report, it is taking a couple of minutes to complete the report.
    Question is if somebody knows how crystal is handling these 2 different data sources.
    Is there any way to say to crystal to fetch the data of both queries and do the join after that?
    At the moment it looks like that crystal is going to the other datasource for each record in the first query, which will cost a lot of time.

    Joris,
    I've always had a bad time combining a Command with any other object. Performance seems to drop dramatically, just as you've described.
    I can't tell you specifically why, it falls off so bad...
    The solution I've used is to do a linked  server query (at least that's what it's called in MS SQL Server) I've never used Oracle, but I'd be VERY surprised if it didn't have that same feature. This will keep 100% of the processing on the server(s) and will get your run times back to what you would expect.
    HTH,
    Jason

  • Using Left Outer Join along with reference

    I have three tables.
    Table 1 : BOOK_DETAILS
    Fields: BOOK_ID, BOOK_NAME
    Table 2: BOOK_ISSUE_RECORD
    Fields: BOOK_ID, USER_NAME
    Table 3: BOOK_AUTHOR
    Fields: BOOK_ID, AUTHOR_NAME
    I have to link Table 1 and Table 2 with Left outer Join because even if the book is not issues to anyone, its name should come.
    Again I have to display the Book Author name for each Book.
    I am able to create a query with the Left outer join between Table 1 and Table 2. However I am not able to give a reference to the Table 3.
    Can any one please help me with this.
    Regards
    Hawker

    select  d.book_name,
            a.book_author,
            i.user_name
      from       book_details d
            join
                 book_author a
              on (d.book_id = a.book_id)
            left join
                 book_issue_recors i
              on (d.book_id = i.book_id)
    /SY.

  • Left Outer Join Help...

    Hi Everyone,
    I am still in the process of learning SQL, and I am having trouble specifically with the the left outer join.  I normally join tables using equijoin's, but I am not getting the right data set returns, and thought the using a left or right outer join would resolve the problem...
    Here is my SQL that is working properly with 1 left outer join.  I am building the query slowly so in the next SQL you will see where I am seeing the error.  I don't expect you to understand the data and columns I am trying to join, I believe the problems I am experiencing are related to syntax, and I am hoping you can find where my syntax errors are.
    select
      s.name as "Screen Name",
      sv.view_name as "View Name",
      s_view.name
    from
      s_screen s,
      s_screen_view sv
      left outer join s_view
      ON (sv.view_name = s_view.name)
    where
      sv.screen_id = '1-866A-1X3LU' and
      s.row_id = sv.screen_id and
      s.repository_id = '1-866A-1' and
      s_view.repository_id = '1-866A-1';
    Here is the SQL where I am experiencing the following error...
    Error:
    ORA-00904: "SV"."VIEW_NAME": invalid identifier
    00904. 00000 -  "%s: invalid identifier"
    *Cause:   
    *Action:
    Error at Line: 14 Column: 7
    Problematic SQL:
    select
      s.name as "Screen Name",
      sv.view_name as "View Name",
      s_view.name,
      s_applet.name as Applet
      --a.name as "Applet Name"
    from
      s_screen s,
      s_screen_view sv,
      s_view_wtmpl_it wti
      left outer join s_view
      ON (sv.view_name = s_view.name)
      left outer join s_applet
      ON (wti.name = s_applet.name)
    where
      sv.screen_id = '1-866A-1X3LU' and
      s.row_id = sv.screen_id and
      s.repository_id = '1-866A-1' and
      s_view.repository_id = '1-866A-1';
    Thanks in advance for your help.
    Chris

    Hi,
    cjpicc11 wrote:
    What is an Oracle style join vs. ANSI join?
    Would this be Oracle Style or ANSI Join?
      left outer join s_view
      ON (sv.view_name = s_view.name)
      left outer join s_applet
    Would this be Oracle Style or ANSI Join?
    s.row_id = sv.screen_id
    "Oracle style" or "old style" joins have commas between tables in the FROM clause, and the join conditions are all in the WHERE clause.  They do not use the keywords JOIN or ON.
    ANSI style joins have the keyword JOIN between tables (sometimes accompanied by other keywords, such as LEFT, OUTER or CROSS), and the join conditions are given in the FROM clause, usually after the keyword ON.
    The first example you gave is an ANSI style join.  It has the JOIN keyword, not a comma, between tables.
    The second example you gave:
    s.row_id = sv.screen_id
    could be part of either.  It could occur in an ANSI join (in the FROM clause, after the keyword ON), or it could occur in an old-style join (in the WHERE clause).

  • N78 keypad left/right keys sometimes not respondin...

    Hello there ...
    I faces some problems with the left/right Selection keys.
    they sometimes and for no reason don't respond, first i thought it is a problem with the keypad itself, so by pressing a little harder it would do the trick, but that's not the case.
    this bug occured in several applications/places.
    i have the latest firmware:
    Software Version: 12.046
    Software version date: 25-06-2008
    Custom Version: 12.046.051.1
    Custom version date: 25-06-2008
    Type: RM-235
    Latest Update: 24/2/2009
    Nokia n78-1 RM-235
    product code 0514523
    firmware 30.014

    thank you for replying...
    the latest version for my region is already installed.
    there is another problem which i forgot to mention, it's very annoying too!
    the right key most of the time goes to the main phone screen when i press on it to go back/cancel when inside any tool/application or webbrowser.
    sometimes it just behaves like the Hangup button when pressed!
    is this a software problem ?
    or may this be a faulty keypad ?
    thanks in advance!
    Nokia n78-1 RM-235
    product code 0514523
    firmware 30.014

  • Left outer join using date range returns too many rows

    I am trying to pull data for a website.
    Names table:
    company_name varchar2(30)
    julian_day varchar2(3)
    logins number(3)
    login_errors number(3)
    Given a julian date range (e.g. 250-252), I am displaying the information from the Names table.
    The problem is that I also need to display changes (increases/decreases) in the data. I do that by coloring the text based on a 10% increase/decrease. Data for the 3 days 250-252 would be compared to data for the previous 3 days 247-249.
    Not all companies will report data on all days, so some gaps in the data may exist. Therefore, I cannot do just a simple join.
    I am trying to write a query that will give me this information if the user chooses days 250-252.
    Company_name
    sum(logins) for days 250-252
    sum(login_errors) for days 250-252
    sum(logins) for days 247-249
    sum(login_errors) for days 247-249
    The query I'm using is:
    select cur.company_name, sum(cur.logins),
    sum(cur.login_errors), sum(old.logins), sum(old.login_errors)
    FROM names cur LEFT OUTER JOIN names old
    ON cur.company_name = old.company_name
    WHERE cur.adate>='250' and cur.adate<='252'
    and old.adate>='247' and old.adate<='249'
    GROUP by cur.company_name
    Given this data:
    Company_name adate logins login_errors
    ABC 247 10 10
    ABC 248 20 20
    ABC 249 30 30
    ABC 250 15 15
    ABC 251 25 25
    ABC 252 35 35
    My problem is that it returns:
    adate cur.logins cur.login_err old.logins old.login_err
    250 15 15 60 60
    251 25 25 60 60
    252 35 35 60 60
    How can I get it to only give me the one "old" day's data? I went with the LEFT OUTER JOIN because it's possible that there is no data for an "old" day.
    Thanks in advance.....

    Your problem stems from the join itself, and would be the same even without the OUTER JOIN. With your data, there are 3 records in cur and 3 records in old. The join matches each record in cur to each record in old resulting in 9 records in total. Without the SUM, this is clear:
    SQL> SELECT cur.company_name, cur.logins, cur.login_errors,
      2         old.logins, old.login_errors, cur.adate cad, old.adate oad
      3  FROM names cur LEFT OUTER JOIN names old
      4                 ON cur.company_name = old.company_name
      5  WHERE cur.adate>=250 and cur.adate<=252 and
      6        old.adate>=247 and old.adate<=249;
    COMPANY_NA     LOGINS LOGIN_ERRORS     LOGINS LOGIN_ERRORS        CAD        OAD
    ABC                35           35         10           10        252        247
    ABC                25           25         10           10        251        247
    ABC                15           15         10           10        250        247
    ABC                35           35         20           20        252        248
    ABC                25           25         20           20        251        248
    ABC                15           15         20           20        250        248
    ABC                35           35         30           30        252        249
    ABC                25           25         30           30        251        249
    ABC                15           15         30           30        250        249
    9 rows selected.You can do this with only one reference to the table.
    SELECT company_name,
           SUM(CASE WHEN adate BETWEEN 250 and 252 THEN logins ELSE 0 END) curlog,
           SUM(CASE WHEN adate BETWEEN 250 and 252 THEN login_errors ELSE 0 END) curerr,
           SUM(CASE WHEN adate BETWEEN 247 and 249 THEN logins ELSE 0 END) oldlog,
           SUM(CASE WHEN adate BETWEEN 247 and 249 THEN login_errors ELSE 0 END) olderr
    FROM names
    WHERE adate BETWEEN 247 and 252
    GROUP BY company_nameHTH
    John

  • Adjusting left/right sound balance

    I have some "play along" music tracks to practice playing musical instruments with. Many have just drums, bass and piano, with bass and piano panned to extreme left and right. To practice bass, for example, one adjusts the balance to extreme right to remove the bass part from the recording. I have not found a way to do this on my iPod or on iTunes. Is it possible?
    Either playing the right channel only (this is what a traditional balance control would do) or playing the right channel through both stereo channels would be good solutions. Alternatively, can one preprocess the track in some way to replace both channels by the right channel in the sound file itself?
    Unfortunately it isn't possible to adjust the balance on the iPod dock (with speakers) that I'm using.
    Many thanks in anticipation

    Well, keep experimenting with the left/right panning and the various parameters you can program into the reverb effect!
    There are no rules with regard to recording and mixing, but traditionally the bass drum, the bass guitar, and the lead vocal are mixed in the center, and the other instruments and harmony vocals are spread out to the left and right to varying degrees. The different drums in the drum kit are often panned to different positions mimicking the physical layout of the drum kit (left to right).
    As far as reverb goes, realize that you can set different amounts and kinds of reverbs on different instrumental and vocal tracks; you don't have to send every instrument to the same stereo reverb effect. If you do so, you'll lose the ability to position sounds where you want them to be. The other element is the wet/dry mix. When you send a sound to a reverb effect, you decide what percentage of the signal goes to the effect (wet) and what percentage bypasses the reverb and goes straight out to the left and right speakers (dry) according to the pan setting for that track.
    Listen to your CD collection. Pick some music that you like that is similar in style to what you are recording. Play a song over and over again and take note of where each instrument is placed in the stereo field. Then learn how to replicate that effect in your GarageBand tracks using panning and reverb. Studying well-recorded music is the best way to figure out how to do things on your own.

  • How  to  do inner join ,outer join, left join ,right join by using infoset

    how  to  do inner join ,outer join, left join ,right join by using infoset

    Hi
    If you want to make  join ,outer join, left join ,right join then its possible if you are using ODS or direct infoobject (In BW3.5) and if you are using BI7.0 then you also make join ,outer join, left join ,right join with Cube also.
    For making join ,outer join, left join ,right join in infosets you just select your info provider then right click on your infoarea from context menu select info set after doing this one pop-up opens here u define your infoset technical name and give either ODS object name of infoobject name.
    After doing this next screen opens in right hand side your selectes ODS or infoobject shows in graphical format .
    and left hand side it shows one menu bar here you can select another ODS or infoobject for making join ,outer join, left join ,right join .just click on ODS button in menu bar and select ODS drag your selected ODS from Left to right after doing this your selected ODS shown in right hand side window in graphical format you just now after doing this you are able to make join ,outer join, left join ,right join for this first you select field from one ods and drag a line from 1 ods to second ods after doing this one arrow is created from one ods to another ods just right click on arrow  and make join ,outer join, left join ,right join in to your ODS.
    I think its clear how we can we make join ,outer join, left join ,right join in infoset.If you have any further query then welcome.
    Assign Points...............
    Thanks and regards
    Ankit modi

  • Update statement with inner join

    Hello everyone. I am am trying to do an update statement with an inner join. I have found several examples of SQL statements that work with Sql server and mysql but they don't work in Oracle. Does anyone know the proper way in Oracle 10G? I am trying to update all fields in one table from fields in another table.
    for example:
    UPDATE table3
    SET
    TL3.name = TL2.name,
    TL3.status = TL2.status,
    TL3.date = TL2.date
    FROM table3 TL3 JOIN table2 TL2
    ON (TL3.unique_id = TL2.unique_id);
    any help will be appreciated.

    Hi,
    You can also use MERGE, like this:
    MERGE INTO  table3     dst
    USING   (
             SELECT  unique_id
             ,         name
             ,         status
             ,         dt          -- DATE is not a good column name
             FROM    table2
         )          src
    ON     (dst.unique_id     = src.unique_id)
    WHEN MATCHED THEN UPDATE
    SET     dst.name     = src.name
    ,     dst.status     = src.status
    ,     dst.dt          = src.dt
    ;Unlike UPDATE, this lets you avoid essentially doing the same sub-query twice: once in the SET clause and then again in the WHERE clause.
    Like UPDATE, you don't acutally join the table being changed (table3 in this case) to the other table(s); that is, the FROM clause of the suib-query does not include table3.
    Riedelme is right; you'll get better response to SQL questions like this in the SQL and PL/SQL forum:
    PL/SQL

Maybe you are looking for

  • Getting error 025036 while setting bind variable value

    Hi, I have created a view object (ViewObj) having bind variable (Bind_Val). I am writing custom java method in AppModuleImpl.java, so that I can use that in serviceInterface. my method is: public void Met(String a){ ViewObjImpl vo=new ViewObjImpl();

  • Download text file from application server to client server.

    Hi all, I am facing a format issue while downloading text file from application server to the client machine. The issue is that, say I have 6 to 10 lines in my text file in application server. but when i store it on the hard drive, it shoes all the d

  • HT4623 Help with software update

    I do not see a software update button in my general settings on my iPad....how would I update to ios7?

  • Screen Capture (file format) used to be pdf

    Is there a way to change the default file format for a screen capture. The file format in OS 10.3 used to capture as a PDF. Now the format is PNG. I know you can open the file in preview and resave it. I just want to see if there is someway to change

  • Ways of synchronizing PXI fpga clock

    It seems that there are two different ways of synchronizing the code on the PXI 7852R to the clock of the PXI-1062Q chassis. What is the difference: 1. As described in http://digital.ni.com/public.nsf/allkb/D108D4AF937524CA862570FF004C2A48?OpenDocume