Insert two tables with a single query (same ID)
HelloI want to insert two tables at the same time (with a single request) provided that both records get inserted with the same identifier. How can I do this?
Table Movies
id
name
Table Category
movie_id
cat_type
(a) insert in the first table, retrieve the id (can be usingmy_sequence.currval
and then insert into another table.question: He brings three queries to the Database, I also suspect that when several people trying to insert there is a problem, I could be wrong.
I have no other idea.
Greatly appreciated!
think you need to do as an anonymous pl/sql block.
Dim cn As New OracleConnection("DataSource = xx'; user id = xx; password = xx;")
Try
'build the anonymous pl/sql
Dim sb as New System.Text.StringBuilder
sb.Append("declare")
sb.Append(" l_N number;")
sb.Append("begin")
sb.Append("insert into movies (id,name) values (my_sequence.nextval, 'film1') returning id into l_N;")
sb.Append( "insert into category values (l_N, 'Category type');")
sb.Append(" END;")
'create commd object
Dim cmd as New OracleCommand(sb.ToString,cn)
cmd.Connection.Open()
cmd.ExecuteNonQuerry()
cmd.Connection.Close()
cmd.dispose()
Catch ex as Exception
blah blah blah
End try
Published by: pollywog on May 28, 2010 10:48
Published by: pollywog on May 28, 2010 10:49
Tags: Database
Similar Questions
-
I try to insert two images in a single document, group them, and then export it to a jpg file but cannot do
Hello sara,.
For my part, I prefer to use my German PS in this way (I try to translate the commands):
Use the same height for both images.
Open the first image in PS.
Use Bild > Arbeitsflache (Image > work plan?) See screenshot:
From there:
Give him the new with, by clicking on the left or the right indicating the hand playing around (trial and error).
Now you can insert your second image.
Hans-Günter
-
Insert two tables simultaneously
I want to insert records into two or several other table with a single statement. Is this possible in Oracle XE?
How can I combine the following in a single statement?
Thank you and best regardsinsert into addressbook(name) values('test'); insert into email(email) values('[email protected]');
Hello
It is possible to merge several inserts with 'all' BLOCinstruction, check
INSERT ALL INTO addressbook(name) VALUES('test') INTO email(email) VALUES('[email protected]') SELECT * FROM dual
General synthax so is;
INSERT ALL INTO
VALUES ( ) INTO VALUES ( ) ... Concerning
-
How to insert multiple lines using a single query
Hi all
How to insert multiple lines using a single query to the emp table?
I have the number of rows to insert into table x. consumes a lot of time. I tried to insert several lines using a single query, but get errors. I know exactly the query to do this.
Thank you
SunilLike this?
SQL> create table test(id number , dt date); Table created. SQL> insert into test values(&a,&b); Enter value for a: 1 --- It asked me and I entered 1 Enter value for b: sysdate --- It asked me and I entered sysdate old 1: insert into test values(&a,&b) new 1: insert into test values(1,sysdate) 1 row created. SQL>
g.
-
by comparing the two tables with
With the help of 10 gr 2
Assuming that we have two tables with the following structure:
create table1 (integer id, amount1 number, status varchar2 (200));
create table2 (integer id, number, status varchar2 amount2 (200));
Table1 contains a single line:
ID = 4711, amount1 = 3, status = "not ok".
Table2 contains one or more lines with table2.id = table1.my_field referenced:
ID = 4711, amount2 = 2, status = "not ok".
ID = 4711, amount2 = 2, status = "not ok".
ID = 4711, amount2 = 1, status = "not ok".
ID = 4711, amount2 = 4, status = "not ok".
The amount1 in Table1 is a cumulative sum of Table2 lines what status should be set to "ok". Table1.my_field is particularly well indexed.
How to make all the lines (for example via the rowid) from Table2 that sum on amount2 is the amount1 in the line after line in Table1 (for switching their table2.status to 'ok')?
I hope my question is clear enough...Try this
SQL> select * from table2; ID AMOUNT2 STATUS ---------- ---------- ------ 4711 2 Ok 4711 2 not ok 4711 1 Ok 4711 4 not ok SQL> roll Rollback complete. SQL> select * from table1; ID AMOUNT1 STATUS ---------- ---------- ------ 4711 3 not ok SQL> select * from table2; ID AMOUNT2 STATUS ---------- ---------- ------ 4711 2 not ok 4711 2 not ok 4711 1 not ok 4711 4 not ok SQL> SQL> SQL> update 2 table2 a 3 set 4 a.status = 'Ok' 5 where 6 rowid in 7 (select t2.rowid 8 from 9 (select 10 table2.*, 11 sum(amount2) over (partition by id order by rn) rn_total 12 from 13 (select table2.*, row_number() over (partition by id order by amount2) rn from table2 ) table2) t2, 14 table1 15 where 16 table1.id = t2.id and 17 t2.rn_total <= table1.amount1) 18 / 2 rows updated. SQL> select * from table2; ID AMOUNT2 STATUS ---------- ---------- ------ 4711 2 Ok 4711 2 not ok 4711 1 Ok 4711 4 not ok SQL>
-
How to select all text in a table with a single click cell?
How to select all text in a table with a single click cell? I use TextField.selectAll () when you implement a table cell factory. But when I select a line with a single click, then a click on a table cell again: see the result image
The text in the table cell is not all selected. What I simply selects all the text in a table cell when there is a click on it. How to realize that? Thank you
Thanks for help ~.
-
can perform us two actions with a single button in two clicks, one after the other?
Mr President.
can perform us two actions with a single button in two clicks, one after the other?
I want that when I click on the button Add once it add data to the database and when I click again on this button it clears the form data to the empty fields.
Concerning
TanvirIn the code, it should be easy.
The following code adds that a button called butman with text 'ADD '.
It then registers a listener that will be called if the user clicks the button.This listener then calls the runAddData method if you clicked butman while it contained the text of "ADD" and it calls the runClearData method otherwise.
That's why he will swap the functionality of the button between ADD and CLEAR on each click.final Button butman = new Button("ADD"); butman.setOnAction(new EventHandler
() { @Override public void handle(ActionEvent t) { if (butman.getText().equals("ADD")) { butman.setText("CLEAR"); runAddData(); } else { butman.setText("ADD"); runClearData(); } // END IF-THEN }}); I hope that's what you wanted.
Further reflection.
You might want to run the ADD and CLEAR methods in their own son so that it can run in the background without slowing down your user interface.I also reuse rather a single button for several features instead of to apply with hundreds of nodes used only rarely with masses of code to show and hide as needed.
-
Two actions with a single button Oracle adf
Hello
Dear all,
I want two action with a single button. Before posting, I studied this thread, but it seems that it cannot solve my problem two actions with a single button?
It's my button and its action http://4.bp.blogspot.com/-tpP5wIW8JLI/T66zhLZgG0I/AAAAAAAAAPY/F1A-Ka8KGPY/s1600/req1.JPG
getReqID button is actually a call to a procedure that returns a value to his class of action. The cb1_action function is...
public String cb1_action() {}
BindingContainer links = getBindings();
OperationBinding operationBinding = bindings.getOperationBinding("getReqID");
Object result = operationBinding.execute ();
int id = Integer.parseInt (result.toString ());
System.out.println ("result =" + id);
If (! operationBinding.getErrors () .isEmpty ()) {}
Returns a null value.
}
Returns a null value.
}
It works very well. Don't know I want to, click this button, it also opens a page of .jsff. but I'm unable to open this page.
Help, please
Thank you
Muhammad NasirThe first image you provided shows a small 'Attention' sign on the "request for quote-global-TF" which, I guess, gives you the sentence.
This warning tells you that there is a problem with the task flow that you imported from the pot. Move the mouse over the warning sign a see what message you get from the frame on the error. If you don't get one, in 'source' view and look for red or orange squares in the gutter of the right hand. Scroll to the position of the red square and move the mouse over the underlined part red or orange of the code.Timo
-
How to match columns from two tables with
Hello:
I have two tables as below:
Table1::(Base Table)
Country | Prefix | Prefix_Length
Travel | 001 | 3
CountryB. 0012 | 4
PaysC | 00443 | 5
CountryD | 0091 | 4
:(Detail Table) table2
The population | Area | Prefix
500 | AreaA | 0015921
1000 | AreaB | 00122
400. AreaC. 00443743
300. ALIS | 0091333
100. AreaA | 001
I need to match these two tables with prefix columns (whose length is not fixed in the two tables: but it starts with 00 in the two tables). Two different countries the prefix may be similar up to a certain length. Thus, Prefix_Length can be used to determine (exactly) how much time should be taken in the search of Table2.
Output:
Country | Prefix | Area | Population
Travel | 001 | AreaA | 600
CountryB. 0012 | AreaB | 1000
PaysC | 00443 | AreaC. 400
CountryD | 0091 | ALIS | 300
Please help me with your valuable comments.
-TenderTry this
with base_table as ( select 'CountryA' country,'001' prefix,3 prefix_length from dual union all select 'CountryB','0012',4 from dual union all select 'CountryC','00443',5 from dual union all select 'CountryD','0091',4 from dual ), detail_table as ( select 10 no_of_call,'0015921' prefix from dual union all select 3,'00122' from dual union all select 50,'00443743' from dual union all select 50,'00443643' from dual union all select 300,'0091333' from dual union all select 60,'001' from dual ) SELECT country, prefix,sum(no_of_call) FROM ( select country, b.prefix,no_of_call, decode(no_of_call,lead(no_of_call,1,0) over(partition by no_of_call order by b.prefix,no_of_call),'y','n') y_or_no from base_table b, detail_table d where b.prefix = substr(d.prefix,1,prefix_length)) where y_or_no !='y' group by country, prefix order by country, prefix;
Published by: Vi on 20 February 2012 01:07
-
Insert data into two tables in a single transaction
Hi all
I have a problem with the development of features.
Background:
I have two tables: OFFER_HEADER and OFFER_CONTENT
For now, user must insert and commit the OFFER_HEADER (single-row view), then content becomes accessible and OFFER_CONTENT(multi-row view) can be filled. It is done by selecting the save form PRODUCTS and integration of values in OFFER_CONTENT. Product data can be changed on the canvas of CONTENT form.
My goal:
I know this isn't a practical way to implement the functionality. I want to insert all the data (header and content) in a single transaction. What is the best way to do it?
Thanks in advance,
Best regards
BartekHai,
The error is now with the primary key. In order to check the value of the primary key as part of the operation.
Kind regards
Manu.
-
It is possible to have two tables with the same name in Oracle!
Oracle Version: 10 gr 2
MS Access 2007, I had to use the 'Export' by which I copy a table (and its data) to an Oracle schema via an ODBC connection. Later, I realized that, during the copy of tables with a mix of lower and upper case names, the table does not copied (exported). But MS Access will give you the message that table obtained export successfully.
MS-Access mess around Oracle data dictionary.
When you issue
You will see the names of the tables. But when you try to DESCRIBE or SELECT this table, you willSQL>select * from tab; TNAME TABTYPE CLUSTERID ------------------------------ ------- ---------- AMStates TABLE Version TABLE
You can even create another table with the same name in the schemaSQL>desc Version ERROR: ORA-04043: object Version does not exist
Why this is happening and how can I bring these items 'non-existent '?SQL>create table VERSION (X NUMBER); Table created.
Hello
Use
SQL > desc 'Version '.
Or
SQL > select * from 'Version '.
Or
SQL > drop table 'Version '.
To overcome the problems of mixed-case.
-
How to compare the DOF of the OWNER. Table_name two DB in a single query?
Hello community,
I am trying to compare the DDL from a table that is located in two databases with the same name and the same pattern:
select my_files.schema_name || '.' || my_files.table_name as table_name , case ( select dbms_lob.compare( dbms_metadata.get_ddl(one.object_type, one.object_name, one.owner) , dbms_metadata.get_ddl(two.object_type, two.object_name, two.owner) ) from all_objects one , all_objects@db_link two where one.object_type = 'TABLE' and one.owner = my_files.schema_name and one.object_name = my_files.table_name and two.object_type = one.object_type and two.owner = one.owner and two.object_name = one.object_name ) when 0 then 'Y' else 'N' end as ddl_equal_flag from my_files;
When I run the query above in SQL Developer, I get results like:
Table-name DDL_EQUAL_FLAG MY_SCHEMA. TABLE_1 THERE MY_SCHEMA. TABLE_2 THERE MY_SCHEMA. TABLE_3 THERE etc. etc. But I wonder if it really works... I suspect DBMS_METADATA. GET_DDL returns the DDL of the database where I am connected, regardless of the database link, I used. Is this correct?
And if so, is there another approach that gives me the expected results?
Your help is very appreciated!
Best regards, Yvo
I would not use DBMS_METADATA, but the DBA_TAB_COLUMNS query directly.
-
sqlloader to load two tables of the single data file in a single operation
Oracle 11.2.0.3 SE - One
Oracle Linux 5.6
I don't know if I need a second set of eyes or if I am missing something.
Problem: Given a file of text csv with header and detail records (identified by the first field in the file) use sql loader to load the header and detail of the tables in a single operation.
The header record is to take, but the detail records are rejected by omitting the WHEN clause.
More comments after reading through the exhibits:
In view of these two tables:
SQL > desc EDSTEST_HEADER
Name Null? Type
----------------------------------------- -------- ----------------------------
EDSTEST_HEADER_ID NOT NULL NUMBER
REC_TYPE VARCHAR2 (10)
SOLD_TO_ACCOUNT VARCHAR2 (50)
SCAC_RECEIVER_ID VARCHAR2 (50)
FORMAT_TYPE VARCHAR2 (10)
CLIENT_NAME VARCHAR2 (100)
CUSTOMER_PICKUP_ADDRESS VARCHAR2 (100)
CUSTOMER_PICKUP_CITY VARCHAR2 (50)
CUSTOMER_PICKUP_STATE VARCHAR2 (10)
CUSTOMER_PICKUP_ZIP VARCHAR2 (50)
INSERT_USER VARCHAR2 (50)
DATE OF INSERT_USER_DATE
INSERT_STATUS_CODE VARCHAR2 (10)
SQL > desc EDSTEST_DETAIL
Name Null? Type
----------------------------------------- -------- ----------------------------
EDSTEST_DETAIL_ID NOT NULL NUMBER
NUMBER OF EDSTEST_HEADER_ID
REC_TYPE VARCHAR2 (10)
SHIP_TO_NAME VARCHAR2 (100)
SHIP_TO_ADDRESS VARCHAR2 (100)
SHIP_TO_CITY VARCHAR2 (50)
SHIP_TO_STATE VARCHAR2 (10)
SHIP_TO_ZIP VARCHAR2 (50)
STATUS_OR_APPT_REASON_CD VARCHAR2 (10)
EVENT_DESCRIPTION VARCHAR2 (50)
SHIPMENT_STATUS_CD VARCHAR2 (10)
SHIPMENT_EVENT_DATE VARCHAR2 (10)
SHIPMENT_EVENT_TIME VARCHAR2 (10)
EVENT_TIME_ZONE VARCHAR2 (30)
EVENT_CITY VARCHAR2 (100)
EVENT_STATE VARCHAR2 (50)
EVENT_ZIP VARCHAR2 (50)
CUSTOMER_CONFIRM VARCHAR2 (100)
DELIVERY_CONFIRM VARCHAR2 (100)
TRACKING_NUMBER VARCHAR2 (50)
MAIL_REC_WEIGHT VARCHAR2 (20)
MAIL_REC_WEIGHT_CD VARCHAR2 (10)
MAIL_RED_QTY VARCHAR2 (10)
INSERT_USER VARCHAR2 (50)
DATE OF INSERT_USER_DATE
INSERT_STATUS_CODE VARCHAR2 (10)
In light of this data file:
Oracle: mydb$ cat eds_edstest.dat
HDR, 0005114090, MYORG, CSV, MY NAME OF THE COMPANY, 123 ELM ST, STUCKYVILLE, OH, 12345
DTL, TOADSUCK, NC, 27999, NS, ARRIVED at the UNIT, X 4, 20140726, 063100, AND, TOADSUCK, NC,.3861, 27999, 12345, 23456 lbs, 1
DTL, TOADSUCK, NC, 27999, lbs, 1 NS, SORTING COMPLETE, X 6, 20140726, 080000, AND TOADSUCK, NC,.3861, 27999, 12345, 23456
DTL, TOADSUCK, NC, 27999, NS, PRONOUNCED, D1, 20140726, 121800, TOADSUCK, NC, 27999, 12345, 23456,.3861, lbs and 1
Given this control sqlloader file:
Oracle: mydb$ cat eds_edstest_combined.ctl
Load
INFILE ' / xfers/oracle/myapp/data/eds_edstest.dat'
BADFILE ' / xfers/oracle/myapp/data/eds_edstest.bad'
DISCARDFILE ' / xfers/oracle/myapp/data/eds_edstest.dsc'
ADD
IN THE TABLE estevens.edstest_header
WHERE (rec_type = 'HDR')
FIELDS TERMINATED BY ', '.
SURROUNDED OF POSSIBLY "" "
TRAILING NULLCOLS
(rec_type CHAR,
sold_to_account TANK,
scac_receiver_id TANK,
format_type TANK,
client_name TANK,
customer_pickup_address TANK,
customer_pickup_city TANK,
customer_pickup_state TANK,
customer_pickup_zip TANK,
INSERT_USER "1"
INSERT_USER_DATE sysdate,
INSERT_STATUS_CODE CONSTANT 'I')
IN THE TABLE estevens.edstest_detail
WHERE (rec_type = 'PIF')
FIELDS TERMINATED BY ', '.
SURROUNDED OF POSSIBLY "" "
TRAILING NULLCOLS
(rec_type CHAR,
ship_to_name TANK,
ship_to_address TANK,
ship_to_city TANK,
ship_to_state TANK,
ship_to_zip TANK,
status_or_appt_reason_cd TANK,
event_description TANK,
shipment_status_cd TANK,
shipment_event_date TANK,
shipment_event_time TANK,
event_time_zone TANK,
event_city TANK,
Event_State TANK,
event_zip TANK,
customer_confirm TANK,
delivery_confirm TANK,
tracking_number TANK,
mail_rec_weight TANK,
mail_rec_weight_cd TANK,
mail_red_qty TANK,
INSERT_USER "1"
INSERT_USER_DATE sysdate,
INSERT_STATUS_CODE CONSTANT 'I')
-END CONTROL FILE
And the time of execution of transactions:
SQL * Loader: release 11.2.0.3.0 - Production the kill Jul 29 07:50:04 2014
Copyright (c) 1982, 2011, Oracle and/or its affiliates. All rights reserved.
Control file: /xfers/oracle/myapp/control/eds_edstest_combined.ctl
Data file: /xfers/oracle/myapp/data/eds_edstest.dat
Bad leadership: /xfers/oracle/myapp/data/eds_edstest.bad
Delete the file: /xfers/oracle/myapp/data/eds_edstest.dsc
(Allow all releases)
Number of loading: ALL
Number of jump: 0
Authorized errors: 50
Link table: 10000 lines, maximum of 256000 bytes
Continuation of the debate: none is specified
Path used: classics
Silent options: your COMMENTS
Table ESTEVENS. EDSTEST_HEADER, loaded when REC_TYPE = 0 X 484452 (character "HDR") add the option in effect for this table: APPEND TRAILING NULLCOLS option in effect
Column Position Len term Encl. Datatype name
------------------------------ ---------- ----- ---- ---- ---------------------
FIRST REC_TYPE *, O ("") CHARACTER
SOLD_TO_ACCOUNT NEXT *, O ("") CHARACTER
SCAC_RECEIVER_ID NEXT *, O ("") CHARACTER
FORMAT_TYPE NEXT *, O ("") CHARACTER
CLIENT_NAME NEXT *, O ("") CHARACTER
CUSTOMER_PICKUP_ADDRESS NEXT *, O ("") CHARACTER
CUSTOMER_PICKUP_CITY NEXT *, O ("") CHARACTER
CUSTOMER_PICKUP_STATE NEXT *, O ("") CHARACTER
CUSTOMER_PICKUP_ZIP NEXT *, O ("") CHARACTER
INSERT_USER NEXT *, O ("") CHARACTER
The SQL string for the column: "1."
INSERT_USER_DATE SYSDATE
CONSTANT INSERT_STATUS_CODE
The value is 'I '.
Table ESTEVENS. EDSTEST_DETAIL, loaded when REC_TYPE = 0X44544c ('PIF' character) in effect for this table insert option: APPEND TRAILING NULLCOLS option in effect
Column Position Len term Encl. Datatype name
------------------------------ ---------- ----- ---- ---- ---------------------
REC_TYPE NEXT *, O ("") CHARACTER
SHIP_TO_NAME NEXT *, O ("") CHARACTER
SHIP_TO_ADDRESS NEXT *, O ("") CHARACTER
SHIP_TO_CITY NEXT *, O ("") CHARACTER
SHIP_TO_STATE NEXT *, O ("") CHARACTER
SHIP_TO_ZIP NEXT *, O ("") CHARACTER
STATUS_OR_APPT_REASON_CD NEXT *, O ("") CHARACTER
EVENT_DESCRIPTION NEXT *, O ("") CHARACTER
SHIPMENT_STATUS_CD NEXT *, O ("") CHARACTER
SHIPMENT_EVENT_DATE NEXT *, O ("") CHARACTER
SHIPMENT_EVENT_TIME NEXT *, O ("") CHARACTER
EVENT_TIME_ZONE NEXT *, O ("") CHARACTER
EVENT_CITY NEXT *, O ("") CHARACTER
EVENT_STATE NEXT *, O ("") CHARACTER
EVENT_ZIP NEXT *, O ("") CHARACTER
CUSTOMER_CONFIRM NEXT *, O ("") CHARACTER
DELIVERY_CONFIRM NEXT *, O ("") CHARACTER
TRACKING_NUMBER NEXT *, O ("") CHARACTER
MAIL_REC_WEIGHT NEXT *, O ("") CHARACTER
MAIL_REC_WEIGHT_CD NEXT *, O ("") CHARACTER
MAIL_RED_QTY NEXT *, O ("") CHARACTER
INSERT_USER NEXT *, O ("") CHARACTER
The SQL string for the column: "1."
INSERT_USER_DATE SYSDATE
CONSTANT INSERT_STATUS_CODE
The value is 'I '.
value used for the parameter LINES increased from 10000 to 30 sheet 2: discarded - failed all WHEN clauses.
Sheet 3: Discarded - failed all WHEN clauses.
Folder 4: Discarded - failed all WHEN clauses.
Table ESTEVENS. EDSTEST_HEADER:
1 row loaded successfully.
0 rows not loaded due to data errors.
3 rows not loading because all WHEN clauses were failed.
0 rows not populated because all fields are null.
Table ESTEVENS. EDSTEST_DETAIL:
0 rows successfully loaded.
0 rows not loaded due to data errors.
4 rows not loading because all WHEN clauses were failed.
0 rows not populated because all fields are null.
The space allocated to bind table: 247800 byte (30 lines)
Bytes of read buffer: 1048576
Total logical records ignored: 0
Total logical records read: 4
Total rejected logical records: 0
Logical records discarded total: 3
Run started the kill Jul 29 07:50:04 2014
Run finished on Tue Jul 29 07:50:04 2014
Time was: 00:00:00.07
Time processor was: 00:00:00.01
It works on linux, and the file data calculated from a Windows system to the time we get to it, but it's in the * nix format - with a simple x '0A' as the line terminator.
If, in the control file, I comment on the block of INSERTION for the header table, retail inserts very well.
If, in the control file, (return to the initial charge, two tables) I change the line
INFILE ' / xfers/oracle/myapp/data/eds_edstest.dat'
To read
INFILE ' / xfers/oracle/myapp/data/eds_edstest.dat' "str" | "» \n' »
The saved result becomes
Table ESTEVENS. EDSTEST_HEADER:
1 row loaded successfully.
0 rows not loaded due to data errors.
0 rows not loading because all WHEN clauses were failed.
0 rows not populated because all fields are null.
Table ESTEVENS. EDSTEST_DETAIL:
0 rows successfully loaded.
0 rows not loaded due to data errors.
1 row not loaded because all WHEN clauses were failed.
0 rows not populated because all fields are null.
I try to help the developer on this, and it resists change to use external tables. Even if I can overcome that, I now have a puzzle I want to solve, just to add to my knowledge. Plus, I have some concerns at this stage that whatever it is that miss me here could also come into play if I convert external tables.
Ed,
Are you sure that put you the post in the right place? It should be located in the first definition of the following field each time after the first when clause clause. Put after the first when the clause is optional. When I use the following with what you have provided, it loads 1 record in the table header and 3 records in the Details table. Did you actually do or tell your developer to do and wish that he understood and put it in the right place?
Load
INFILE 'eds_edstest.dat '.
BADFILE "eds_edstest.bad."
DISCARDFILE 'eds_edstest.dsc '.
ADD
IN THE TABLE edstest_header
WHERE (rec_type = 'HDR')
FIELDS TERMINATED BY ', '.
SURROUNDED OF POSSIBLY "" "
TRAILING NULLCOLS
(rec_type CHAR,
sold_to_account TANK,
scac_receiver_id TANK,
format_type TANK,
client_name TANK,
customer_pickup_address TANK,
customer_pickup_city TANK,
customer_pickup_state TANK,
customer_pickup_zip TANK,
INSERT_USER "1"
INSERT_USER_DATE sysdate,
INSERT_STATUS_CODE CONSTANT 'I')
IN THE TABLE edstest_detail
WHERE (rec_type = 'PIF')
FIELDS TERMINATED BY ', '.
SURROUNDED OF POSSIBLY "" "
TRAILING NULLCOLS
(rec_type POSITION (1) TANK,
ship_to_name TANK,
ship_to_address TANK,
ship_to_city TANK,
ship_to_state TANK,
ship_to_zip TANK,
status_or_appt_reason_cd TANK,
event_description TANK,
shipment_status_cd TANK,
shipment_event_date TANK,
shipment_event_time TANK,
event_time_zone TANK,
event_city TANK,
Event_State TANK,
event_zip TANK,
customer_confirm TANK,
delivery_confirm TANK,
tracking_number TANK,
mail_rec_weight TANK,
mail_rec_weight_cd TANK,
mail_red_qty TANK,
INSERT_USER "1"
INSERT_USER_DATE sysdate,
INSERT_STATUS_CODE CONSTANT 'I')
-
Two tables with different values of basic on an analysis filter
Hi guys,.
Let assume that I have an analysis with columns: group_id and sales.
On this basis I would like to create two tables: table1 where group_id = 1 and table2 where group_id = 2.
OBIEE is able to do?
Kind regards
SlaviHi Slavi,
You can do it in a single analysis, but you have to have the column with group_id twice.
Bring, group_id_1, group_id_2 (same column), sale
Now in table 1.
bring group_id_1, sales
Then in the selection steps for group_id_1-> select members-> Action choose keep only-> choose the value of the filter 1
This will filter the table 1 with group_id 1
In table2 group_id_2 porter, sales
Then do the same step for group_id_2 with the value 2.
You now have two reports with different filter in the same report.
If you want you can keep the same name column for the two columns group_id, I just kept group_id_1, group_id_2 for easy reference.
-
How to subtract two table of 1 d (uint16) same size
I need to remove two 1 d (uint16) same size table. with output as follows...
x - y = result (EXPECTED)
5 - 2 = 3
4 - 0 = 4
0-4 = 0
2 - 3 = 0
If the difference is less than zero value must be zero. Currently, if I use the digital subtraction... I get...
x - y = result (OBSERVED)
5 - 2 = 3
4 - 0 = 4
0-4 = 4
2 - 3 = 1
Thank you
Hello rajxabc,
I don't know why you expect whole math unsigned to produce a 0 in the script show you below. The U16 ends actually spent 0.
Thus,.
0-1 = 65535
0-2 = 65534
0-3 = 65533
If you want to change the standard behavior of the unsigned integer math, you need to create a special algorithm for this, produce something like:
There are a number of ways that you can accomplish this, but at the end of the day, I don't know that I would be the label none of them "expected."
Maybe you are looking for
-
Portege Z930 - impossible to boot from the external USB CD/DVD drive
I have a portege Z930 14UI am not able to boot from an external linke (Samsun SE-218) CD player via USB I already set the boot sequence and choosed CSM as model BIOS Thank youAndrea
-
I bought COD MS2 and when I try to install STEAM, either on the CD of the game, either by the direct d/l on the STEAM website, I get nothing. I have updated my video drivers for more late and am running Vista 64 bit. Help, please... Thank you
-
I need to install Microsoft NET Framework 3.5 Service Pack 1, as it is necessary to perform a Dell diagnostic Test, but I've been advised that: Setup has detected that this computer does not meet the requirements to install this software. Requirement
-
folder Windows will compress not do I need shellbrd.dll
I tried to reduce my windows folder (in this moment is 17 GB) to give me more disk space (very slow pc) on a 32 GB L/top. All the others check the pc is clean, defraged, swept, blown, washed and dried. Told me to compress the folder but it stops sayi
-
Does anyone know if there is a default Q10 data usage meter or do I have to download an application? Thanks in advance