Join Table from a set of records

I will try to explain the best I can...
In the first code; I have assigned my UNION result set to BCALC.  
How do I modify the second query so I will get all records from BCALC and all filtered records from second query in one result set?
First Query:
SELECT * FROM (
SELECT bc.SpecId, bc.EmpNo, e.LastName, e.FirstName, rcd.EarningsCode, bc.FinalPayoutDollars, eh.CompanyNo,
FROM Speculations bc, Employees e, RoleCodeDefs rcd, PeriodDefs p, EmpHist eh, vw_RollupPortfolios rp
WHERE
bc.EmpNo=e.EmpNo
AND bc.PeriodId=p.PeriodId
AND bc.RoleCode = rcd.RoleCode
UNION
SELECT bc.SpecId, bc.EmpNo, e.LastName, e.FirstName, rcd.EarningsCode, bc.FinalPayoutDollars, c.CompanyNo,
FROM Speculations bc, Employees e, RoleCodeDefs rcd, dbo.afn_CommunityLookup() c
WHERE
bc.EmpNo=e.EmpNo
AND bc.PeriodId=p.PeriodId
AND bc.RoleCode = rcd.RoleCode
AND bc.RoleCode <> 'MS'
) BCALC
Second Query:
select 'IBDX' AS EarningsCode,
ROUND(BCALC.FinalPayoutDollars * dbo.udsf_GetInfo(BCALC.EmpNo, otpr.PeriodStartDate), 2) as FinalPayoutDollars
from otprhours otpr, BCALC
WHERE otpr.EmpNo=BCALC.EmpNo

Query1 returns record from two select statement;  I need to insert new records (or UNION) in it form Query2 which contains a field reference to Query1 and a where clause (Query1.EmpNo = Query2.EmpNo).
Basically, for each EmpNo in Query1; look into Query2. If EmpNo matches; insert a new record in Query1 with the values of EarningsCode and FinalPayoutDollars as in Query2.
Query1:
SELECT bc.SpecId, bc.EmpNo, e.LastName, e.FirstName, rcd.EarningsCode, bc.FinalPayoutDollars, eh.CompanyNo,
FROM Speculations bc, Employees e, RoleCodeDefs rcd, PeriodDefs p, EmpHist eh, vw_RollupPortfolios rp
WHERE
bc.EmpNo=e.EmpNo
AND bc.PeriodId=p.PeriodId
AND bc.RoleCode = rcd.RoleCode
UNION
SELECT bc.SpecId, bc.EmpNo, e.LastName, e.FirstName, rcd.EarningsCode, bc.FinalPayoutDollars, c.CompanyNo,
FROM Speculations bc, Employees e, RoleCodeDefs rcd, dbo.afn_CommunityLookup() c
WHERE
bc.EmpNo=e.EmpNo
AND bc.PeriodId=p.PeriodId
AND bc.RoleCode = rcd.RoleCode
Query2:
SELECT 'IBDX' AS EarningsCode,
ROUND(Query1.FinalPayoutDollars * dbo.udsf_GetInfo(Query1.EmpNo, otpr.PeriodStartDate), 2) as FinalPayoutDollars
from otprhours otpr, Query1
WHERE otpr.EmpNo=BCALC.EmpNo

