Failed to RowUpdate to 2 different tables simultaneously
Hi there,
I am trying to update two different tables from each other after some calculation (this is related to inventory cost calculation) while I am using a 3rd table to drive the loop. Unfortunately, the following exception is occured..
Place 2o: transactionQty....>>>>:353975.0 onHandQty:844259.0
Rolled Back
java.sql.SQLException: [Microsoft][SQLServer 2000 Driver for JDBC]Row update failed.
at com.microsoft.jdbc.base.BaseExceptions.createException(Unknown Source)
at com.microsoft.jdbc.base.BaseExceptions.getException(Unknown Source)
at com.microsoft.jdbc.base.BaseImplUpdatableResultSet.executeStatement(Unknown Source)
at com.microsoft.jdbc.base.BaseImplUpdatableResultSet.updateRow(Unknown Source)
at com.microsoft.jdbc.base.BaseResultSet.updateRow(Unknown Source)
at updateInventoryCostData(InteIc.java:915)
I can e-mail you the java file if any one want to help me.
Can any one help me?
Regards,
Mortoza
[email protected]
Also, here is an example of handling transactions
I believe this link may help:
http://www.webservertalk.com/archive135-2005-3-934206.html
public ArrayList myFunction(){
Connection conn=null;
PreparedStatement pstmt1= null;
ResultSet resultSet=null;
ArrayList list1;
try{
list1=new ArrayList();
conn= dataSource.getConnection();
conn.setAutoCommit(false);
pstmt1= conn.prepareStatement();
resultSet= pstmt1.executeUpdate();
while(resultSet.next()){
arrayList.add(resultSet.getString("lastName");
conn.commit();
return arrayList;
} catch (SqlException e){
if(conn!=null)
conn.rollback();
e.printStackTrace();
} finally {
if(conn!=null)
conn.setAutoCommit(true);//must ensure this is done first because
//following lines might throw an error
if(rsultSet!=null)
resultSet.close();
if(pstmt1!=null)
pstmt1.close();
if(conn!=null)
conn.close();
}
Similar Messages
-
Insert data from a table into 5 different tables
My application has a data block than display information from another table. From this data block, the user has the option to select the records for upload. The information in the data block is used to insert data into 5 different tables. So if any exception occurs while inserting, the whole process should be rollback, but before this happen a record is inserting in a failed table indicated the reason of the failed.
For this process I use the following commands:
1. sp_name := Get_Application_Property(SAVEPOINT_NAME);
2. INSERT DDL
3. INSERT DDL
4. INSERT DDL
5. INSERT DDL
6. INSERT DDL
7. If Other Exception then ISSUE_ROLLBACK(sp_name) Otherwise FORMS_DDL ('commit')
The problem the previous insert(s) rollback
Thanks,Hi,
If you are using FORMS_DDL built-in to insert the data, then after each FORMS_DDL statement, you have to check the values of FORM_SUCCESS or FORM_FAILURE built-ins.
FORMS_DDL('<insert_statement_1>');
IF FORM_FAILURE THEN
<the statement fails. so have to be rollbacked>
END IF;
FORMS_DDL('<insert_statement_2>');
IF FORM_FAILURE THEN
<the statement fails. so have to be rollbacked>
END IF;Hope this helps.
Regards,
Manu.
If my response or the response of another was helpful or Correct, please mark it accordingly -
Getting same index size despite different table size
Hello,
this question arose from a different thread, but touches a different problem, which is why I have decided to post it as a separate thread.
I have several tables of 3D points.
The points roughly describe the same area but in different densities, which means the tables are of different sizes. The smallest contains around 3million entries and the largest around 37 million entries.
I applied an index with
CREATE INDEX <index name>
ON <table name>(<column name>)
INDEXTYPE is MDSYS.SPATIAL_INDEX
PARAMETERS('sdo_indx_dims=3');
My problem is that I am trying to see how much space the index occupies for each table.
I used the following syntax to get the answer to this:
SELECT usim.sdo_index_name segment_name, bytes/1024/1024 segment_size_mb
FROM user_segments us, user_sdo_index_metadata usim
WHERE usim.SDO_INDEX_NAME = <spatial index name>
AND us.segment_name = usim.SDO_INDEX_TABLE;
(thanks Reggie for supplying the sql)
Now, the curious thing is that in all cases, I get the answer
SEGMENT_NAME SEGMENT_SIZE_MB
LIDAR_POINTS109_IDX .0625
(obviously with a different sement name in each case).
I tried to see what an estimated index size would be with
SDO_TUNE.ESTIMATE_RTREE_INDEX_SIZE
And I get estimates ranging from 230MB in the case of 3million records up to 2.9 for the case of 37million records.
Does anyone have an idea why I am not getting a different actual index size for the different tables?
Any help is greatly appreciated!!!
Cheers,
F.It looks like your indexes didn't actually create properly. Spatial indexes are a bit different to 'normal' indexes in this regard. A BTree index will either create or not. However, when creating a spatial index, something may fail, but the index structure will remain and it will appear to be valid according to the data dictionary.
Consider the following example in which the SRID has a problem:
SQL> CREATE TABLE INDEX_TEST (
2 ID NUMBER PRIMARY KEY,
3 GEOMETRY SDO_GEOMETRY);
Table created.
SQL>
SQL> INSERT INTO INDEX_TEST (ID, GEOMETRY) VALUES (1,
2 SDO_GEOMETRY(2001, 99999, SDO_POINT_TYPE(569278.141, 836920.735, NULL), NULL, NULL)
3
SQL> INSERT INTO user_sdo_geom_metadata VALUES ('INDEX_TEST','GEOMETRY',
2 MDSYS.SDO_DIM_ARRAY(
3 MDSYS.SDO_DIM_ELEMENT('X',0, 1000, 0.0005),
4 MDSYS.SDO_DIM_ELEMENT('Y',0, 1000, 0.0005)
5 ), 88888);
1 row created.
SQL>
SQL> CREATE INDEX INDEX_TEST_SPIND ON INDEX_TEST(GEOMETRY) INDEXTYPE IS MDSYS.SPATIAL_INDEX;
CREATE INDEX INDEX_TEST_SPIND ON INDEX_TEST(GEOMETRY) INDEXTYPE IS MDSYS.SPATIAL_INDEX
ERROR at line 1:
ORA-29855: error occurred in the execution of ODCIINDEXCREATE routine
ORA-13249: SRID 88888 does not exist in MDSYS.CS_SRS table
ORA-29400: data cartridge error
Error - OCI_NODATA
ORA-06512: at "MDSYS.SDO_INDEX_METHOD_10I", line 10
SQL> SELECT usim.sdo_index_name segment_name, bytes/1024/1024 segment_size_mb,
2 usim.sdo_index_status
2 FROM user_segments us, user_sdo_index_metadata usim
3 WHERE usim.SDO_INDEX_NAME = 'INDEX_TEST_SPIND'
4 AND us.segment_name = usim.SDO_INDEX_TABLE;
SEGMENT_NAME SEGMENT_SIZE_MB SDO_INDEX_STATUS
INDEX_TEST_SPIND .0625 VALID
1 row selected.
SQL>When you ran the CREATE INDEX statement did it say "Index created." afterwards or did you get an error?
Did you run the CREATE INDEX statement in SQL*Plus yourself or was it run by some software?
I suggest you drop the indexes and try creating them again. Watch out for any errors. Chances are its an SRID issue. -
Selecting from 2 different tables
is this possible?
i just want to select from two different tables in one select statement and they have the same WHERE clauseSELECT
a.pkggrp,
a.pkgtype,
a.area,
a.process,
a.ww,
count(a.ww) as LOTSGATED,
sum(a.samplesize) as SUMSAMPLESIZE,
sum(a.total_defects) as SUMTOTALDEFECTS,
sum(case a.auditresult when 'pass' then 1 else 0 end) COUNTPASS,
sum(case a.auditresult when 'fail' then 1 else 0 end) COUNTFAIL,
case sum(case a.auditresult when 'fail' then 1 else 0 end)
when 0 then 0
else round(sum(case a.auditresult when 'fail' then 1 else 0 end) / count(a.ww) * 100,2)
end LRR,
case sum(case a.auditresult when 'fail' then 1 else 0 end)
when 0 then 0
else round(sum(case a.auditresult when 'fail' then 1 else 0 end) / sum(a.samplesize) * 1000000,0)
end PPM,
count(c.itrnum)
FROM
t_prodproc_monitoring a, t_itr c
WHERE
a.ww=c.ww
and a.ww between 1 and 50
and c.ww between 1 and 50
GROUP BY
a.pkggrp,
a.pkgtype,
a.area,
a.process,
a.ww
ORDER BY
a.pkggrp,
a.pkgtype,
a.area,
a.process,
a.ww ascthis gave me a
"c". "ww": invalid identifier -
Selecting Cells in Different Tables
I've created three tables on a Numbers 09 spreadsheet - let's call them tables "A", "B" and "C".
I want to select a cell on Table A and another cell on Table B then Sum them in another cell on Table C.
The problem is, I cannot figure out how to select the cells on tables A and B simultaneously so that I can drag the Sum function for them to a cell on table C.Marty,
In the English mode, the range identifier is the colon, not the comma. So, to SUM cells A1, B1 and C1, one would write: =SUM(A1:C1).
This may be what is tripping you up. The comma delimits multiple ranges, so if you wanted the sum of A1, B1, C1 including as well X1, Y1 and Z1, one would write: =SUM(A1:C1, X1:Z1). Of course, the comma can also be used to delimit single-cell ranges, as in: =SUM(A1, X2, Z3)
Further, and more to the point of your original question; to select multiple arguments for the SUM function, one at a time from different tables, type =SUM() in the cell where the result goes, and place the cursor between the parentheses, then hold down the Command key while you click in any Table, any cell, for as many tables and cells as you like, and the references will all appear in your expression properly formatted.
Hope this helps.
Jerry
Additional comment about Command Key -
Update two different tables by a single sql query:
Hi All,
i need to update two different talbes in a single sql query..
i m using the following query
UPDATE FT_User_Alert SET Subscription = 'W' where product_key=1 and measure_key = 12
AND
UPDATE LU_Monthly_Alert_Budget_Sheet SET Min_Red_Range ='16.0' AND Max_Green_Range ='24.0'AND Max_Red_Range ='27.0'AND Min_Green_Range ='16.0' where product_key='1' and measure_key = 12
i m getting the following error:
Odbc driver returned an error (SQLExecDirectW).
Error Details
Error Codes: OPR4ONWY:U9IM8TAC:OI2DL65P
State: HY000. Code: 10058. [NQODBC] [SQL_STATE: HY000] [nQSError: 10058] A general error has occurred. [nQSError: 43093] An error occurred while processing the EXECUTE PHYSICAL statement. [nQSError: 17001] Oracle Error code: 936, message: ORA-00936: missing expression at OCI call OCIStmtExecute: UPDATE FT_User_Alert SET Subscription = 'W' where product_key=1 and measure_key = 12 AND UPDATE LU_Monthly_Alert_Budget_Sheet SET Min_Red_Range ='16.0' AND Max_Green_Range ='24.0'AND Max_Red_Range ='27.0'AND Min_Green_Range ='16.0' where product_key='1' and measure_key = 12 . [nQSError: 17011] SQL statement execution failed. (HY000)
SQL Issued: EXECUTE PHYSICAL CONNECTION POOL writeback UPDATE FT_User_Alert SET Subscription = 'W' where product_key=1 and measure_key = 12 AND UPDATE LU_Monthly_Alert_Budget_Sheet SET Min_Red_Range ='16.0' AND Max_Green_Range ='24.0'AND Max_Red_Range ='27.0'AND Min_Green_Range ='16.0' where product_key='1' and measure_key = 12
but when i m ushin the same query in Microsoft SQL Server it executes properly:
please help me out...Duplicate thread. I've already answered on your other thread...
update two different tables by a single sql query: -
To execute a script in two different instances simultaneously
Hello All,
Is it possible to execute a script on different instances simultaneously?
Like, can we create a user on different instances simultaneously using a script?
Thanks in advance..!
Thanks and Regards, Readers please vote for my posts if the questions i asked are helpful.Hi,
Registered Servers meets your requirements.
The Query Editor window in SQL Server Management Studio can connect to and query multiple instances of SQL Server at the same time. The results that are returned by the query can be merged into a single results pane, or they can be returned
in separate results panes. As an option, Query Editor can include columns that provide the name of the server that produced each row, and also the login that was used to connect to the server that provided each row. For more information about how to execute
multiserver queries, see
Execute Statements Against Multiple Servers Simultaneously (SQL Server Management Studio).
To execute queries against all the servers in a local server group, right-click the server group, point to click
Connect, and then click New Query. When queries are executed in the new Query Editor window, they will execute against all servers in the group, using the stored connection information including the user authentication context. Servers
registered by using SQL Server Authentication but not saving the password will fail to connect.
More information, see: http://msdn.microsoft.com/en-us/library/ms188231.aspx
Thanks.
Tracy Cai
TechNet Community Support -
Best practice for a same query against 2 different tables
Hello all,
I want to extract info about tablespaces storage, both permanent and temporary. For that I use 2 different cursors that do exactly the same query but against a different table (dba_data_files and dba_temp_files).
CURSOR permanentTBSStorageInfo (tablespaceName VARCHAR2) IS
SELECT file_name, bytes, autoextensible, maxbytes, increment_by
FROM dba_data_files
WHERE tablespace_name = tablespaceName;
CURSOR temporaryTBSStorageInfo (tablespaceName VARCHAR2) IS
SELECT file_name, bytes, autoextensible, maxbytes, increment_by
FROM dba_temp_files
WHERE tablespace_name = tablespaceName;
First I'm bothered that I have to use 2 cursors to execute the same query against 2 different tables. Is there no another way around?
Then I fetch the results of this cursors in 2 different loops because I didn't find a way to dynamically call the cursors. I am looking for best practice here, knowing that I will do the same parsing against the results of the 2 cursors.
Thank you,Hi
Check whether the below query is helpful or not
select fs.tablespace_name "Tablespace",
fs.tempspace "Temp MB",
df.totalspace "Total MB"
from
(select
tablespace_name,
round(sum(bytes) / 1048576) TotalSpace
from
dba_data_files
group by
tablespace_name
) df,
(select
tablespace_name,
round(sum(bytes) / 1048576) tempSpace
from
dba_temp_files
group by
tablespace_name
) fs
where
df.tablespace_name = fs.tablespace_name;
Thanks -
How to create a foreign key for the table from two different tables?
Hi All,
I have a three table like below. In the below table SAMPLE_CONS_CHECK and SAMPLE_CONS2_CHECK will be having the primary key for NAME column. The same SAMPLE_CONS3_CHECK table also having the primary key for NAME column and forieign key for SAMPLE_CONS_CHECK and SAMPLE_CONS2_CHECK tables. See the below code 2
code 1:
CREATE TABLE SAMPLE_CONS_CHECK
(NAME VARCHAR2(10),
SERIES VARCHAR2(5)
CREATE TABLE SAMPLE_CONS2_CHECK
(NAME VARCHAR2(5),
MODEL NUMBER
CREATE TABLE SAMPLE_CONS3_CHECK
(NAME VARCHAR2(5),
MODEL_NO NUMBER
)code 2
alter table SAMPLE_CONS_CHECK
add constraint SAMPLE_CONS_CHECK_pk primary key (NAME)
alter table SAMPLE_CONS2_CHECK
add constraint SAMPLE_CONS2_CHECK_pk primary key (NAME)
alter table SAMPLE_CONS3_CHECK
add constraint SAMPLE_CONS3_CHECK_pk primary key (NAME)
ALTER TABLE SAMPLE_CONS3_CHECK ADD
CONSTRAINT SAMPLE_CONS3_CHECK_FK1 FOREIGN KEY
NAME
) REFERENCES SAMPLE_CONS_CHECK
NAME
) ON DELETE CASCADE;
ALTER TABLE SAMPLE_CONS3_CHECK ADD
CONSTRAINT SAMPLE_CONS3_CHECK_FK2 FOREIGN KEY
NAME
) REFERENCES SAMPLE_CONS2_CHECK
NAME
) ON DELETE CASCADE;From the above schenario i am able to insert the data to SAMPLE_CONS3_CHECK table. But the parent data is already available in the parent table. The problem is here two different constarints from two different tables. While inserting, it is checking from both the tables whether the parent is exist or not.
How can i solve this problem? Can anyone halp me about this?
Thanks
Edited by: orasuriya on Aug 8, 2009 2:02 AMActually the design is completely incorrect.
What you say is
I have
'foo', 'foo series'
'foo','foo model'
'foo',666
By virtue of table3 referring to both table1 and table2.
This means you actually need to have 1 (one) table:
'foo','foo series','foo model', 666
And the 'problem' disappears.
Sybrand Bakker
Senior Oracle DBA -
Report using Data from different tables
Hello,
I am trying to convert a Cobol batch program to Oracle 6i tabular report.
The data is fetched from many different tables and there are lots of processing(i.e, based on the value of a column from one table need additional processing from different tables) required to generate the desired columns in the final report.
I would like to know what is the best strategy to follow in Oracle Reports 6i. I heard that CREATE GLOBAL TEMPORARY TABLE is an option. ( or REF CURSOR ?) I do not know much about its usage. Can somebody guide me about this or any other better way to achieve the result.
Thank you in advance
PriyaHello,
There are many, many options available to you, each of which has advantages and disadvantages. This is why it is difficult to answer "what is best?" without alot more details about your specific circumstances.
In general, you're going to be writing PL/SQL to do any conditional logic that cannot be expressed as pure SQL. It can executed in the database, or it can executed within Reports itself. And most reports developers do some of both.
As a general rule, you want to send only the data you need from the database to the report. This means you want to do as much filtering and aggregating of the data as is readily possible within the database. If this cannot be expressed as plain SQL queries, then you'll want to create a stored procedures to help do this work.
Generally, the PL/SQL you create for executing within the report should be focused on control of the formatting, such as controlling whether a field is visible, or controlling display attributes for conditional formatting.
But these are not hard and fast rules. In some cases, it is difficult to get all the stored procedures you might like installed into the database. Perhaps the dba is reluctant to let you install that many stored procedures. Perhaps there are restrictions when and how often updates can be made to stored procedures in a production database, which makes it difficult to incrementally adjust your reports based on user feedback. Or perhaps there are restrictions for how long queries are allowed to run.
So, Reports offers lots of options and features to let you do data manipulation operations from within the report data model.
In any case, Oracle does offer temporary table capabilities. You can populate a temp table by running stored procedures that do queries, calculations and aggregations. And you can define and initiate a dynamic query statement within the database and pass a handle to this query off to the report to execute (ref cursor).
From the reports side, you can have as many queries as you want in the data model, arranged in any hierarchy via links. You can parameterize and change the queries dynamically using bind variables and lexicals. And you can add calculations, aggregations, and filters.
Again, most people do data manipulation both in the database and in Reports, using the database for what it excels at, and Reports for what it excels at.
Hope this helps.
Regards,
The Oracle Reports Team --skw -
How to join 5 different tables using SQL to make it to a flat file structur
I am trying to load five differnt tables into one flat file structure table without cartesian product.
I have five different tables Jobplan, Jobtask(JT), Joblabor(JL), Jobmaterial(JM) and Jpsequence(JS) and the target table as has all the five tables as one table.
The data i have here is something like this.
jobplan = 1record
jobtask = 5 records
joblabor = 2 records
jobmaterial = 1 record
jpsequence = 3 records
The output has to be like this.
JPNUM DESCRIPTION LOCATION JT_JPNUM JT_TASK JL_JPNUM JL_labor JM_JPNUM JM_MATERIAL JS_JPNUM JS_SEQUENCE
1001 Test Jobplan USA NULL NULL NULL NULL NULL NULL NULL NULL
1001 Test Jobplan USA 1001 10 NULL NULL NULL NULL NULL NULL
1001 Test Jobplan USA 1001 20 NULL NULL NULL NULL NULL NULL
1001 Test Jobplan USA 1001 30 NULL NULL NULL NULL NULL NULL
1001 Test Jobplan USA 1001 40 NULL NULL NULL NULL NULL NULL
1001 Test Jobplan USA 1001 50 NULL NULL NULL NULL NULL NULL
1001 Test Jobplan USA NULL NULL 1001 Sam NULL NULL NULL NULL
1001 Test Jobplan USA NULL NULL 1001 Mike NULL NULL NULL NULL
1001 Test Jobplan USA NULL NULL NULL NULL 1001 Hammer NULL NULL
1001 Test Jobplan USA NULL NULL NULL NULL NULL NULL 1001 1
1001 Test Jobplan USA NULL NULL NULL NULL NULL NULL 1001 2
1001 Test Jobplan USA NULL NULL NULL NULL NULL NULL 1001 3
Please help me out with this issue.
Thanks,
Siva
Edited by: 931144 on Apr 30, 2012 11:35 AMHope below helps you
CREATE TABLE JOBPLAN
( JPNUM NUMBER,
DESCRIPTION VARCHAR2(100)
INSERT INTO JOBPLAN VALUES(1001,'Test Jobplan');
CREATE TABLE JOBTASK
( LOCATION VARCHAR2(10),
JT_JPNUM NUMBER,
JT_TASK NUMBER
INSERT INTO JOBTASK VALUES('USA',1001,10);
INSERT INTO JOBTASK VALUES('USA',1001,20);
INSERT INTO JOBTASK VALUES('USA',1001,30);
INSERT INTO JOBTASK VALUES('USA',1001,40);
INSERT INTO JOBTASK VALUES('USA',1001,50);
CREATE TABLE JOBLABOR
( JL_JPNUM NUMBER,
JL_LABOR VARCHAR2(10)
INSERT INTO JOBLABOR VALUES(1001,'Sam');
INSERT INTO JOBLABOR VALUES(1001,'Mike');
CREATE TABLE JOBMATERIAL
( JM_JPNUM NUMBER,
JM_MATERIAL VARCHAR2(10)
INSERT INTO JOBMATERIAL VALUES(1001,'Hammer');
CREATE TABLE JOBSEQUENCE
( JS_JPNUM NUMBER,
JS_SEQUENCE NUMBER
INSERT INTO JOBSEQUENCE VALUES(1001,1);
INSERT INTO JOBSEQUENCE VALUES(1001,2);
INSERT INTO JOBSEQUENCE VALUES(1001,3);
SELECT JP.JPNUM AS JPNUM ,
JP.DESCRIPTION AS DESCRIPTION ,
NULL AS LOCATION ,
NULL AS JT_JPNUM ,
NULL AS JT_TASK ,
NULL AS JL_JPNUM ,
NULL AS JL_labor ,
NULL AS JM_JPNUM ,
NULL AS JM_MATERIAL ,
NULL AS JS_JPNUM ,
NULL AS JS_SEQUENCE
FROM JOBPLAN JP
UNION ALL
SELECT JP.JPNUM AS JPNUM ,
JP.DESCRIPTION AS DESCRIPTION ,
JT.LOCATION AS LOCATION ,
JT.JT_JPNUM AS JT_JPNUM ,
JT.JT_TASK AS JT_TASK ,
NULL AS JL_JPNUM ,
NULL AS JL_labor ,
NULL AS JM_JPNUM ,
NULL AS JM_MATERIAL ,
NULL AS JS_JPNUM ,
NULL AS JS_SEQUENCE
FROM JOBPLAN JP, JOBTASK JT
UNION ALL
SELECT JP.JPNUM AS JPNUM ,
JP.DESCRIPTION AS DESCRIPTION ,
NULL AS LOCATION ,
NULL AS JT_JPNUM ,
NULL AS JT_TASK ,
JL.JL_JPNUM AS JL_JPNUM ,
JL.JL_labor AS JL_labor ,
NULL AS JM_JPNUM ,
NULL AS JM_MATERIAL ,
NULL AS JS_JPNUM ,
NULL AS JS_SEQUENCE
FROM JOBPLAN JP, JOBLABOR JL
UNION ALL
SELECT JP.JPNUM AS JPNUM ,
JP.DESCRIPTION AS DESCRIPTION ,
NULL AS LOCATION ,
NULL AS JT_JPNUM ,
NULL AS JT_TASK ,
NULL AS JL_JPNUM ,
NULL AS JL_labor ,
JM.JM_JPNUM AS JM_JPNUM ,
JM.JM_MATERIAL AS JM_MATERIAL ,
NULL AS JS_JPNUM ,
NULL AS JS_SEQUENCE
FROM JOBPLAN JP, JOBMATERIAL JM
UNION ALL
SELECT JP.JPNUM AS JPNUM ,
JP.DESCRIPTION AS DESCRIPTION ,
NULL AS LOCATION ,
NULL AS JT_JPNUM ,
NULL AS JT_TASK ,
NULL AS JL_JPNUM ,
NULL AS JL_labor ,
NULL AS JM_JPNUM ,
NULL AS JM_MATERIAL ,
JS.JS_JPNUM AS JS_JPNUM ,
JS.JS_SEQUENCE AS JS_SEQUENCE
FROM JOBPLAN JP, JOBSEQUENCE JS;
JPNUM DESCRIPTION LOCATION JT_JPNUM JT_TASK JL_JPNUM JL_LABOR JM_JPNUM JM_MATERIA JS_JPNUM JS_SEQUENCE
1001 Test Jobplan NULL NULL NULL NULL NULL NULL NULL NULL NULL
1001 Test Jobplan USA 1001 10 NULL NULL NULL NULL NULL NULL
1001 Test Jobplan USA 1001 20 NULL NULL NULL NULL NULL NULL
1001 Test Jobplan USA 1001 30 NULL NULL NULL NULL NULL NULL
1001 Test Jobplan USA 1001 40 NULL NULL NULL NULL NULL NULL
1001 Test Jobplan USA 1001 50 NULL NULL NULL NULL NULL NULL
1001 Test Jobplan NULL NULL NULL 1001 Sam NULL NULL NULL NULL
1001 Test Jobplan NULL NULL NULL 1001 Mike NULL NULL NULL NULL
1001 Test Jobplan NULL NULL NULL NULL NULL 1001 Hammer NULL NULL
1001 Test Jobplan NULL NULL NULL NULL NULL NULL NULL 1001 1
1001 Test Jobplan NULL NULL NULL NULL NULL NULL NULL 1001 2
1001 Test Jobplan NULL NULL NULL NULL NULL NULL NULL 1001 3
{code} -
Can i use one interface to load data into 2 different tables
Hi Folks,
Can i use one interface to load data into 2 different tables(same schema or different schemas) from one source table with same structure ?
Please give me advice
Thanks
Raj
Edited by: user11410176 on Oct 21, 2009 9:55 AMHi Lucky,
Thanks for your reply,
What iam trying is ...Iam trying to load the data from legacy tables(3) into oracle staging tables.But i need to load the same source data into two staging tables(these staging tables are in two different schemas)
can i load this source data into two staging tables by using single standard interface(some business logic is there)
If i can then give me some suggestion how to do that
Thanks in advance
Raj -
How can I use create/createInsert for two different tables
Hi All,
I am showing different fields in the UI from different tables. I am able to fetch the data from all the tables and able to modify and save the data.
Now, the problem when I want to create/insert some data into those columns(from different tables) I am facing issues.
How can I proceed further??Hi Shay,
Thank you very much for your quick response.
Actually I am totally new in ADF world and I am trying to implement some applications in ADF.
I created an UI based on some 3 tables(there is foreign key relation between them) and some other tables. I am able to modify and save my application if there is any data in all the tables.
My Actual issues are
1) I removed all the data from the tables. There is a submit(CreateInsert) button, what I expected is on click of the button I should see all the fields in editable mode. But I was able to see only few fields and also in readonly mode. So here my issue is how can i create and save these data.
2) Consider on my landing page I have just CommandLink/CommandButton. After clicking that page I should get the above screen in create mode(I mean to say all fields in editable mode). How can achieve this?
Thanks & Regards,
Ravi. -
How to use a USER_DATASTORE to index multiple columns in different tables
I would appreciate if somebody can give an example or point to links with examples on how to use USER_DATASTORE on multiple columns in different tables. THe Oracle Text documentation only shows multiple columns in the same table.
Thanks in advance.I am not sure why your getting the wrong results but you should seriously reconsider the approach your are taking. Using functions like this is very ineffecient and should be avoided at all cost.
-
Hello Community
Using Visual Studio 2008 I have created a Windows Forms Application in which I created
Embedded Reports (rdlc).
The embedded reports (rdlc) uses Matrix(s).
Now on this one rdlc I have dragged 2 Matrix(s) onto the body.
One of the Matrix datasource dataset name and table name is "DataSet1_Table1.
A cells in the Matrix has a total column on the end as follows:
=FormatNumber(Sum(Fields!fld1.Value)+Sum(Fields!fld2.Value)+Sum(Fields!fld3.Value)+Sum(Fields!fld4.Value)+Sum(Fields!fld5.Value),"0")
The other Matrix datasource dataset name and table name is "DataSet2_Table2.
The cell in this Matrix has a total column on the end as follows:
=Sum(Fields!fld1.Value)+Sum(Fields!fld2.Value)+Sum(Fields!fld3.Value)+Sum(Fields!fld4.Value)+Sum(Fields!fld5.Value)
As you can see each Matrix has a different table.
I would like to add the total columns from each table in each Matrix but I haven't been
able to do it successfully. If I have to drag another Matrix or a Textbox on the
body to do it that is okay and/or add another/different formula to a cell onto the body that is
okay too.
So my question is how can I add the contents of the total in cell from each table in each matrix
which will create the "grand total"?
Thank you
ShabeautIt is possible to reference SSRS elements directly using the ReportItems collection. If your total tablix cell is outside of yoour matrix groups, you can use this collection to accomplish what you want:
=ReportItems!Matrix1Total.Value + ReportItems!Matrix2Total.Value
where Matrix1Total and Matrix2Total is the name of the cell that contains your totals. Note that for this to work, the cell name must be unique. If the total cell is inside a group, it will be repeated once for each instance of the group and will not be
unique.
You may be able to do it using the Sum aggregate and specifying the dataset for the scope variable:
=Sum(Fields!fld1.Value, "DataSet1")+Sum(Fields!fld2.Value,
"DataSet1")+Sum(Fields!fld3.Value,
"DataSet1")+Sum(Fields!fld4.Value,
"DataSet1")+Sum(Fields!fld5.Value,
"DataSet1")+Sum(Fields!fld1.Value,
"DataSet2")+Sum(Fields!fld2.Value,
"DataSet2")+Sum(Fields!fld3.Value,
"DataSet2")+Sum(Fields!fld4.Value,
"DataSet2")+Sum(Fields!fld5.Value,
"DataSet2")
This will work as long as you are not filtering the dataset in your Matrix properties. If you are, those
filters will not apply to this expression and the numbers will not total correctly.
"You will find a fortune, though it will not be the one you seek." -
Blind Seer, O Brother Where Art Thou
Please Mark posts as answers or helpful so that others may find the fortune they seek.
Maybe you are looking for
-
I want to vent my disgust with HP notebook product line. I want to state that I am not the generic user, I have been working in the personal computer industry since 1986. And, in the mid-90's... I was arepair center supervisor for AST Computer Noteb
-
"A serious error has occurred" when exporting
Please help!! i am going to export a 20mins video, but i try many times, when export till around 50%, a window pop up and said " sorry, a serious error has occurred that requires Adobe Premiere Pro to shut down" i try both premiere and encoder, also
-
Orange uk will not provide a micro sim replacement
As the title says, if you are still in contract and not eligible for an upgrade yet but were thinking of getting the iPhone 4 on pay as you go and swapping out your normal size contract sim for a micro one orange will not allow it, they said if you b
-
Hi, I am new to Oracle. I would like to check if it is ok to install Oracle database for educational purpose, not commerical use, in an corporate environment ? Thanks and regards. Chengbc
-
Connecting ERPi with ODI Interface
Hi Gurus, Till now I was able to connect to Oracle EBS but, now my query is whether I can connect to ODI Interface through ERPi instead of connecting directly to EBS. If its possible how can I achieve this please let me know I am eager to learn this.