CTL file in OWB 9.2

I have a mapping with file as source. I want to generate a CTL file that contains actual physical directory of my location and not the location name. I have specified my own path where the control file for this mapping should get generated.
(1) When I generate this mapping <map.ctl> file has location_name of the file module and not the physical path in the ctl script.
(2) When I deploy this mapping - ctl file is not generated in the specified directory.
(3) Only when I execute this mapping thru OWB that a CTL file containing the physical location of the data file is generated in the OS directory.
My questions are :
(1) How do I generate a CTL file containing physical location - without executing the mapping thru OWB. I want to do that so that I can run from sqlldr directly.
(2) What is the function of Deploy in case of file to table mappings.
(3) What is the OWB recommended way of deploying and executing such mappings involving sqlldr in prod environment.

Vibha,
Sorry for the late response.
(1) How do I generate a CTL file containing physical location - without executing the mapping thru OWB. I want to do that so that I can run from sqlldr directly.
There should be no need to run from sqlldr directly. Warehouse Builder manages the execution in which case you get all the error handling and logging included in the runtime audit browser.
(2) What is the function of Deploy in case of file to table mappings.
Deploy stores the control file in the runtime repository, so that it can be picked up at execution time, temporarily be stored on the file system and OWB will then execute SQL loader natively.
(3) What is the OWB recommended way of deploying and executing such mappings involving sqlldr in prod environment.
Deploy to the production environment and execute it through OEM or a command line scheduling.
Mark.

