Problems running owb 10gr2 package (mapping) from sqlplus
not sure what i'm doing wrong.
here is how i am trying to do it:
1 declare
2 out1 varchar2(100);
3 begin
4 entity_map.main( p_status => out1
5 , P_MAX_NO_OF_ERRORS => '50'
6 , P_COMMIT_FREQUENCY => '1000'
7 , P_OPERATING_MODE => 'SET_BASED'
8 , P_BULK_SIZE => '50'
9 , P_AUDIT_LEVEL => 'AUDIT_COMPLETE'
10 , P_PURGE_GROUP => 'WB'
11 );
12 dbms_output.put_line('Result = '||out1);
13* end;
SQL> /
entity_map.main( p_status => out1
ERROR at line 4:
ORA-06550: line 4, column 1:
PLS-00306: wrong number or types of arguments in call to 'MAIN'
ORA-06550: line 4, column 1:
PL/SQL: Statement ignored
here is the procedure spec:
PROCEDURE Main(p_status OUT VARCHAR2, "TRUNCATE_LOAD" IN VARCHAR2
DEFAULT 'false', "AW_EXECUTE_RESULT" OUT NOCOPY VARCHAR2,
p_max_no_of_errors IN VARCHAR2 DEFAULT NULL,
p_commit_frequency IN VARCHAR2 DEFAULT NULL,
p_operating_mode IN VARCHAR2 DEFAULT NULL,
p_bulk_size IN VARCHAR2 DEFAULT NULL,
p_audit_level IN VARCHAR2 DEFAULT NULL,
p_purge_group IN VARCHAR2 DEFAULT NULL)
any ideas?
nevermind..i needed to pass in another variable for "AW_EXECUTE_RESULT"
Similar Messages
-
Executing a mapping from sqlplus in OWB 904
I have used the below syntax to execute OWB 902 mappings as below:
sqlplus / <<*sql*
Execute MAP_SOMETHING.MAIN();
sql
I deployed the same mapping with new version of OWB 904.. it did not work. What is new syntax to execute the mapping from sqlplus?From OWB 9.0.4 on, you must use the execution template to execute your mappings from sql. The template file, that has a brief doc section in its heading is:
<OWB installation directory>/owb/rtp/sql/sqlplus_exec_template.sql
Regards:
Igor -
I have a problem, when I execute an mapping from Desing Center, its frezeen
I have a problem, when I execute an mapping from Desing Center, its frezeen, this doesnt send error can you help me plis
AliIf I would be you, I will check mapping activity from backend using (TOAD/SESSION-BROWSER) your map should be under JDBC THIN CLIENT. Also check if your target table is locked by running this query (select
c.owner,
c.object_name,
c.object_type,
b.sid,
b.serial#,
b.status,
b.osuser,
b.machine
from
v$locked_object a ,
v$session b,
dba_objects c
where
b.sid = a.session_id
and
a.object_id = c.object_id;). -
Problem by transporting the message mapping from PI 7.0 to PI 7.1
Hi Everyone,
by transporting the message mapping from PI 7.0 to PI 7.1 i have got the following problem.
"Source code has syntax error:
K:\usr\sap\E71\DVEBMGS00\j2ee\cluster\serve......
package udfpool does not exist
import udfpool.*;
i have used a UDF in my message mapping.
This UDF calls for a method of a java class, which is imported as a .jar file with this message mapping.
this message mapping works very well on PI 7.0,
but doesn't work any more on PI 7.1 because of the problem described above.
anyone can help me out of this problem?
thanks!
zchi,
but did you import the jar archive to 7.1 first?
Regards,
Michal Krawczyk
http://mypigenie.com XI/PI FAQ -
What kind of wrapper Program for Running OWB 10g Packages
Hi,
We are migrating our mapping from OWB 9.i to OWB 10.g. Earlier we were using a scheduling tool and through that we used to execute the package for the OWB Mapping from SQL Prompt with th below mentioned command at SQL PLUS.
execute &procname..main(:operating_mode,:audit_level,:max_errors,:commit_frequency,:bulk_size);
Here &procname is the name of the OWB 9.i Package.
Kindly Suggest how do we do this with an OWB 10.g Mapping.
ThanksMy new classroom is being set up and I have two computers to practice on at this moment. I did try internet sharing and it worked between the main computer and a student computer (that is the main computer was wired to the network, and the student iMac was the client), and this was without a router: the main computer had a wireless network "MacBook" and I connected to it through Airport, and I had perfect access to the internet.
I'm going to sound very naive here but if all I have are the main and three student computers, can't they all just be connected directly to the main computer without a router, like I have done as described above?
But isn't file sharing what I need not internet sharing? -
Strange problem with executing PL/SQL procedure from sqlplus.
Hello,
basicly, I'm strugling with executing a procedure written in PL/SQL from sqlplus.
It's all because I convert a data in procedure by other function.
SELECT partition_name
INTO strpartition
FROM user_tab_partitions
WHERE table_name = tablename_in
and substr(partition_name, -8, length(partition_name)) = (SELECT F_CONVERT_DATE(tablename_in,p_date) from dual);
/tablename_in and p_date are input parameters/
Function F_CONVERT_DATE looks more less like :
select
TO_CHAR(TRUNC(NEXT_DAY(ADD_MONTHS(substr(partition_name, -8, length(partition_name)), -3), 'MONDAY')-7), 'YYYYMMDD')
END
AS p_date
INTO v_okr
FROM user_tab_partitions
where substr(partition_name, -8, length(partition_name)) = p_date;
Well, the thing is that procedure is executable from TOAD without any errors !! But when I try to execute it straight from sqlplus it returns:
ORA-01861: literal does not match format string
ORA-06512: at "F_CONVERT_DATE", line 13
ORA-06512: at "NAME_OF_PROCEDURE", line 17
Tip: When I don't use functions ADD_MONTHS, NEXT_DAY and TO_CHAR in function F_CONVERT_DATE sqlplus can execute it. But only when I use them it returns an error.
Anybody has a clue how to solve it?
Regards !Hi, Nodex,
Avoid implicit conversions.
For example:
TO_CHAR(TRUNC(NEXT_DAY(ADD_MONTHS(substr(partition_name, -8, length(partition_name)), -3), 'MONDAY')-7), 'YYYYMMDD')ADD_MONTHS expects a DATE as its first argument.
SUBSTR returns a VARCHAR2, so you're calling ADD_MONTHS with a VARCHAR2 where it expects a DATE.
For good or ill, the system tries to avoid raising an error in this case by implicitly converting the VARCHAR2 to a DATE. Exactly how it does that depends on
(a) the tool you are using (SQL*Plus or Toad, for example),
(b) the version (Oracle 10 behaved quite different form Oracle 9),
(c) environmental settings (such as NLS_DATE_FORMAT), which in turn may depend on initialization parameneters, and
(d) who knows what else.
When you have to convert, do so explicitly.
You can convert a VARCHAR2 to a DATE using TO_DATE, like this:
TO_CHAR ( TRUNC ( NEXT_DAY ( ADD_MONTHS ( TO_DATE ( SUBSTR ( partition_name
, -8
, LENGTH (partition_name)
, 'YYYYMMDD' -- or whatever
, -3
, 'MONDAY'
- 7
, 'YYYYMMDD'
) -
Executing an OWB mapping from sqlplus
Hi
I am trying to run an OWB mapping using the OWB provided script sqlplus_exec_template.sql. Here is the syntax I use:
@Script\sql\sqlplus_exec_template.sql OWB_RUN_OWNER CODE_LOC PLSQL MAPPING_TI "," ","
I am able to successfully execute my task when I use the above script. However, when the account pertaining to 'CODE_LOC' is locked, the script fails and gives me an error message that the account is locked.
Our security standards expect the CODE_LOC account to be locked. Is there a way around it ? When the mapping is executed, does the Runtime repository owner lookup the task from the Code location or attempts to connect to the account ?
Can someone advise me on whether I can successfully execute a mapping that is deployed to a locked account ?
ThanksHi
The only way I can think of is when the account X is locked, to have granted execute on the packages for the map to schema Y which is unlocked and execute the package MAIN procedure/function from schema Y.
Cheers
David -
Problem Experts OWB 10gR2 - Mapping with OMB - Give a name to the flat file
I'm trying to create a mapping in OWB by using the Experts (OMB),
where the data source is a database table and the target is a flat file (to transform a table to a flat file).
The tasks of my Experts :
This task create a mapping, and add a existing table on it.
OMBCC '$thepath'
catch {OMBDROP MAPPING 'M1'}
OMBCREATE MAPPING 'M1'
OMBALTER MAPPING 'M1' \
ADD $INITIAL_LAUNCH_CONTEXT_TYPE OPERATOR '$thetable' \
BOUND TO $INITIAL_LAUNCH_CONTEXT_TYPE \ '$INITIAL_LAUNCH_CONTEXT' \
This task change the context and create a flat file
OMBCC '/PRJ_LABO_PHARMA/SRC_FILE'
catch {OMBDROP FLAT_FILE 'NEW_FILE'}
OMBCREATE FLAT_FILE 'NEW_FILE' \
SET PROPERTIES (DATA_FILE_NAME) VALUES('fichier_genere.txt')
This task add the flat file to the mapping, and create a connection between the source (table) and the target (flat file)
OMBCC '/PRJ_LABO_PHARMA/MOD_SRC_LABO'
OMBALTER MAPPING 'M1' \
ADD FLAT_FILE OPERATOR 'NEW_FILE'\
BOUND TO FLAT_FILE '/PRJ_LABO_PHARMA/SRC_FILE/NEW_FILE' \
OMBALTER MAPPING 'M1' \
ADD CONNECTION FROM GROUP 'INOUTGRP1' OF OPERATOR '$thetable' \
TO GROUP 'NEW_FILE' OF OPERATOR 'NEW_FILE' COPY ALL
This task update the flat file structure
OMBRECONCILE MAPPING 'M1' OPERATOR 'NEW_FILE' \
TO FLAT_FILE '/PRJ_LABO_PHARMA/SRC_FILE/NEW_FILE' \
USE (RECONCILE_STRATEGY 'REPLACE', MATCHING_STRATEGY 'MATCH_BY_OBJECT_ID')
Then I have a task which execute this mapping.
Everything is good, but during the execution I have a error VLD-2357 : The target file's name is not indicated for the file NEW_FILE.
I don't know how to give a name to the flat file in OMB.
Help me please.
Best regards
SamyJust like if you built this in the UI where you would have to configure the flat file operator and define a target data file name and possibly the location these properties should be set in scripting.
Set the property TARGET_DATA_FILE_NAME to the name of the data file.
Something like....
OMBALTER MAPPING 'M1' \
MODIFY FLAT_FILE OPERATOR 'NEW_FILE' SET PROPERTIES (TARGET_DATA_FILE_NAME) VALUES ('my_datafile.csv')
Cheers
David -
Edit package body from sqlplus
HI,
I usually use SQL developer to create and edit my packages which usually worked fine. But the problem for today is that I can not save only packageA's body, and the others can be saved well. ( the SQL developer just runs for ever when I click save)
And I try to edit it using sqlplus, but I don't know the syntax for it.
Any help appreciated!!HI, thanks so much for your help!
The final solution was to create a new package with same code, and of course, with new updates.
The new problem is : no way to drop the old package( tried many times):
Error starting at line 1 in command:
drop package packageA
Error report:
SQL Error: ORA-04021: timeout occurred while waiting to lock object
04021. 00000 - "timeout occurred while waiting to lock object %s%s%s%s%s"
*Cause: While waiting to lock a library object, a timeout is occurred.
*Action: Retry the operation later. -
Reverse engineering OWB (11.2) maps from SQL
Hi,
Is there a way to reverse engineer SQL code into OWB Maps using Experts. I have seen one for older version of OWB, but wondering if it's possible (or can one use the same downloads) for the new version.
http://blogs.oracle.com/warehousebuilder/2007/08/sql_and_owb_accelerated_map_co.html
Thanks.Use the same MDL it will be upgraded when you import the MDL, any problems let me know.
Cheers
David -
Minor question / problem with OWB 10gR2 demo tutorial
Hi, I'm working on the OWB tutorial demo for 10gR2 that was just released, and have a question. At the start of the chapter on "Designing ETL Data Flow Mappings", as part of the workflow manager install instructions, it says to execute the following:
grant owb_o_rep_owner to owf_mgr;
I can't find the role owb_o_rep_owner anywhere - should this instead be owb_o_owb_owner?
Thanks in advance,
ScottOne more question - does anyone know how to install the demo / tutorial on a different server? I.e. I've had the DBAs get OWB installed on a QA server, but they are busy and don't have time to do the install of the tutorial. Can I install it remotely some way (note that when I tried, I kept getting errors from OMB saying it couldn't deploy things remotely or something).
Thx in advance,
Scott -
Problem with OWB export ext table from dev to prod not the same
Hi everyone,
I created a lot of external table in dev and everything works fine, but as I did a mdl export in production about half of my ext tables dont work anymore and I found in the script created by the export/import in OWB something strange: here is a exemple of script :
CREATE TABLE TBL_AGENTNOTREADYBREAK_EXT
STARTDATETIME VARCHAR2(23 BYTE),
DSTSTATUS INTEGER,
SWITCHID INTEGER,
AGENTID INTEGER,
NOTREADYREASON INTEGER,
INTERVALDURATION INTEGER,
INTERVALID INTEGER,
NUMBEROFTIMESPRESSED INTEGER,
DURATION INTEGER,
ROLLEDUP INTEGER
ORGANIZATION EXTERNAL
( TYPE ORACLE_LOADER
DEFAULT DIRECTORY SOURCE_FICHIER_LOCATION
ACCESS PARAMETERS
( RECORDS DELIMITED BY NEWLINE
CHARACTERSET UTF16
STRING SIZES ARE IN CHARACTERS
NOBADFILE
NODISCARDFILE
LOGFILE SOURCE_FICHIER_LOCATION:'NOTREADY'
FIELDS
TERMINATED BY '\t'
RTRIM
OWBUNUSED0 CHAR,
OWBUNUSED1 CHAR,
OWBUNUSED2 CHAR,
OWBUNUSED3 CHAR,
OWBUNUSED4 CHAR,
OWBUNUSED5 CHAR,
OWBUNUSED6 CHAR,
OWBUNUSED7 CHAR,
OWBUNUSED8 CHAR,
OWBUNUSED9 CHAR
LOCATION (SOURCE_FICHIER_LOCATION:'Stat_AgentNotReadyBreakdown_I.dat')
REJECT LIMIT UNLIMITED
NOPARALLEL
NOMONITORING;
in dev the OWBUNESED# does not exist it is rather the name of the field between double quote as they are in the first part of the script.
Why is that?, cause when I change the script in the database then my tables are accessing the data correctly. What caused this difference. Am I using the wrong method to deploy in Production?
Database version 10R2
Repository 10.2.0.4.36
Thank you all
JacquesHi Oleg,
Yes I did check the box for dependencies, you must note that I have something like 20 file definitons hence external tables and only 5 or 6 that had the problem, solving it by hand, still wandering what went wrong.
Thanks -
How to Execute a OWB Mapping or a Process from SQLPLUS editor?
I need to know how can we execute a OWB mapping from SQLPLUS editor or from a Stored Procedure.
Hi,
You can use the MDL export/import utility for this, but as you are importing into the same repository you will end up with importing into the same project again.
So for this you can follow the workaround as:
->Take export of the required mapping from the project OWB_B
-> Rename the Project OWB_B to some thing like OWB_B_1(or any other name), note that you have to rename both logical and physical name of the project
-> Rename the project OWB_A to OWB_B and if you import the MDL all the objects will be imported to OWB_B then you can rename back the project to OWB_A
-> Finally rename the project OWB_B_1 to OWB_B (to its original name).
Regards,
Pnreddy -
OWB 10gr2 - MDL1601 and MDL1201 - Metadata Import Problems
I am running OWB 10gr2 on top of a 10gr2 database for the repository. I'm trying to do an export of an entire project into MDL, and then import it into another repository in a different environment, with same setup (both OWB and database are 10gr2 there as well).
The export goes fine, but when trying to import, I get two different error messages:
1) After selecting the MDL file to import, if I click the "Import" button I get a-
"MDL1601: Cannot import because the base language in the MDL file is missing"
2) Also if I try to click the "Show Summary" or "Advanced..." buttons on the import screen, I instead get a-
"MDL1201: Import file is not valid. Metadata Loader release must by specified in import data file using the MDLRELEASE keyword."
As to the first error, I have verified in my source repository that the Base Language is in fact listed as "American English", and have even gone so far as to add basic "English" as an additional display language using the repository assistance, but this brings no improvement.
As to the second error, I have already found the post here in the forums explaining that it is due to a corrupted MDL file because of insufficient Java VM memory. However, I have tried the solution recommended there, also with no improvement. (it is here: Re: MDL1201: Import data file is not valid.
Any help that someone can provide would be greatly appreciated. For purposes of backing up my repository project, I'm getting concerned that if I ever needed to, I'd never be able to restore from a MDL export file!
Thanks in advance for any help.The error is due to the corrupted MDL file. MDL is getting corrupted because there is not enough memory for java VM. To fix the MDL corruption increase memory parameters.
1. On client PC: XXXX\owb\bin\win32\owbclient.bat change
java -Xms64M -Xmx768M -Dlimit=768M -XX:MaxPermSize=256M
to
java -Xms64M -Xmx1024M -Dlimit=1024M -XX:MaxPermSize=512M
Restart client session.
It did fix the problem in my case.
Oracle also recommends changing memory parameters on the server side (UNIX in my case)
2.On server side XXXX/owb/bin/unix/run_service.sh
$JAVAPATH/bin/java -Xmx768M
to
$JAVAPATH/bin/java -Xmx1024M -
Running Class in package?
I have problem running class in package. What do I write (win) to make the class in a packege run? If I remove it from the package I just write: java MyClass.
If it is in package com.bananaco, for example, then at
the command line you must type
java com/bananaco/MyClassI'd refrain from calling it that way, as it leads to confusion.
The standard way is to call it fully qualified
java -cp <classpath> com.bananaco.MyClass
under any JAVA release with the classpath set appropriately (rename <classpath> with yout path to directory where com is located in exmpale above).
Take in mind that the directory structure should reflect the package structure (having MyClass.class under com/banaco in the class path)
Oliver
>
That works for Java 2, but I sort of recall that for
Java 1 you had to use
java com.bananaco.MyClass
instead. So try both. And if you get NoClassDefFound
error, remember that the package has to be in
your classpath, not the class.
Maybe you are looking for
-
Hello Experts, Requesting your suggestions/solutuon to the below issue on availabiltiy control. Few days back we faced a issue that , the AVAC status set for the projects automatically gets deactivated and we were not able to set the AVAC status back
-
hi...Fri's i exported data from dev to quality using CMS , when i am trying to import the data in CMS , the import failed.. how can i import the data in CMS.. thanks in Advance, Pasi.
-
HELP: Mac Pro restarts when waking from sleep
the problem just started a few days ago. i hadn't made any mods or installed any new software. all firmware is current. i've reset the NVRAM and SMC with no results. any suggestions?
-
HP Deskjet 6980-print cartridge error
I replaced both ink cartridges.Once I closed the lid and error came on my screen telling me Print Cartridge error- tri color. and the tri color light blinks continuously???
-
Need help setting up DIal-Up (PPP) on Leopard.
Hey guys. I work tech support/setups for a (very) small dial-up ISP, and my cheap (expletive) boss won't sign off on getting us a copy of Leopard. They feel there aren't enough people with it yet for it to be worth the expense... and so any customers