How to load error table from mapping
i have one doubt regarding including error table in mapping.
i am here with table structure,
map_name varchar2(30),
source_name varchar2(15),
transformation_stage varchar2(100),
source_name varchar2(30),
target_table varchar2(30),
error_field varchar2(100),
error_message varchar2(225),
Execution_date date.
this table i have to include in all mappings and i have to load the errors in this table.please guide me
how to include this table and load the errors.if you have any code please send me.
with regards
narendra.p.v
just kind of workout(rather call it as template) as post mapping process...
declare
-- in this cusor, you can include mor attributes in SELECT clause
cursor cur_audit is SELECT a.RTE_IID,
a.RTA_IID,
a.RTE_ROWKEY,
a.RTE_SQLERRM,
c.TASK_NAME,
-- the return_result attribute, which will get the value only after the mapping completed(/ or exited) including post process
case when a.RTE_IID is null then
'SUCCESS'
else
'FAILURE'
end RETURN_RESULT,
c.RETURN_CODE,
c.NUMBER_OF_TASK_ERRORS,
c.NUMBER_OF_TASK_WARNINGS,
c.CREATION_DATE, c.LAST_UPDATE_DATE
FROM WB_RT_ERRORS a,
WB_RT_AUDIT b,
WB_RT_AUDIT_EXECUTIONS c
WHERE b.RTe_ID = ANY(SELECT MAX(AUDIT_EXECUTION_ID) FROM WB_RT_AUDIT_EXECUTIONS)
AND b.rta_iid = a.rta_iid(+)
AND b.RTE_ID = c.AUDIT_EXECUTION_ID;
begin
for i in cur_audit
loop
insert into cs_event_template values(ccv_event_seq.nextval,i.task_name,i.return_result,i.return_code,i.number_of_task_errors,
i.number_of_task_warnings,i.rte_sqlerrm,i.rte_rowkey,i.rta_iid,i.rte_iid,i.creation_date,i.last_update_date);
end loop;
commit;
exception
when others then
dbms_output.put_line('Error: '||SQLErrm);
end ;
You will get more than this and/or if you have just simple plan than this , would you mind to just let us know...
Similar Messages
-
How to use error table in mapping level?
Hi all
Any one please tell me how to use error table in mapping level or how to handle the errors in mapping.
I am creating one error table in oracle but i dont know how to use it in mapping.
Thanks in advance.
KumarHi Kumar,
You need to use Error Table along with the Data Rule .
Error tables are used with Logical error handlers (Data Rules). Detailed description on using data rules is explained in the following document
http://www.oracle.com/technology/products/warehouse/pdf/OWB10gR2_ETLandBusinessRules.pdf
In a nut shell usage of error tables is as follows.
1. Create a data rule associate it with a table (Target table or table in which you load data).
2. Use the table in a mapping as target table.
3. Deploy the table and mapping.
Now in the target schema one more table will be created with the name <target table name>_ERR. When a mapping is executed the data which violates the data rule gets into this error table.
The following has to be done to have error table name of customers choice.
1. Right click on the table and click configure.
2. Give the table name in "shadow table name" section.
3. Deploy the table.
4. Use this table in a mapping. Now in the mapping on this table properties in "Error Table Name" section the name of the table specified in "shadow table name" will be populated.
Thanks,
Sutirtha -
How to Load the data from excel file(Extension is .CSV) into the temp.table
Hi
How to Load the data from excel file(Extension is .CSV) into the temporary table of oracle in Forms11g.
My Forms Version is - Forms [64 Bit] Version 11.1.2.0.0 (Production)
Kindly Suggest the Solution.
Regards,
SachinHello Sachin,
You can use the following metalink note:How to Read Data from an EXCEL Spreadsheet into a Form Using Webutil Client_OLE2 (Doc ID 813535.1) and modify it a little bit.
Instead of copy values into forms you can save them in your temporary table.
Kind regards,
Alex
If someone's helpful or correct please mark it accordingly. -
How to load the data from .csv file to oracle table???
Hi,
I am using oracle 10g , plsql developer. Can anyone help me in how to load the data from .csv file to oracle table. The table is already created with the required columns. The .csv file is having about 10lakh records. Is it possible to load 10lakh records. can any one please tell me how to proceed.
Thanks in advance981145 wrote:
Can you tell more about sql * loader??? how to know that utility is available for me or not??? I am using oracle 10g database and plsql developer???SQL*Loader is part of the Oracle client. If you have a developer installation you should normally have it on your client.
the command is
sqlldrType it and see if you have it installed.
Have a look also at the FAQ link posted by Marwin.
There are plenty of examples also on the web.
Regards.
Al -
How to load the data from excel file into temprory table in Forms 11g?
Hi
How to Load the data from excel file(Extension is .CSV) into the temporary table of oracle in Forms11g.
My Forms Version is - Forms [64 Bit] Version 11.1.2.0.0 (Production)
Kindly Suggest the Solution.
Regards,
SachinDeclare
v_full_filename varchar2(500);
v_server_path varchar2(2000);
v_separator VARCHAR2(1);
v_filename VARCHAR2(400);
filename VARCHAR2 (100);
v_stop_load varchar2 (2000);
v_rec_error_log varchar2(4000);
v_error_log varchar2(4000);
ctr NUMBER (12);
cols NUMBER (2);
btn number;
RES BOOLEAN;
application ole2.obj_type;
workbooks ole2.obj_type;
workbook ole2.obj_type;
worksheets ole2.obj_type;
worksheet ole2.obj_type;
cell ole2.obj_type;
cellType ole2.OBJ_TYPE;
args ole2.obj_type;
PROCEDURE olearg
IS
args ole2.obj_type;
BEGIN
args := ole2.create_arglist;
ole2.add_arg (args, ctr);
ole2.add_arg (args, cols);
cell := ole2.get_obj_property (worksheet, 'Cells', args);
ole2.destroy_arglist (args);
END;
BEGIN
v_full_filename := client_get_file_name(directory_name => null
,file_name => null
,file_filter => 'Excel files (*.xls)|*.xls|'
||'Excel files (*.xlsx)|*.xlsx|'
,message => 'Choose Excel file'
,dialog_type => null
,select_file => null
If v_full_filename is not null Then
v_separator := WEBUTIL_CLIENTINFO.Get_file_Separator ;
v_filename := v_separator||v_full_filename ;
:LOAD_FILE_NAME := substr(v_filename,instr(v_filename,v_separator,-1) + 1);
RES := Webutil_File_Transfer.Client_To_AS(v_full_filename,"server_path"||substr(v_filename,instr(v_filename,v_separator,-1) + 1));
--Begin load data from EXCEL
BEGIN
filename := v_server_path||substr(v_filename,instr(v_filename,v_separator,-1) + 1); -- to pick the file
application := ole2.create_obj ('Excel.Application');
ole2.set_property (application, 'Visible', 'false');
workbooks := ole2.get_obj_property (application, 'Workbooks');
args := ole2.create_arglist;
ole2.add_arg (args, filename); -- file path and name
workbook := ole2.get_obj_property(workbooks,'Open',args);
ole2.destroy_arglist (args);
args := ole2.create_arglist;
ole2.add_arg (args, 'Sheet1');
worksheet := ole2.get_obj_property (workbook, 'Worksheets', args);
ole2.destroy_arglist (args);
ctr := 2; --row number
cols := 1; -- column number
go_block('xxx');
FIRST_RECORD;
LOOP
--Column 1 VALUE --------------------------------------------------------------------
olearg;
v_stop_load := ole2.get_char_property (cell, 'Text'); --cell value of the argument
:item1 := v_stop_load;
cols := cols + 1;
--Column 2 VALUE --------------------------------------------------------------------
olearg;
:item2 := ole2.get_char_property (cell, 'Text'); --cell value of the argument
cols := cols + 1;
--<and so on>
ole2.invoke (application, 'Quit');
ole2.RELEASE_OBJ (cell);
ole2.RELEASE_OBJ (worksheet);
ole2.RELEASE_OBJ (worksheets);
ole2.RELEASE_OBJ (workbook);
ole2.RELEASE_OBJ (workbooks);
ole2.RELEASE_OBJ (application);
END;
--End load data from EXCELPlease mark it as answered if you helped. -
How to load the data from excel file into table in oracle using UTL_FI
How to load the data from excel file into table in oracle
and from table to excel file
using UTL_FILE package
Please give me some exampleThis is something i tried in oracle apex
http://avdeo.com/2008/05/21/uploading-excel-sheet-using-oracle-application-express-apex/
Regards,
CKLP -
How to load color table in a indexed mode file??
How to load color table in a indexed mode file??
Actually, if i opened a indexed file and want to edit color table by loading another color table from desktop (or any other location), any way to do this through java scripting??continuing...
I wrote a script to read a color table from a GIF file and save to an ACT color table file. I think it might be useful for someone.
It goes a little more deeper than the code I posted before, as it now identifies the table size. It is important because it tells how much data to read.
Some gif files, even if they are saved with a reduced palette (less than 256), they have all the bytes for the full color palette filled inside the file (sometimes with 0x000000). But, some gif files exported in PS via "save for web" for example, have the color table reduced to optimize file size.
The script store all colors into an array, allowing some kind of sorting, or processing at will.
It uses the xlib/Stream.js in xtools from Xbytor
Here is the code:
// reads the color table from a GIF image
// saves to an ACT color table file format
#include "xtools/xlib/Stream.js"
// read the 0xA byte in hex format from the gif file
// this byte has the color table size info at it's 3 last bits
Stream.readByteHex = function(s) {
function hexDigit(d) {
if (d < 10) return d.toString();
d -= 10;
return String.fromCharCode('A'.charCodeAt(0) + d);
var str = '';
s = s.toString();
var ch = s.charCodeAt(0xA);
str += hexDigit(ch >> 4) + hexDigit(ch & 0xF);
return str;
// hex to bin conversion
Math.base = function(n, to, from) {
return parseInt(n, from || 10).toString(to);
//load test image
var img = Stream.readFromFile("~/file.gif");
hex = Stream.readByteHex(img); // hex string of the 0xA byte
bin = Math.base(hex,2,16); // binary string of the 0xA byte
tableSize = bin.slice(5,8) // Get the 3 bit info that defines size of the ct
switch(tableSize)
case '000': // 6 bytes table
tablSize = 2
break;
case '001': // 12 bytes table
tablSize = 4
break;
case '010': // 24 bytes table
tablSize = 8
break;
case '011': // 48 bytes table
tablSize = 16
break;
case '100': // 96 bytes table
tablSize = 32
break;
case '101': // 192 bytes table
tablSize = 64
break;
case '110': // 384 bytes table
tablSize = 128
break;
case '111': // 768 bytes table
tablSize = 256
break;
//========================================================
// read a color (triplet) from the color lookup table
// of a GIF image file | return 3 Bytes Hex String
Stream.getTbColor = function(s, color) {
function hexDigit(d) {
if (d < 10) return d.toString();
d -= 10;
return String.fromCharCode('A'.charCodeAt(0) + d);
var tbStart = 0xD; // Start of the color table byte location
var colStrSz = 3; // Constant -> RGB
var str = '';
s = s.toString();
for (var i = tbStart+(colStrSz*color); i < tbStart+(colStrSz*color)+colStrSz; i++) {
var ch = s.charCodeAt(i);
str += hexDigit(ch >> 4) + hexDigit(ch & 0xF);
return str;
var colorHex = [];
importColors = function (){
for (i=0; i< tablSize; i++){ // number of colors
colorHex[i] = Stream.getTbColor(img, i);
importColors();
// remove redundant colors
// important to determine exact color number
function unique(arrayName){
var newArray=new Array();
label:for(var i=0; i<arrayName.length;i++ ){
for(var j=0; j<newArray.length;j++ ){
if(newArray[j]==arrayName[i])
continue label;
newArray[newArray.length] = arrayName[i];
return newArray;
colorHex = unique(colorHex);
// we have now an array with all colors from the table in hex format
// it can be sorted if you want to have some ordering to the exported file
// in case, add code here.
var colorStr = colorHex.join('');
//=================================================================
// Output to ACT => color triplets in hex format until 256 (Adr. dec 767)
// if palette has less than 256 colors, is necessary to add the
// number of colors info in decimal format to the the byte 768.
ColorNum = colorStr.length/6;
lstclr = colorStr.slice(-6); // get last color
if (ColorNum < 10){
ColorNum = '0'+ ColorNum;
cConv = function (s){
var opt = '';
var str = '';
for (i=0; i < s.length ; i++){
for (j=0; j<2 ; j++){
var ch = s.charAt(i+j);
str += ch;
i ++;
opt += String.fromCharCode(parseInt(str,16));
str = '';
return opt
output = cConv(colorStr);
// add ending file info for tables with less than 256 colors
if (ColorNum < 256){
emptyColors = ((768-(colorStr.length/2))/3);
lstclr = cConv(lstclr);
for (i=0; i < emptyColors ; i++){
output += lstclr; // fill 256 colors
output += String.fromCharCode(ColorNum) +'\xFF\xFF'; // add ending bytes
Stream.writeToFile("~/file.act", output);
PeterGun -
How to load the data from informatica into bw & how to report the data
Hi friends,
how to load the data from informatica into bw & how to report the data
using cognos.(i.e how to access the data in sap bw using cognos 8 BI suite).
Thanks,
madhu.Inorder to report BW data into Cognos you can extract data from using Open Hub to the DB table from which Cognos reads.
For BW informatic integration refer following docs:
http://www.aman.co.il/aman/pfd/DataInteg_BR.q103cd.pdf.pdf
http://h71028.www7.hp.com/enterprise/cache/3889-0-0-225-121.html
http://devnet.informatica.com/learning/ePresentations.asp
http://72.14.203.104/search?q=cache:C741L86Q19oJ:devnet.informatica.com/showcase/resources/Essbase_DataSheet.pdfinformaticapowerconnect(BI)&hl=en&gl=in&ct=clnk&cd=3
http://www.informatica.com/customers/utilities_energy/fpl_group.htm
http://www.informatica.com/solutions/resource_center/technote_sapbw_65241004.pdf#search=%22Informatica%20to%20Bw%22 -
SQL Loader to Load Multiple Tables from Multiple Files
Hi
I wish to create a control file to load multiple tables from multiple files
viz.Emp.dat into emp table and Dept.dat into Dept table and so on
How could I do it?
Can I create a control file like this:
OPTIONS(DIRECT=TRUE,
SKIP_UNUSABLE_INDEXES=TRUE,
SKIP_INDEX_MAINTENANCE=TRUE)
UNRECOVERABLE
LOAD DATA
INFILE 'EMP.dat'
INFILE 'DEPT.dat'
INTO TABLE emp TRUNCATE
FIELDS TERMINATED BY "|" OPTIONALLY ENCLOSED BY '"'
(empno,
ename,
deptno)
INTO TABLE dept TRUNCATE
FIELDS TERMINATED BY "|" OPTIONALLY ENCLOSED BY '"'
(deptno,
dname,
dloc)
Appreciate a Quick Reply
mailto:[email protected]Which operating system? ("Command Prompt" sounds like Windows)
UNIX/Linux: a shell script with multiple calls to sqlldr run in the background with "&" (and possibly nohup)
Windows: A batch file using "start" to launch multiple copies of sqlldr.
http://www.pctools.com/forum/showthread.php?42285-background-a-process-in-batch-%28W2K%29
http://www.microsoft.com/resources/documentation/windows/xp/all/proddocs/en-us/start.mspx?mfr=true
Edited by: Brian Bontrager on May 31, 2013 4:04 PM -
Java Procedure to load Oracle Table from flat file
Hi,
I am trying to load oracle table from data in flat file.
Anybody help me out.
I am using following code but it is giving invalid sql statement error
try {
// Create the statement
Statement stmt = conn.createStatement();
// Load the data
String filename = "c:\\temp\\infile.txt";
String tablename = "TEST";
// If the file is comma-separated, use this statement
stmt.executeUpdate("LOAD DATA INFILE" + "c:\\temp\\infile.txt" + "INTO TABLE "
+ "TEST" + " FIELDS TERMINATED BY ','");
stmt.close();
conn.close();
} catch (SQLException e) {
e.printStackTrace();
}I will appriciate your help.
Thanks.I tried the following too but getting same error.
try {
// Create the statement
Statement stmt = conn.createStatement();
// Load the data
String filename = "c:\\temp\\infile.txt";
String tablename = "TEST";
// If the file is comma-separated, use this statement
stmt.executeUpdate("LOAD DATA INFILE \"" + filename + "\" INTO TABLE "
+ tablename + " FIELDS TERMINATED BY ','");
//If the file is terminated by \r\n, use this statement
//stmt.executeUpdate("LOAD DATA INFILE \"" + filename + "\" INTO TABLE "
//+ tablename + " LINES TERMINATED BY '\\r\\n'");
stmt.close();
conn.close();
} catch (SQLException e) {
e.printStackTrace();
}Any Idea ? -
How can we copy table from one schema to other schema
Hi,
I have create one table in one schema and i want to copy it to other schema.How we can copy table from one schema to other schemaHi,
You can try something like this :-
SQL> CONNECT SYS/SYS123@SERVER AS SYSDBA
Connected.
SQL> CREATE USER TEST_1 IDENTIFIED BY TEST_1;
User created.
SQL> CREATE USER TEST_2 IDENTIFIED BY TEST_2;
User created.
SQL> GRANT CONNECT,RESOURCE,DBA TO TEST_1;
Grant succeeded.
SQL> GRANT CONNECT,RESOURCE,DBA TO TEST_2;
Grant succeeded.
SQL> CONNECT TEST_1/TEST_1@SERVER
Connected.
SQL> CREATE TABLE TEST_COPY ( TEST_COL NUMBER );
Table created.
SQL> INSERT INTO TEST_COPY VALUES ( 1 );
1 row created.
SQL> INSERT INTO TEST_COPY VALUES ( 2 );
1 row created.
SQL> COMMIT;
Commit complete.
SQL> GRANT ALL ON TEST_COPY TO TEST_2;
Grant succeeded.
SQL> CONNECT TEST_2/TEST_2@SERVER
Connected.
SQL> CREATE TABLE TEST_COPY AS SELECT * FROM TEST_1.TEST_COPY;
Table created.
SQL> SELECT * FROM TEST_COPY;
TEST_COL
1
2Regards,
Sandeep -
Can someone tell me how I load my music from my itunes account onto my new macbook pro??
can someone tell me how to load my music from my itunes account on my iphone to my new macbook pro?
See Here
iTunes: How to move your music to a new computer -
how can i import tables from a different schema into the existing relational model... to add these tables in the existing relational/logical model? plss help
note; I already have the relational/logical model ready from one schema... and I need to add few more tables to this relational/logical model
can I import the same way as I did previously??
but even if I do the same how can I add it in the model?? as the logical model has already been engineered..
please help ...
thanksHi,
Before you start, you should probably take a backup copy of your design (the .dmd file and associated folder), in case the update does not work out as you had hoped.
You need to use Import > Data Dictionary again, to start the Data Dictionary Import Wizard.
In step 1 use a suitable database connection that can access the relevant table definitions.
In step 2 select the schema (or schemas) to import. The "Import to" field in the lower left part of the main panel allows you to select which existing Relational Model to import into (or to specify that a new Relational Model is to be created).
In step 3 select the tables to import. (Note that if there are an Foreign Key constraints between the new tables and any tables you had previously imported, you should also include the previous tables, otherwise the Foreign Key constraints will not be imported.)
After the import itself has completed, the "Compare Models" dialog is displayed. This shows the differences between the model being imported and the previous state of the model, and allows you to select which changes are to be applied.
Just selecting the Merge button should apply all the additions and changes in the new import.
Having updated your Relational Model, you can then update your Logical Model. To do this you repeat the "Engineer to Logical Model". This displays the "Engineer to Logical Model" dialog, which shows the changes which will be applied to the Logical Model, and allows you to select which changes are to be applied.
Just selecting the Engineer button should apply all the additions and changes.
I hope this helps you achieve what you want.
David -
How to get internal table from SAP Data Provider C#
Hello.
ABAP:
DATA: lt_t001 TYPE TABLE OF t001.
DATA: url(1000) TYPE c.
SELECT * INTO TABLE lt_t001 FROM t001.
CALL FUNCTION 'DP_CREATE_URL'
EXPORTING
type = 'APPLICATION'
subtype = 'X-R3TABLE'
TABLES
data = lt_t001
CHANGING
url = url
EXCEPTIONS
OTHERS = 4.
C#:
using SAPDataProvider;
using SAPTableFactoryCtrl;
public void SetDataFromUrl(string url)
SAPDataProviderClass p = new SAPDataProviderClass();
p.SetDataFromURL("APPLICATION", "X-R3TABLE", url);
ISapDPR3Table tbl = p.GetDataAsR3Table("APPLICATION", "X-R3TABLE");
SAPTableFactoryClass tf = new SAPTableFactoryClass();
Table tb = (Table)tf.NewTable();
tb.ISAPrfcITab = tbl.DataTable; // Exception !!!!!!
How to get internal table from SAP Data Provider ?Hi Sergey,
I'm trying to do the same, have you found a solution to solved it?
thanks for your help.
Regards.
Jonathan -
How to load master data from SAP R/3 system like Customer master, materioal master , vendor master.............
Hi Bramha,
Check ...........
Re: master data loading in BI 7.0
/message/4708129#4708129 [original link is broken]
Re: Master data loading.
Regards,
Vijay.
Maybe you are looking for
-
Iphoto freezes when I try to open it.
Iphoto freezes when I try to open it.
-
Memory ? & Program transfers? OS Mt. Lion Backup disk
Have several IMac's (5) 22" all intel duo core, (3) mini Macs duo core, (2) 24" Duo's. (1) 27", (1) MacBook Pro 17" duo. Do each of these units have their own set of rules to memory upgrades? Currently I'm trying to find out 24" which are DDR2 to 27
-
I want to purchase music but I cant get past the itunes 10 upgrade screen
I want to purchase music on i tunes but everytime I try i get the upgrade to itunes 10 screen. I dont want itunes 10 i like my old version
-
Hi there: My sales order was created on 11/12,then I went to schedule line item and selecing shipping tab,I found that delivery date is 11/23,goods issue date is 11/22,loading date is 11/19,material available date is 11/18,transportation plan date i
-
Linking Endnote X4 with WORD 2011 for mac.
My Endnote X4 software does not show up in my toolbar of WORD 2011. How do I tackle this problem?