Similar Messages

  • OWB: .ctl files deployment

    Hi
    I'd like to know why OWB doesn't give me the option to deploy
    the generated .ctl scripts; in fact, the only two available
    options are "view code" and "save as file".
    I am working with OWB 3i and an Oracle 8.1.6 data base.
    Thanks for your help!

    Hi,
    OWB can't deploy Ctl file because it doesn't use SQL Loader.
    YOu need to use either OEM 2.2 with register your run.ini either
    SQL loader in your console.
    With OEM it seem to work fine. But don't forget to put good
    value in the OWB configure mapping....
    Good luck
    E.R

  • Error in scheduling a mapping with sqlloader ctl file

    Hi everyone,
    I have been trying to schedule a single mapping which generates sqlloader ctl file. but i get the error
    ORA-20001: Begin. initialize complete. workspace set. l_job_audit_execution_id= 20545. ORA-20001: Please check execution object is deployed correctly. ORA-01403: no data found ORA-06512: at "USER7.PMAP_TLOG_JOB", line 180 ORA-20001: Please check execution object is deployed correctly. ORA-01403: no data found
    but when i attach this mapping with a process flow it works fine. There is no error.
    so my question is in OWB is it a must that we should attach the mapping which generates sqlloader ctl file to a process flow and then schedule it or can we schedule a single mapping which generates sqlloader ctl file and what should be the process to schedule a single mapping which generates sqlloader ctl file?
    can anyone please help?
    Thanks & Regards
    Subhasree

    Hi Nawneet,
    Any suggestions?
    can anybody else also help me in this error???
    Regards
    Subhasree

  • Extracting data from flat file in OWB

    Hi,
    Does anyone know, how to run a mapping having source as flat file in OWB?
    I am facing a problem as run button becomes disabled as it is SQL Loader script.
    When I register the TCL script with OEM it doesn't pass the name of the CTL file
    as parameter and so the job fails.
    If anyone knows how to do it, please reply.
    Regards
    -Yogesh

    Hi Bhavesh ,
    The data type beimg given is of this format :
    TLOG          Root Node     Structure     1..n
    STORECODE               
    TILLID               
    TXDATE               
    POSTDATE               
    TXTIME               
    TXSERIAL               
    TXBATCH               
    DOCNO               
    VOIDDOCNO               
    TXTYPE               
    TXMSG
    TMSG is the field conatinig the message ( stated in my mail ) .
    Thanks
    Anita Yadav

  • Need help to use 'When' clause in CTL file

    Hi,
    I have a requirement
    in ctl file while loading file names in to a table we need to ignore if the filename already exist in the table
    eg:
    load infile.txt
    into a
    when filename not in (select filename from a) append
    filename varchar(1000)
    is it possible?? any way to achieve this?? Pleas help..
    Thanks in advance..

    user3647602 wrote:
    Hi,
    I have a requirement
    in ctl file while loading file names in to a table we need to ignore if the filename already exist in the table
    eg:
    load infile.txt
    into a
    when filename not in (select filename from a) append
    filename varchar(1000)
    is it possible?? any way to achieve this?? Pleas help..
    Thanks in advance..Easiest method i can think of would be to use an EXTERNAL TABLE instead of SQL LOADER.
    Much more flexible.
    Cheers,

  • SQL Loader : Loading multiple tables using same ctl file

    Hi ,
    We tried loading multiple tables using the same ctl file but the data was not loaded and no errors were thrown.
    The ctl file content is summarised below :
    LOAD DATA
    APPEND INTO TABLE TABLE_ONE
    when record_type ='EVENT'
    TRAILING NULLCOLS
    record_type char TERMINATED BY ',' ,
    EVENT_SOURCE_FIELD CHAR TERMINATED BY ',' ENCLOSED BY '"',
    EVENT_DATE DATE "YYYY-MM-DD HH24:MI:SS" TERMINATED BY ',' ENCLOSED BY '"',
    EVENT_COST INTEGER EXTERNAL TERMINATED BY ',' ENCLOSED BY '"',
    EVENT_ATTRIB_1 CHAR TERMINATED BY ',' ENCLOSED BY '"',
    VAT_STATUS INTEGER EXTERNAL TERMINATED BY ',' ENCLOSED BY '"',
    ACCOUNT_REFERENCE CONSTANT 'XXX',
    bill_date "to_date('02-'||to_char(sysdate,'mm-yyyy'),'dd-mm-yyyy')",
    data_date "trunc(sysdate)",
    load_date_time "sysdate"
    INTO TABLE TABLE_TWO
    when record_type ='BILLSUMMARYRECORD'
    TRAILING NULLCOLS
    RECORD_TYPE char TERMINATED BY ',' ,
    NET_TOTAL INTEGER EXTERNAL TERMINATED BY ',' ENCLOSED BY '"',
    LOAD_DATE_TIME "sysdate"
    INTO TABLE BILL_BKP_ADJUSTMENTS
    when record_type ='ADJUSTMENTS'
    TRAILING NULLCOLS
    RECORD_TYPE char TERMINATED BY ',' ,
    ADJUSTMENT_NAME CHAR TERMINATED BY ',' ENCLOSED BY '"',
    LOAD_DATE_TIME "sysdate"
    INTO TABLE BILL_BKP_CUSTOMERRECORD
    when record_type ='CUSTOMERRECORD'
    TRAILING NULLCOLS
    RECORD_TYPE char TERMINATED BY ',' ,
    GENEVA_CUSTOMER_REF CHAR TERMINATED BY ',' ENCLOSED BY '"',
    LOAD_DATE_TIME "sysdate"
    INTO TABLE TABLE_THREE
    when record_type ='PRODUCTCHARGE'
    TRAILING NULLCOLS
    RECORD_TYPE char TERMINATED BY ',' ,
    PROD_ATTRIB_1_CHRG_DESC CHAR TERMINATED BY ',' ENCLOSED BY '"',
    LOAD_DATE_TIME "sysdate"
    Has anyone faced similar errors or are we going wrong somewhere ?
    Regards,
    Sandipan

    This is the info on the discard in the log file :
    Record 1: Discarded - failed all WHEN clauses.
    Record 638864: Discarded - failed all WHEN clauses.
    While some of the records were loaded for one table.
    Regards,
    Sandipan

  • Error while importing CTL FILE?

    Hi
    I am using Oracle 9i to Import Data from a disk file to the table in the database.
    Here are the CTL File and .Dat file i am using to import data to the database.
    Book1.CTL
    load data
    infile 'E:\Oracle\ORADATA\oracle9\SAMPLEDATA.DAT' "str '|\n'"
    into table sampletable
    fields terminated by ',' optionally enclosed by '"'
    (SNO1 NUMBER,SNO2 NUMBER,SNO3 NUMBER,SNO4 NUMBER,SNO5 NUMBER,SNO6 NUMBER,SNO7 NUMBER,SNO8 NUMBER,SNO9 NUMBER,SNO10 NUMBER,SN011 NUMBER,SNO12 NUMBER)
    Sampledata.dat
    1,2,3,4,5,6,7,8,9,10,11,12,|
    1,2,3,4,5,6,7,8,9,10,11,12,|
    I already created a table with 12 columns as specified in the ctl file. I am trying to import data from a disk file ie from sampledata.dat file.
    I am seeing the following error in JOBS.
    VNI-2015 : The Node preferred credentials for the target node are either invalid
    or do not have sufficient privileges to complete the operation.
    On Windows platforms, the Node credentials specified for the Windows target
    should have the "Logon as a batch job" privilege.
    What do i need to do in order to succeed saving the data into the database?
    Can anyone help in this issue?
    Thanks
    srinivas

    Hi, i think that your problem is about the authentification credentials with Oracle Agent On Windows system. If you need execute jobs and task with this agent you must config correctly the environment. The OS user that you use must have the privilegies for execute "Logon as a batch job", this configuration must set into Control Panel>Administration Tools>Local Security Police>User Rights Assigments>Logon as a batch job, here you must add the user to this police.
    Luck.
    Have a good day.
    Regards.

  • Error while load the data from CSV with CTL file..?

    Hi TOM,
    When i try to load data from CSV file to this table,
    CTL File content:
    load data
    into table XXXX append
         Y_aca position char (3),
         x_date position date 'yyyy/mm/dd'
    NULLIF (x_date = ' '),
    X_aca position (* + 3) char (6)
    "case when :Y_aca = 'ABCDDD' and :XM_dt is null then
    decode(:X_aca,'AB','BA','CD',
    'DC','EF','FE','GH','HG',:X_aca)
    else :X_aca
    end as X_aca",
    Z_cdd position char (2),
         XM_dt position date 'yyyy/mm/dd'
    NULLIF XM_dt = ' ',
    When I try the above CTL file; geting the following error..
    SQL*Loader-281: Warning: ROWS parameter ignored in parallel mode.
    SQL*Loader-951: Error calling once/load initialization
    ORA-02373: Error parsing insert statement for table "XYZ"."XXXX".
    ORA-00917: missing comma

    Possible Solutions
    Make sure that the data source is valid.
    Is a member from each dimension specified correctly in the data source or rules file?
    Is the numeric data field at the end of the record? If not, move the numeric data field in the data source or move the numeric data field in the rules file.
    Are all members that might contain numbers (such as "100") enclosed in quotation marks in the data source?
    If you are using a header, is the header set up correctly? Remember that you can add missing dimension names to the header.
    Does the data source contain extra spaces or tabs?
    Has the updated outline been saved?

  • Generation of Control file in OWB Mapping.

    Hi All,
    OWB config details is as follows:
    OWB 9i :9.2.0.2.8
    OWB Repository: 9.2.0.2.0
    OWB 9i Client OS: Windows XP Environment
    Oracle DB 9i Enterprise Edition 9.2.0.1.0-64 bit Production on IBM AIX machine.
    I developed mapping which involved a source file (CSV) & oracle table as target.
    Validated & Generated mapping. No error displayed.
    Configured mapping set Data File Location, Bad File Location, Log File Location (All these parameters were set to point to different directories in unix.)
    Registered all the above location in Deployment Manager.
    Deployed the mapping & executed mapping.
    I was expecting control file generated by mapping to create on unix partition, however many times it did save on my local machine on Windows XP rather than on unix. The control file created in the local directory where OWB client is installed.
    When the same mapping is executed from another machine still the file was created on my local machine.
    This was observed after I created file location for Bad file & Log file from OWB.
    Why does control file is created on local machine rather than Unix Server?
    Can someone please let me know more on this?
    Thanks in Advance.
    Regards,
    Vidyanand

    Hi Vidyanand
    You may try to register physical file location under one logical location. Then register the location with physical datafile lication. It worked for us.
    Cheers, Bana

  • Upgrade cucm from 8.5 to 9.1 : Security issue (CTL Files)

    Hello All,
    I am in the process of performing a P2V upgrade from CUCM 8.5 to CUCM 9.1. The same IP address and Hostname on the new cluster will be kept.
    Could you please advise on what are the right steps to do this operation, knowing that I have deployed CTL files on my phones using usb etokens.
    My cluster includes 1 PUB + 8 SUB distributed over WAN.
    Total phones is : 1800 phones
    Only the Publisher will be upgraded to virtual instance. All subscribers servers will be kept at mcs.
    Actually, I'm working on the Publisher to restore the cucm DB v8.5, do an upgrade to v9 and test all phones behavior before upgrade the whole cluster.
    Do i to take care about subscribers before upgrade, knowing that tftp role is on different servers not only the publisher ?
    What is the behaviour of phones when going to the new cluster ?
    What is needed to be done in maintenance mode and in production mode ?
    Thanks,
    Driss

    What version of 8.5.1 are you on?  Look out for https://tools.cisco.com/bugsearch/bug/CSCtn50405/ which causes certificates to not be backed up properly so when you do the backup/restore you could run into problems.  The good news is that you are using CTLs which uses a physical token so you cannot run into a state where the phones do not trust anything (unless the tokens are lost/damaged of course).

  • CTL File creation in Lab/Upgrade

    Hello,
    My current production cluster has a CTL file installed. I am now working on setting up a lab environment inpreperation of an upgrade to simulate my current cluster settings..
    I need to create a CTL file for the new lab environement and had a couple of questions before moving ahead.
    1. Can I use the same security tokens I am using  for my production cluster?
    2. Will this somehow affect my tokens giving me a problem with my production cluster?
    3. When upgrading from 8.6.2 to 9.1.1 do I need to do anything with the CTL files or CTL client because of the version change?
    Thanks,
    Randall

    Edit the control file as
    I_CREATION_DATE sysdate,
    I_INVOICE_ID "EXT_IMP_INT_S.NEXTVAL",
    Sample:
    LOAD DATA
    truncate
    INTO TABLE test
    FIELDS TERMINATED BY ',' OPTIONALLY ENCLOSED BY '"' trailing nullcols
    (id "seq1.nextval",
    c1,
    c2,
    dt sysdate)
    {code}                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               

  • SQL LOADER / INFILE filename as variable in .ctl file

    I stumbled over several threads in the OTN-forums regarding this problem, but neither was it finaly solved nor did I find a FAQ that answered my question. Soooo:
    We get several datafiles from several sources and process them via SQL Loader and store 'em in the DB.
    This is done via a CHRON job and a PERL skript, for all datafiles in a specific directory.
    We need the information which file on which date generated the data INSIDE the DB as well.
    So I want to store the filename || SYSDATE combination as well.
    I know, I could parse the .ctl file and replace a key-string with the actual filename and so have it in the input.
    But this seems a bit dirty to me. Isn't there some way, i.e. a keyword or variable for the infile-filename within the SQLLoader that I can access in the .ctl file? Something like:
    INTO TABLE processed_files
    FIELDS TERMINATED BY ';'
    WHEN LOWER(LTRIM(RTRIM(hdr_ftr))) = 'ftr' -- FOOTER??
    (hdr_ftr VARCHAR2(100),
    source INFILE||' on '||TO_CHAR(SYSDATE, 'MM/DD/YYYY'),
    realm VARCHAR2(100),
    version VARCHAR2(20)
    I would be greatfull if you?d share your wisdom with me. ;-))
    Oliver

    I passed this quite similar to 'Ask Tom' and got the advice to put the .ctl's content as a string variable into a Shell skript.
    This shell skript (which had to be written anyway to loop over the datafiles an subsequently call the sqlldr) should then replace the INFILE parameter and the CONSTANTs for the filenames and generate a 'temporarry' .ctl before calling sqlldr!
    That's it, no better and safer way!

  • Field in data file exceeds maximum length - CTL file error

    Hi,
    I am loading data in new system using CTL file. But I am getting error as 'Field in data file exceeds maximum length' for few records, other records are processed successfully. I have checked the length of the error record in the extract file, it is less than the length in the target table, VARCHAR2 (2000 Byte). Below is the example of error data,
    Hi Rebecca~I have just spoken to our finance department and they have agreed that the ABCs payments made can be allocated to the overdue invoices, can you send any future invoices direct to me so that I can get them paid on time.~Hope this is ok ~Thanks~Terry~
    Is this error caused because of the special characters in the string?
    Below is the ctl file I am using,
    OPTIONS (SKIP=2)
    LOAD DATA
    CHARACTERSET WE8ISO8859P1
    INFILE  '$FILE'
    APPEND
    INTO TABLE "XXDM_DM_17_ONACCOUNT_REC_SRC"
    WHEN (1)!= 'FOOTER='
    FIELDS TERMINATED BY '|'
    OPTIONALLY ENCLOSED BY '"'
    TRAILING NULLCOLS (
                                  <Column_name>,
                                  <Column_name>,
                                  COMMENTS,
                                  <Column_name>,
                                  <Column_name>
    Thanks in advance,
    Aditya

    Hi,
    I suspect this is because of the built in default length of character datatypes in sqldr - it defaults to char(255) taking no notice of what the actual table definition is.
    Try adding CHAR(2000), to your controlfile so you end up with something like this:
    OPTIONS (SKIP=2)
    LOAD DATA
    CHARACTERSET WE8ISO8859P1
    INFILE  '$FILE'
    APPEND
    INTO TABLE "XXDM_DM_17_ONACCOUNT_REC_SRC"
    WHEN (1)!= 'FOOTER='
    FIELDS TERMINATED BY '|'
    OPTIONALLY ENCLOSED BY '"'
    TRAILING NULLCOLS (
                                  <Column_name>,
                                  <Column_name>,
                                  COMMENTS CHAR(2000),
                                  <Column_name>,
                                  <Column_name>
    Cheers,
    Harry

  • Loading xml file using owb

    Hi Gurus,
    I am new to owb and as per requirement we need to load xml files into oracle table using owb.
    below is the xml file:
    <bookstore>
    <book category="COOKING">
    <title lang="en">Everyday Italian</title>
    <author>Giada De Laurentiis</author>
    <year>2005</year>
    <price>30.00</price>
    </book>
    <book category="CHILDREN">
    <title lang="en">Harry Potter</title>
    <author>J K. Rowling</author>
    <year>2005</year>
    <price>29.99</price>
    </book>
    <book category="WEB">
    <title lang="en">Learning XML</title>
    <author>Erik T. Ray</author>
    <year>2003</year>
    <price>39.95</price>
    </book>
    </bookstore>
    please help me in loading above xml file using owb.

    You can leverage the XML SQL functions to extract from XML using the database, see the blog post below;
    https://blogs.oracle.com/warehousebuilder/entry/leveraging_xdb
    For example to extract information from your XML document the following SQL can be generated from OWB;
    select extractValue(value(s), '/book/author'),
    extractValue(value(s), '/book/year'),
    extractValue(value(s), '/book/price') from
    ( select XMLType('<bookstore>
    +<book category="COOKING">+
    +<title lang="en">Everyday Italian</title>+
    +<author>Giada De Laurentiis</author>+
    +<year>2005</year>+
    +<price>30.00</price>+
    +</book>+
    +<book category="CHILDREN">+
    +<title lang="en">Harry Potter</title>+
    +<author>J K. Rowling</author>+
    +<year>2005</year>+
    +<price>29.99</price>+
    +</book>+
    +<book category="WEB">+
    +<title lang="en">Learning XML</title>+
    +<author>Erik T. Ray</author>+
    +<year>2003</year>+
    +<price>39.95</price>+
    +</book>+
    +</bookstore>') adoc from dual+) r,
    table(XMLSequence(extract(r.adoc, '/bookstore/book'))) s;
    Cheers
    David

  • Hw to skip first field of input file in ctl file and map other fields- cols

    I need to write a ctl file where in my input file has 3 fields by comma separated.
    My table has 2 columns. In my ctl file I am using
    LOAD
    INFILE *
    TERMINATED BY ','
    COL1 need second field in the file
    COL2 need third field in the file
    Not sure how to skip the first field.

    Not sure abt it as
    load data
    infile *
    into table [table name]
    terminated by ','
    (COL1 has to be filled wth second field of the data file,
    COL2 has to be filled wth third field of the data file )
    i need to skip first field of the data file.

Maybe you are looking for