Similar Messages

  • How to select a row from duplicate set of records?

    I want to select a row from a duplicate set of records.
    below is the explanation of my requirement.
    select * from test_dup;
    COL_BILL     COL_SERV     COL_SYS
    b1     s1     c
    b1     s1     g
    b1     s2     c
    b1     s2     g
    b2     s2     g
    b2     s3     c
    b2     s3     g
    b3     s3     c
    Here what I want is, for a distinct col_sys if col_bill and col_serv is same then I need the row where col_sys='c'
    from the above result set I need the following:
    b1     s1     c
    b1     s2     c
    b2     s3     c
    I am using the following SQL query which is giving me the correct result set. But it will hamper the performance because there are total 45 columns in the table and total volume is around 50 million.
    select * from test_dup where col_bill||col_serv in (
    select col_bill||col_serv from (
    select col_bill,col_serv,count(*) from test_dup
    where col_sys in ('c','g')
    group by col_bill,col_serv having count(*) >1)) and
    col_sys='c';
    Can anyone please provide me the optimize SQL query for the same.

    Hi,
    Another way,
    SQL> with test_dup
    as
         select 'b1' col_bill, 's1' col_serv, 'c' col_sys from dual union all
         select 'b1', 's1', 'g' from dual union all
         select 'b1', 's2', 'c' from dual union all
         select 'b1', 's2', 'g' from dual union all
         select 'b2', 's2', 'g' from dual union all
         select 'b2', 's3', 'c' from dual union all
         select 'b2', 's3', 'g' from dual union all
         select 'b3', 's3', 'c' from dual
      select col_bill, col_serv, min(col_sys) col_sys
        from test_dup
       where col_sys in ('c', 'g')
    group by col_bill, col_serv
      having count( * ) > 1
         and count(nullif(col_sys, 'g')) > 0;
    CO CO C
    b1 s1 c
    b2 s3 c
    b1 s2 c
    3 rows selected.Regards
    Peter
    Edited by: Peter on Feb 18, 2009 1:10 AM
    - Added test data, thanks Karthick

  • Picking unique records from huge set of records

    Hi db experts,
    Could anyone help me in having a query which is based on partitioned table with 400,00,000 records each day . It has member number unique and I want to pick unique ones say for dates between 20-jan-2007 and 20-apr-2007.
    How can I proceed to write query. Am expecting query which will only pull unique records in less possible time.
    Thanks in advance
    Ravikanth

    The table has 400 lakh records each day my mistake - I misread the original post.
    Is this a one-off exercise or an ongoing requirement? What are you going to do with the data once you've got it - do you need more columns than the numbers? Do you have a feel for how many unique numbers there are per day and over the entire quarter?
    The easiest way to do this would probably be to create an extract table (maybe a temporary one) and vary the query I posted to insert the unique numbers into this table for each day i.e. run it multiple times against a smaller data set. Then you can select the unique numbers from the extract table to get the finished set.
    Of course, whether this is a viable solution depends on the answers to the questions I posed above. The more information you give us the easier it is for us to advise you.
    Cheers, APC

  • How to join tables from different databases (DBLink/DB connection )

    Hello,
    i have an issue and i hope you could help me to solve it. My problem is: I want to create native sql select which joins two tables from different DB (both of them are ORACLE, one of them internal, another one - external). I have found several notes and posts, but without any success. Db connection exists in dbcon table, so this part of my problem has been solved.
    I would like something like that:
    select * from table1@xxx inner join table2.
    i can not split this select into two separate ones, because both tables store over 30 mln. entries and i do not want to create any copies of them.
    Br,
    dez

    Hi,
    you might need to create a DB-Link on DB level and use EXEC SQL.
    Lots of stuff on google about this, like
    Oracle DBLink ( external database )
    Volker

  • Joining tables from two different databases

    Hi,
    I am trying to join W_DAY_D from 1 database to another 2 database to the fact table . The datatype for CALENDER _DTis (DATE) from W_DAY_D  and the Create date from fact table is TIMESTAMP . I changed the the datatype in the phyiscal layer for CREATE DATE from the fact table to DATE and joined it with W_DAY_D (Calender_DT = create_date) Thought the rpd showed me no errors while saving it . But when I try adding the column in the report it throws me error
    State: HY000. Code: 10058. [NQODBC] [SQL_STATE: HY000] [nQSError: 10058] A general error has occurred. [nQSError: 43113] Message returned from OBIS. [nQSError: 43119] Query Failed: [nQSError: 46008] Internal error: File server\Utility\Server\DataType\SUKeyCompare.cpp, line 772. (HY000)

    I tried this ealier but it throws me an Invaild expression error. In the Physical Foreign key join
    "ABC"."test"."dbo"."W_DAY_D_Alias"."CALENDAR_DT" = CAST("CT"."EAST"."dbo"."Fact-TEST"."Input date " as DATE)

  • Can we join table from different schema?

    Hi
    All,
    I have a SYS schema and MED schema. Now, I want to join DBA_USERS tables from SYS schema to EMPLOYEE table from MED schema to get an username. i am using following query but it's not working.
    select username,empl_userid,empl_nm_lst,empl_nm_fst from sys.dba_users db, med.employee emp where db.username = emp.empl_userid;
    Thanks,
    vishal

    g8 it is working now I just modify my query to make user name in upper case and then compare..
    select username,empl_userid,empl_nm_lst,empl_nm_fst from sys.dba_users db, med.employee emp where db.username = upper(emp.empl_userid);
    before that it was returning nothing..
    thanks for your help ... awesome..
    vishal
    Edited by: vishal patel on Sep 29, 2008 2:39 PM
    Edited by: vishal patel on Sep 29, 2008 2:40 PM

  • How to find a string from a set of records?

    I am having a stored procedure which is used for creating a crystal report. When I run the stored procedure sometimes it gives more than one row of data. I want to check if a particular string exists in any row of a particular column. To make it clear let me give an example
    When I run the query I get the below columns
    Part          Part type
    A001          Blanket
    A002          Blanket
    A003          Toys
    What I want to check is if Toys is appearing in any of the row in a formula in crystal reports.
    Thanks
    Sreejith J

    Hi,
    If you want to check a particular sub string or part of a string within a string, you can try this:
    if instr(<database column>, <String to be searched>) = 1 then true
    So, your formula output will be true if the <string to be searched> is part of your <database field>.
    Thanks,
    Raghavendra

  • Joining tables : Smart Access Connection

    Here's my scenario...
    I have data from 1 system existing as standard HANA tables.
    I have data from a second system, coming into HANA as a Smart Access Connection.
    My task is to build queries against each system's tables to obtain relevant data from each system, and then a top level query to join system A data to system B data.
    I'm from a SQL Server background, so my natural instinct is to NOT to join tables from linked servers directly to 'local' tables.
    I would normally query the remote source, stage the required data into a local temporary table, and then join local-to-local.
    However, I am unsure as to the best approach in this new world of HANA.
    I did some reading here : SAP HANA Smart Data Access - Using the SAP HANA Database - SAP Library
    "SAP HANA Smart Data Access optimizes execution of queries by moving processing as far as possible to the database connected via SAP HANA Smart Data Access. The SQL queries then work in SAP HANA on virtual tables. The SAP HANA Query Processor optimizes the queries and executes the relevant part in the connected database, returns the result to SAP HANA and completes the operation"
    .. but this is still a bit vague to me, and I am not sure that it was intended to be read in relation to simply querying the remote connection in isolation, or in queries involving other sources as well.
    Would anyone be able to clarify, or point me to better suited reading material ?
    many thanks for any pointers on this ....

    Not possible within SQL Dev.
    It pains me to suggest this.. but the simplest thing to do is to use an external table in Access to link to Oracle and make your joins in Access. I used to do it all the time and access is fairly good at only grabbing what is necessary from oracle. The only other product that comes to mind that does this type of operation is crystal reports.

  • Generate database tables from Business Components

    Is it possible to generate the database tables from a set of existing business components?
    This would be a handy feature to have, similar with JPA tables generation based on Entity Beans.
    Thanks
    Florin Marcus

    <BLOCKQUOTE><font size="1" face="Verdana, Arial">quote:</font><HR>Originally posted by Dmitri:
    Dear Laura,
    I mean first variant where the database would be the same:
    scott/tiger@database1
    foo/bar@database1
    Of course I understand that we must register every user in database by "CREATE USER XXX" and it is unacceptable for Internet. But it may be very convenient for an Intranet because we can build access restriction based on set of views without any changes in applications.
    Best wishes,
    Dmitri.<HR></BLOCKQUOTE>
    null

  • Getting the recordcount of a third table from a Join query

    Hi Folks,
    I've been trying to get my head around the best way of doing
    this within a single query, and sadly none of the books within my
    collection touch upon this scenario.
    I'm using the query below to query 2 tables as you can see. I
    want to add in a further query which searches a third table
    'ccsample' looking for matching records in the 'merchant_id' field
    against the merchant_id field of the cc_watchlists table. I only
    want to return the recordcount from the 'ccsample' table.
    I've tried adding another join, however if the recordcount in
    ccsample is 0, no records are returned at all (the query below
    returns 2 rows).
    I hope this makes sense!
    Query;
    <cfquery name="getwatched" datasource="#datasource#">
    SELECT r.retailer_name, r.id, r.shortname, d.id AS wid,
    d.merchant_id, d.user_id, d.e_updates
    FROM cc_watchlists d
    LEFT JOIN merchants r
    ON d.merchant_id=r.id
    WHERE d.user_id=#SESSION.Auth.ID#
    ORDER BY r.retailer_name ASC
    </cfquery>

    Did you make it a LEFT (OUTER) JOIN as well (something like
    below)? Not sure about what database you are using, but the
    ISNULL() function in MSSQL will convert any instances where you
    don't have a match to a 0 for counting purposes.
    SELECT r.retailer_name, r.id, r.shortname,
    d.id AS wid,d.merchant_id, d.user_id, d.e_updates,
    COUNT(ISNULL(c.merchant_id, 0)) AS cc_count
    FROM cc_watchlists d
    LEFT JOIN merchants r ON d.merchant_id=r.id
    LEFT JOIN ccsample c ON d.merchant_id=c.merchant_id
    WHERE d.user_id=#SESSION.Auth.ID#
    GROUP BY r.retailer_name, r.id, r.shortname,
    d.id,d.merchant_id, d.user_id, d.e_updates
    ORDER BY r.retailer_name ASC
    Phil

  • How do you join two tables from different Oracle schemas using a subquery

    I am trying to join two tables from different Oracle schemas using a subquery. I can extract data from each of the tables without a problem. However, when I combine the select statements using a subquery I get the Oracle error *'ORA-00936: missing expression'*. Since each SELECT statement executes on its own without error I don't understand what is missing. The result set I am trying to get is to match up the LINE_ID from PDTABLE_12_1 in schema DD_12809 with the MAT_DESCRIPTION from table PDTABLE_201 in schema RA_12809.
    The query is as follows:
    sql = "SELECT [DD_12809].[PDTABLE_12_1].LINE_ID FROM [DD_12809].[PDTABLE_12_1] JOIN " _
    + "(SELECT [RA_12809].[PDTABLE_201].MAT_DESCRIPTION " _
    + "FROM [RA_12809].[PDTABLE_201]) AS FAB " _
    + "ON [DD_12809].[PDTABLE_12_1].PIPING_MATER_CLASS = FAB.PIPING_MATER_CLASS"
    The format of the query is copied from a SQL programming manual.
    I also tried executing the query using a straight JOIN on the two tables but got the same results. Any insight would be helpful. Thanks!
    Edited by: user11338343 on Oct 19, 2009 6:55 AM

    I believe you are receiving the error because you are trying to JOIN on a column that doesn't exist. For example you are trying to join on FAB.PIPING_MATER_CLASS but that column does not exist in the subquery.
    If you want to do a straight join without a subquery you could do the following
    SELECT  DD_12809.PDTABLE_12_1.LINE_ID
    ,       FAB.MAT_DESCRIPTION
    FROM    DD_12809.PDTABLE_12_1
    JOIN    RA_12809.PDTABLE_201    AS FAB ON DD_12809.PDTABLE_12_1.PIPING_MATER_CLASS = FAB.PIPING_MATER_CLASS  HTH!

  • Select query based on joining of tables from different database is taking too long

    Hi Team,
    Select query on table with millions of records is taking very long time. It took 50mins, the below query is joining on multiple table from two databases DB1.dbo.Table1 contains 100 million records and also Table3 and Table4 (of different database) might
    contain close to 1million records.
    Select T1.*
    From DB1.dbo.Table1 T1
    Join DB1.dbo.Table2 T2 on RTRIM(T1.Col3) = RTRIM(T2.Col3)
    Join Table4 CA on RTRIM(T1.Col1) + T2.Col2 = CA.Col1
    Join Table3 U on CA.Col2 = U.Col2 AND RTRIM(T2.Col2) = U.Col3
    Where U.Col4 NOT IN ('A1', 'A2', 'A3', 'A4', 'A5', 'A6','A7','A8','A9')
    And (T1.flg IS NULL OR T1.flg = 'N')
    And LTRIM(RTRIM(T2.Col2)) NOT IN ('B1','B2')
    How can i improve the performance of this query. Actual thing is update the data in Db1.dbo.table1 based on the conditions but if the select is taking close to 1hr then update will take hours together. Indexes already implemented on all the tables.
    Thanks,
    Eshwar.
    Please don't forget to Marked as Answer if my post solved your problem and use Vote As Helpful if a post was useful. It will helpful to other users.

    Thanks.
    Join Table4 CA on RTRIM(T1.Col1) + T2.Col2 = CA.Col1
    This join is not working with spaces if Rtrim is not used.
    Thanks! Eshwar.
    Please don't forget to Marked as Answer if my post solved your problem and use Vote As Helpful if a post was useful. It will helpful to other users.

  • Load multiple records in 1 table from 1 line in text file w/sql loader

    hi guys,
    quick question, perhaps someone can help. searched around and didn't see this question asked before, and can't find any answer in SQL Loader faqs or docs.
    i know i can extract multiple logical records from a single physical record in the input file as two logical records, and then use two into tables clauses to load the data into the table. see oracle 9i sql loader control file reference chapter 5 to see what i am talking about.
    but my question follows:
    cust_id amount1_val amount1_qual amount2_val amount2_qual amount3_val amount3_qual
    123 1500.35 TA 230.34 VZ 3045.50 TW
    basically i want to use one sql loader statement to load these 3 records into 1 table. the issue for me is that i need to re-use the cust_id for all 3 records as the key, along with the qualifier code. the example in the Oracle docs only works for data where the logical records are completely separate -- no shared column values.
    i'm sure this is possible, perhaps using some :cust_id type parameter for the 2nd and 3rd records, or something, but i just don't have enough knowledge/experience with sql loader to know what to do. appreciate any help.
    wayne

    Hi wayne,
    I found an example on what exactly you were looking for from an SQL*Loader documentation. Please see if it of some help to you
    EXAMPLE
    The control file is ULCASE5.CTL.
    1234 BAKER 10 9999 101
    1234 JOKER 10 9999 777
    2664 YOUNG 20 2893 425
    5321 OTOOLE 10 9999 321
    2134 FARMER 20 4555 236
    2414 LITTLE 20 5634 236
    6542 LEE 10 4532 102
    2849 EDDS xx 4555
    4532 PERKINS 10 9999 40
    1244 HUNT 11 3452 665
    123 DOOLITTLE 12 9940
    1453 MACDONALD 25 5532
    In the above datafile
    Column1 - Empno
    Column2 - ENAME
    Column3 - Depno.
    Column4 - MGR
    Column5 - Proj no.
    -- Loads EMP records from first 23 characters
    -- Creates and loads PROJ records for each PROJNO listed
    -- for each employee
    LOAD DATA
    INFILE 'ulcase5.dat'
    BADFILE 'ulcase5.bad'
    DISCARDFILE 'ulcase5.dsc'
    1) REPLACE
    2) INTO TABLE emp
    (empno POSITION(1:4) INTEGER EXTERNAL,
    ename POSITION(6:15) CHAR,
    deptno POSITION(17:18) CHAR,
    mgr POSITION(20:23) INTEGER EXTERNAL)
    2) INTO TABLE proj
    (empno POSITION(1:4) INTEGER EXTERNAL,
    3) projno POSITION(25:27) INTEGER EXTERNAL) -- 1st proj
    Notes:
    REPLACE specifies that if there is data in the tables to be loaded (EMP and PROJ), SQL*loader should delete the data before loading new rows.
    Multiple INTO clauses load two tables, EMP and PROJ. The same set of records is processed three times, using different combinations of columns each time to load table PROJ.
    Regards,
    Murali Mohan

  • How to retain current set of records in advanced table in OAF

    I have an advanced table in a OAF page. Number of records displayed is set to 5. Now, when I have more than 5 records, we can view the next set of records using navigation buttons of the advanced table. One of its column is an image which has "Action Type" as "fireAction" and "Submit" set to "True", which when clicked displays further details about the selected record in a separate region. However, in this process the page is getting refreshed and the table is again displaying the first set of 5 records even if i chose to display details about record in the next set of 5 (i.e after navigating using "Next 5" button of the table).
    Is there any way to retain the current set of records displayed in the advanced table across the page refresh.?
    Thanks
    Nagamanoj

    Solved.
    Somewhere in our code, while populating one of the columns of the table, we were resetting the VO which was causing the issue. Modified that method call to add a parameter to mention from which row should the table be populated.
    Thanks
    Nagamanoj

  • Reg update of a 10 million record table from 1 million record table

    I have 2 tables
    Tabke 1 : 10 millio records
    21 indexes --> 1). acct_id , acct_seq_no -- index_1
    2). c1 , c2 , c3 -- index_2
    Table 2 : 1 .5 million records
    1 index on ( acct_id, acct_seq_no) - idx_1
    common keys are acct_id and acct_seq_no
    I'm updating table1 from table 2
    I need to use index ( index_1 from table_1 ) and (idx_1 from table_2)
    How can I make my query to use only this particular index.
    MY query ia as follows
    UPDATE csban_&1 csb
    SET (
    duns_no,
    hdqtrs_duns_no,
    us_ultmt_duns_no,
    sci_id,
    blg_cl_id,
    cl_id
    ) =
    ( SELECT acct_id,
    acct_seq_no,
    duns_no,
    hdqtrs_duns_no,
    us_ultmt_duns_no,
    sci_id,
    blg_cl_id,
    cl_id
    FROM csban_abi_temp
    WHERE csb.acct_id = temp.acct_id
    AND csb.acct_seq_no = temp.acct_seq_no
    AND rownum < 2
    WHERE
    EXISTS
    SELECT 1
    FROM csban_abi_temp temp1
    WHERE csb.acct_id = temp1.acct_id
    AND csb.acct_seq_no = temp1.acct_seq_no
    DO I need to put and index hint after this
    UPDATE csban_&1 csb --???????? /*+ indedx (csb.index_1) */
    Thanks in advance

    Thanks a lot david and rob for sharing the info.
    Please find the details
    SQL> EXPLAIN PLAN FOR
    UPDATE csban_2 csb
    SET (
    duns_no,
    hdqtrs_duns_no,
    us_ultmt_duns_no,
    sci_id,
    blg_cl_id,
    cl_id
    ) =
    ( SELECT duns_no,
    hdqtrs_duns_no,
    us_ultmt_duns_no,
    sci_id,
    blg_cl_id,
    cl_id
    FROM csban_abi_temp temp
    WHERE csb.acct_id = temp.acct_id
    AND csb.acct_seq_no = temp.acct_seq_no
    AND rownum < 2
    WHERE
    EXISTS
    SELECT 1
    FROM csban_abi_temp temp1
    WHERE 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20
    21 22 23 24 25 26 27 28 29
    Explained.
    SQL>
    SQL>
    SQL> SELECT * FROM TABLE(dbms_xplan.display);
    PLAN_TABLE_OUTPUT
    Plan hash value: 584770029
    | Id | Operation | Name | Rows | Bytes | Cost
    | TQ |IN-OUT| PQ Distrib |
    PLAN_TABLE_OUTPUT
    | 0 | UPDATE STATEMENT | | 530K| 19M| 8213
    | | | |
    | 1 | UPDATE | CSBAN_2 | | |
    | | | |
    |* 2 | FILTER | | | |
    | | | |
    | 3 | PX COORDINATOR | | | |
    | | | |
    PLAN_TABLE_OUTPUT
    | 4 | PX SEND QC (RANDOM) | :TQ10000 | 530K| 19M| 8213
    | Q1,00 | P->S | QC (RAND) |
    | 5 | PX BLOCK ITERATOR | | 530K| 19M| 8213
    | Q1,00 | PCWC | |
    | 6 | TABLE ACCESS FULL | CSBAN_2 | 530K| 19M| 8213
    | Q1,00 | PCWP | |
    |* 7 | INDEX RANGE SCAN | IDX_CSB_ABI_TMP | 1 | 10 | 3
    PLAN_TABLE_OUTPUT
    | | | |
    |* 8 | COUNT STOPKEY | | | |
    | | | |
    | 9 | TABLE ACCESS BY INDEX ROWID| CSBAN_ABI_TEMP | 1 | 38 | 4
    | | | |
    |* 10 | INDEX RANGE SCAN | IDX_CSB_ABI_TMP | 1 | | 3
    | | | |
    PLAN_TABLE_OUTPUT
    Predicate Information (identified by operation id):
    2 - filter( EXISTS (SELECT 0 FROM "CSBAN_ABI_TEMP" "TEMP1" WHERE "TEMP1"."ACC
    T_SEQ_NO"=:B1 AND
    "TEMP1"."ACCT_ID"=:B2))
    PLAN_TABLE_OUTPUT
    7 - access("TEMP1"."ACCT_ID"=:B1 AND "TEMP1"."ACCT_SEQ_NO"=:B2)
    8 - filter(ROWNUM<2)
    10 - access("TEMP"."ACCT_ID"=:B1 AND "TEMP"."ACCT_SEQ_NO"=:B2)
    Note
    - cpu costing is off (consider enabling it)
    30 rows selected.
    The query had completed and it took 1 hr 47 mts.
    SQL> SQL> SQL> Updating CSBAN from TEMP table
    old 1: UPDATE /*+ INDEX(acct_id,acct_seq_no) */ csban_&1 csb
    new 1: UPDATE /*+ INDEX(acct_id,acct_seq_no) */ csban_1 csb
    1611807 rows updated.
    Elapsed: 01:47:16.40

Maybe you are looking for

  • Windows 7 Pro (64-bit), iTunes 10 and AppleTV (160Gb)

    I'm trying to move my iTunes collection to a PC running windows 7 pro (64bit) - a machine I'm happier to leave on 24/7 than my iMac. I've a fresh install of windows and installed the latest 64-bit iTunes. However, the PC doesn't display the AppleTV u

  • How to make a form-based search API using HTTPClient

    Hi, I am getting trouble to make an API that is related to making a site search by using a form-based search API by help of HTTPClient

  • Spry Tabbed Panels - replace text tab with an image, how to?

    Hi all, I'm stumped. I've uploaded 2 files to: http://docs.google.com/leaf?id=0B4zgjxAaUD97MmUzZTk3NjMtMDNkYi00NDJjLWExNzctOWNjMzM0MDlmMj g0&hl=en&authkey=CMWGoeEP http://docs.google.com/leaf?id=0B4zgjxAaUD97YTQ1MDliNzEtZGVhZS00MmYzLTllZWMtMzJiODQwMj

  • Frustratingly setting up the Airport Extreme

    O.K- i have comcast. and i had a linksys- but everything else i own is apple- so why not, right? i plugged it and got going. i cannot get very far. it does not automatically find the DNS servers, no domain name or domain address. first page: country

  • How to freeze the number of rows in af:inputtext

    Hi all - i have requirement like user should enter only 13 lines after that application should not allow the any characters. am using af:inputtext 13 rows by default it is showing 13 rows , if user trying to enter more than 13 lines it was allowing.