Creating Configuration in OWB 11gR2 using OMB+ Scripts

Hi All,
Please help how to create a configuration pointing to another OWB Repository using OMB+ scripts.Also how to change the Active Deployment Location for a module using OMB+ Script.

Hi
Here is how you can add a new location to a module and set its configuration setting to this location (ADC);
OMBALTER ORACLE_MODULE 'TGT_MOD' ADD REF LOCATION 'ADC'
OMBALTER ORACLE_MODULE 'TGT_MOD' SET PROPERTIES (DB_LOCATION) VALUES ('ADC')
http://download.oracle.com/docs/cd/E11882_01/owb.112/e14406/chap3015.htm#DADFHBGE
Not sure if this is what you are after? To create a new configuration pointing to your own control center;
OMBCREATE CONTROL_CENTER 'MYCC' SET PROPERTIES ( etc...
OMBCREATE CONFIGURATION 'MYCONFIG'
OMBCC 'MYCONFIG'
OMBCREATE DEPLOYMENT 'MYCONFIGDEPLOY' SET REF CONTROL_CENTER 'MYCC'
Cheers
David

Similar Messages

  • Deploying mappings by changing Source/production system using OMB Scripting

    Hi Mark,
    I am now trying to deploy my mappings from DEVELOPMENT environment to PRODUCTION environment.
    Now my mappings are point to DEVELOPMENT Source System and DEVELOPMENT target system. When I deploy these mappings should point to PRODUCTION Source System and PRODUCTION target System.
    I could get some help from the forum for deploying the mappings point to PRODUCTION target system, but I couldnt find any help how to change the Source System Location. I have exported all my mappings (.xml files) in the C:\OWBDeploy directory.
    How do we register and unregister a location using OMB Scripting?
    How to write a batch deployment action without using deployment manager?
    Provide a example to deploy the mappings using OMB script
    for both source and target systems locations.
    I am using Oracle 9.2, OWB 9.2.0.2.8, OWF 2.6 and OMB 9.2.0.2.8.
    Regards,
    Shreedhar

    Below script will deploy all the mappings in a module. It can be used with filter condition like mappings which start with ‘M_D’ or ‘M_F’ also. Above script will deploy mappings very effectively comparing with GUI. Frequent problem in OWB mapping execution ‘ TASK not found’ error will not occur, if we deploy the mappings using above scripts.
    Steps to Deploy All Mappings in a Module
    Start the OMB PLUS from Command Prompt or Start Menu
    Change the context to the respective Project
    Connect to Design Repository
    Register the Location Properties if the deployment is happening first time in the target schema.
    Change the context to the respective Module
    Use foreach and OWBCREATE command to create a Deployment Plan for Droping if any previous deployment for all mappings
    Use foreach and OWBCREATE command to create a Deployment Plan for Newly Deploying the Mapping
    Use foreach and OWBDEPLOY command to run the Drop Deployment Plan
    Commit
    Use for each and OWBDEPLOY command to run the Create Deployment Plan
    Example
    OMBCONNECT mis_owb904_rep/[email protected]:1521:ulyut03s
    OMBCC '/IGMS_MIS_GEMNCAP_FOC'
    OMBCONNECT RUNTIME 'ST_DWH_RUNTIME_FOC' USE PASSWORD ‘MIS_RT_OWNER’
    OMBREGISTER LOCATION 'ST_LOC_CURRENTMISTARGET_FOC' SET PROPERTIES (Host, Port, Service, Schema, Password) \
    VALUES ('10.202.148.176', 1521, 'ULYUT01M','MIS_OWNER', 'MANAGER')
    OMBCC '/IGMS_MIS_GEMNCAP_FOC/CURRENTMISTARGET'
    foreach mappingname [OMBLIST MAPPINGS] {
    OMBCREATE TRANSIENT DEPLOYMENT_ACTION_PLAN '$mappingname.DROP' ADD ACTION '$mappingname.DROP' \
    SET PROPERTIES (OPERATION) VALUES ('DROP') SET REFERENCE MAPPING \
    '/IGMS_MIS_GEMNCAP_FOC/CURRENTMISTARGET/$mappingname';}
    foreach mappingname [OMBLIST MAPPINGS] {
    OMBDEPLOY DEPLOYMENT_ACTION_PLAN '$mappingname.DROP'
    OMBCOMMIT;}
    foreach mappingname [OMBLIST MAPPINGS] {
    OMBCREATE TRANSIENT DEPLOYMENT_ACTION_PLAN '$mappingname.CREATE' ADD ACTION '$mappingname.CREATE' \
    SET PROPERTIES (OPERATION) VALUES ('CREATE') SET REFERENCE MAPPING \
    '/IGMS_MIS_GEMNCAP_FOC/CURRENTMISTARGET/$mappingname';}
    foreach mappingname [OMBLIST MAPPINGS] {
    OMBDEPLOY DEPLOYMENT_ACTION_PLAN '$mappingname.CREATE'
    OMBCOMMIT;}

  • Setting PREFIX for DIMENSION_TABLE using OMB Scripting

    I'm trying all day to find a way to set PREFIX for DIMENSION_TABLE
    using OMB script without success and I'm a little confused now.
    First of all Scripting Reference does not mention about PREFIX
    property so maybe there is no way to achieve what I want. Consequently
    it would mean that GUI interface is "stronger" than OMB Scripting.
    Secondly I don't understand why when I issue following command in OMB
    Plus:
    OMBDESCRIBE CLASS_DEFINITION 'DIMENSION_TABLE' GET PROPERTY_DEFINITIONS
    I get nothing (empty output, no errors) and when I execute:
    OMBDESCRIBE CLASS_DEFINITION 'DIMENSION_TABLE' GET PROPERTIES
    (STEREOTYPE, IS_ABSTRACT, DESCRIPTION)
    I get:
    class false {}
    First result suggests that there are no properties for DIMENSION_TABLE
    and second proves that there are at least three.
    Is there some type/properties inheritance here?
    Can someone explain me this and tell how can I:
    1. find all valid types (I would like to set prefix for LEVEL,
    LEVEL_ATTRIBUTE, etc. too)
    2. find all properties for these types
    regards
    Tomasz Gajewski

    You misunderstood me. I don't want to rename DIMENSION_TABLE. When creating DIMENSION_TABLE with gui I set NAME and PREFIX for each DIMENSION_TABLE and LEVEL.
    PREFIX for level is used later during deploy to distinguish attributes from different levels.
    Example. If I have a level named LEVEL_NAME with prefix LN and an attribute of it named ID than table generated for this contains column LN_ID.
    When I create DIMENSION_TABLE using OMB Script prefix is set same as name (default behaviour that I can't change) and it is to long to use.
    Scripting Reference doesn't mention about PREFIX property. Should I assume that the only way to change these values are through OWB GUI?
    regards
    Tomasz Gajewski

  • Inserting sql scripts in OWB 10g using OMB PLUS

    Hey burleson, thanks for the reply..
    Infact i am new to OWB and my question can be very silly to you.
    Infact i have 1 source table in OWB named 'SALGRADE' which contains data and i have 1 target table named 'TARGET_SALGRADE' which has the same structure as the source table.
    The script i have run and tested is as such :
    INSERT INTO TARGET_SALGRADE
    (GRADE,
    LOSAL,
    HISAL)
    SELECT
    GRADE,
    LOSAL,
    HISAL
    FROM SCOTT.SALGRADE;
    I have tested it in sqlplus and the update has been done.
    Can you please tell me how do i proceed in OMB PLUS and how do i write the script there??
    Regards,
    Amrish

    You can run SQL scripts using the SQLPLus activity in a process flow.
    But the traditional mechanism to move data in OWB is using mappings. The post below might be interesting if you know SQL to understand how mappings are constructed;
    http://blogs.oracle.com/warehousebuilder/2007/08/sql_and_owb_accelerated_map_co.html
    Cheers
    David

  • Reverse owb objects to omb script

    Hi all,
    Has anyone ever developed something like that? I was thinking of developing an expert that could help me revert mappings and process flows into omb scripts so i can easily do new developments that most of the time just need to use a different table as source or something like that...
    If someone has already done that and would like to share it that would be great.
    Best regards,
    Bruno

    One thing to bear in mind is that while it is POSSIBLE to write a script to parse each object, figure out all of the dependencies, and generate a script that would recreate that object, there is one significant aspect which would be lacking.
    Geometry.
    There is no way via OMB to specify object location, so when you open your newly created mapping all of the canvas objects will be neatly stacked one atop the other in the center of the canvas.
    Not a huge deal to drag them all around and make the mapping readable, but still something you will need to do.
    That or you need to write in the SQL code to copy out the existing geometry, and then update it back after rebuilding using SQL calls, but this is entirely unsupported - especially if you were trying to work across OWB versions.
    Cheers,
    Mike

  • Error while listing tables using OMB script

    Hi All,
    I'm just trying to list certain tables in OWB that contain a specific column but the following script I wrote is not working:
    foreach tablename [OMBLIST TABLE TMP*] {
    set columnlist [OMBRETRIEVE TABLE '$tablename' GET COLUMNS];
    if {[lsearch $columnlist 'ID'] != -1} {
    puts "Table: $tablename";
    It returns the next error message:
    OMB01036: Object type must be plural.
    I've been searching for any documentation about this error but haven't found anything.
    Any help would be highly appreciated as I'm starting to learn about OMB scripts.
    Regards,
    Mauricio

    I tried that before and I got this error:
    OMB00001: Encountered TMP* at line:1 column:16. Was expecting one of: <EOF> <QUOTED_STRING>...
    It is strange because I wrote the code based on oracle documentation examples (Introduction to OMB Plus).
    I also tried removing the "TMP*" just to see if that worked, even though I only want to check for tables which name start with TMP, and at least it doesn't return any error but It doesn't list any table either (and I'm pretty sure there are tables that satisfy the conditions). The script right now is:
    foreach tablename [OMBLIST TABLES] {
    set columnlist [OMBRETRIEVE TABLE '$tablename' GET COLUMNS];
    if {[lsearch $columnlist 'ID'] != -1} {
    puts "Table: $tablename";
    I guess the solution must be simple but I can't see it. Any help?

  • Creating a random noise (Gaussian) using Matlab Script

    Hello,
    Since I only have Labview 6.1 base, I can't use the white-noise generator in Labview. I'm thinking of using the Matlab Script. I have Matlab 2006R installed in the same computer. However, I tried running the program and nothing happened (I used the help example "a=rand(50);surf(a)" in the Matlab Script.
    Why it's not calling the Matlab, or is there a better way to create a Gaussian distribution in Labview 6.1 Base?
    Thanks a lot!

    Hello,
    Why are you unable to use the Gaussian White Noise VI in LabVIEW 6.1?  It is under the Analyze >> Signal Processing >> Signal Generation palette.  I have attached a simple VI that illustrates creating a matrix.
    If you wish to use the MATLAB® script node, let's first make sure it is working correctly.  Try opening one of the LabVIEW shipping examples.  Browse to <LabVIEW>\examples\scriptnode and open "HiQMATLAB_Fractal.llb."  Then open "MATLAB Fractal.vi."  Run the VI.  Do you get any error windows that pop up?  If not and you see a picture of a fractal appear, then the connection to the MATLAB software is working correctly.  In your VI, try creating an error out indicator from the MATLAB script node and see if any errors appear.
    If you do see an error in the shipping example, it means there is a problem with the software connection.  Make sure that you have launched the MATLAB software at least once after you installed it.  This will set up the necessary connection information.  Then launch LabVIEW.  If this isn't the issue, we could try manually restoring the server commands.  Make sure LabVIEW and the MATLAB software are not running.  Go to a command prompt, browse to the MATLAB bin directory (e.g. MATLAB\R2006b\bin), and type
    matlab -regserver
    Quit the instance of the MATLAB software that appears and launch LabVIEW.  If this also fails, please post again with any error information you receive.
    Also, the rand function in your script will not generate a Gaussian distribution. You will need to use the randn function instead.
    MATLAB® is a registered trademark of The MathWorks, Inc.
    Grant M.
    Staff Software Engineer | LabVIEW Math & Signal Processing | National Instruments
    Edit: For some reason, I am unable to attach the VI.  I have included a picture instead.
    Message Edited by GrantM on 08-08-2008 02:50 PM
    Attachments:
    Gaussian Matrix.png ‏35 KB

  • OWB Paris and OMB Scripting

    Will my OMB and tcl scripts written in OWB 10g (for metadata management and deployment to production) upgradable when I go to next version of OWB code named 'Paris'?
    Thanks and Regards,
    Ayaz.

    Hi Maurice. It seems like Oracle is trying to reduce number of licenses with the OLAP option, since it should be possible to have both OLTP and OLAP systems in the very same instance.
    In the other hand, Oracle seems to want more money for "advanced ETL options", such as scheduling, metadata management, bla bla bla...
    But those "advanced" functions seems to me as something every ETL tool should provide. For free...

  • List of operators in OWB mapping using OMB Plus

    Hi,
    I got a situation where I need to find out the list of operators names and its type that I used in a mapping. I tried to search but could not find it. Can any body help me regarding this.
    Thanks in advance
    Yeswanth

    Try this and similarly you can get all operator.
    OMBRETRIEVE MAPPING 'MAP_NAME' GET TABLE OPERATORS
    OMBRETRIEVE MAPPING 'MAP_NAME' GET VIEW OPERATORS
    OMBRETRIEVE MAPPING 'MAP_NAME' GET TRANSFORMATION OPERATORS
    OMBRETRIEVE MAPPING 'MAP_NAME' GET TABLE_FUNCTION OPERATORS
    Cheers
    Nawneet
    Edited by: Nawneet_Aswal on Aug 30, 2010 8:43 AM

  • How to create multiple users in solaris using script

    hi
    how i can create multiple users (2000 users) using shell script with a common password .
    useradd is creating one user at a time.
    thanks

    I m new to solaris and scripting also.
    how i can write a script for this .

  • Error while exporting using OMB+ in unix

    Hi we are trying to export the OWB project using OMB+ ,
    i wrote a shell script which contains this
    /oradir/dkfndr/owb/owb/bin/unix/OMBPlus.sh /finapps/dkfndr/owb/owb_export.tcl
    the tcl script does the export stuff , we got the following error,
    srxgpor11dv01:/finapps/dkfndr/owb(1058)$ /finapps/dkfndr/owb/owb_export.sh
    cat: cannot open setowbenv.sh
    /oradir/dkfndr/owb/owb/bin/unix/OMBPlus.sh: ../admin: does not exist
    any clues ,
    Thanks in advance
    Suresh

    I've had issues with paths in UNIX on several occassions, so I now just ensure that my shell scripts 'cd' to the owb/bin/unix directory first
    cd /oradir/dkfndr/owb/owb/bin/unix/
    ./OMBPlus.sh /finapps/dkfndr/owb/owb_export.tcl
    I have also had cases in UNIX where the install left me with at least on of the JDK directories with improperly set permissions.

  • Calling oracle function in OMB script

    Hi
    Can anyone please tell me how can i get the returned value of an oracle function in OMB script. or how can i get the value into OMB variable and use it.
    Basically i want to set the properties of OWB mapping via OMB script.
    Following OMB code sets the max error limit of a mapping.
    OMBALTER MAPPING 'MAP_DATA' SET PROPERTIES (MAXIMUM_NUMBER_OF_ERRORS) VALUES ('100')
    i dont want to hard code the value 100 rather i want this value to be returned from a function.
    If it is not possible then plz tell me how can i set MAXIMUM_NUMBER_OF_ERRORS property of OWB mapping via sql or pl/sql.
    Any type of clue will be highly appreciated.
    Best Regards

    Here is my bare-bones OMB SQL Library to allow you to do pure SQL calls from within OMB+. All I have ever used it for is to run queries, so I don't have a library procedure for calling a function, however if your function is SQL-callable (e.g. select my_func() from dual) then it would work. Either that or you'll want to augment this library to build a procedure that will call and return the results from a java preparedStatement. It's something I've been meaning to do, but haven't got around to it yet.
    All you should need to do is save this as it's own tcl file and then source it at the top of your own script, or embed it into your script.
    EDIT: Here is a page with some sample code on using java.sql.CallableStatement to call a Pl/SQL procedure from Java which should certainly do the trick for you in conjunction with the basic session control in my library.
    http://www.exampledepot.com/egs/java.sql/CallProcedure.html
    Cheers,
    Mike
    package require java
    #file omb_sql_library.tcl
    proc oracleConnect { serverName databaseName portNumber username password } {
       # import required classes
       java::import java.sql.Connection
       java::import java.sql.DriverManager
       java::import java.sql.ResultSet
       java::import java.sql.SQLWarning
       java::import java.sql.Statement
       java::import java.sql.CallableStatement
       java::import java.sql.ResultSetMetaData
       java::import java.sql.DatabaseMetaData
       java::import java.sql.Types
       java::import oracle.jdbc.OracleDatabaseMetaData
       # load database driver .
       java::call Class forName oracle.jdbc.OracleDriver
       # set the connection url.
       append url jdbc:oracle:thin
       append url :
       append url $username
       append url /
       append url $password
       append url "@"
       append url $serverName
       append url :
       append url $portNumber
       append url :
       append url $databaseName
       set oraConnection [ java::call DriverManager getConnection $url ]
       set oraDatabaseMetaData [ $oraConnection getMetaData ]
       set oraDatabaseVersion [ $oraDatabaseMetaData getDatabaseProductVersion ]
       puts "Connected to: $url"
       puts "$oraDatabaseVersion"
       return $oraConnection
    proc oracleDisconnect { oraConnect } {
      $oraConnect close
    proc oraJDBCType { oraType } {
      #translation of JDBC types as defined in XOPEN interface
      set rv "NUMBER"
      switch $oraType {
         "0" {set rv "NULL"}
         "1" {set rv "CHAR"}
         "2" {set rv "NUMBER"}
         "3" {set rv "DECIMAL"}
         "4" {set rv "INTEGER"}
         "5" {set rv "SMALLINT"}
         "6" {set rv "FLOAT"}
         "7" {set rv "REAL"}
         "8" {set rv "DOUBLE"}
         "12" {set rv "VARCHAR"}
         "16" {set rv "BOOLEAN"}
         "91" {set rv "DATE"}
         "92" {set rv "TIME"}
         "93" {set rv "TIMESTAMP"}
         default {set rv "OBJECT"}
      return $rv
    proc oracleQuery { oraConnect oraQuery } {
       set oraStatement [ $oraConnect createStatement ]
       set oraResults [ $oraStatement executeQuery $oraQuery ]
       # The following metadata dump is not required, but will be a helpfull sort of thing
       # if ever want to really build an abstraction layer
       set oraResultsMetaData [ $oraResults getMetaData ]
       set columnCount        [ $oraResultsMetaData getColumnCount ]
       set i 1
       #puts "ResultSet Metadata:"
       while { $i <= $columnCount} {
          set fname [ $oraResultsMetaData getColumnName $i]
          set ftype [oraJDBCType [ $oraResultsMetaData getColumnType $i]]
          #puts "Output Field $i Name: $fname Type: $ftype"
          incr i
       # end of metadata dump
       return $oraResults
    # SAMPLE CODE to run a quick query and dump the results. #
    #set oraConn [ oracleConnect myserver orcl 1555 scott tiger ]
    #set oraRs [ oracleQuery $oraConn "select name, count(*) numlines from user_source group by name" ]
    #for each row in the result set
    #while {[$oraRs next]} {
      #grab the field values
    #  set procName [$oraRs getString name]
    #  set procCount [$oraRs getInt numlines]
    #  puts "Program unit $procName comprises $procCount lines"
    #$oraRs close
    #oracleDisconnect $oraConnEdited by: zeppo on Nov 25, 2008 7:19 AM

  • OMB Script - Run a process flow (OMBSTART) with input parameters.

    I have a process flow with one input parameter : PF_SCHEMA_NAME. This is a string, literal value = false.
    While running this from the OWB Control center UI, it prompts for value of parameter.
    I need to execute this process flow using OMB script.
    OMBSTART PROCESS_FLOW 'WMREPORT_INCR_DAILY_FCT_SIMP' IN '$OWFLOCATION' OVERRIDE CUSTOM_PARAMETER ('PF_SCHEMA_NAME') VALUES ('ADVIEWPROD')
    This gives following error:
    OMBSTART PROCESS_FLOW 'WMREPORT_INCR_DAILY_FCT_SIMP' IN 'OWF_LOCATION' OVERRIDE CUSTOM_PARAMETER ('PF_SCHEMA_NAME') VALUES ('ADVIEWPROD')
    Starting Execution WMREPORT_INCR_DAILY_FCT_SIMP
    RPE-01003: An infrastructure condition prevented the request from completing.
    RPE-01038: Failed to evaluate expression declare "$LOOP_DETECT$" NUMBER :
    ORA-06550: line 1, column 668:
    PLS-00201: identifier 'ADVIEWPROD' must be declared
    ORA-06550: line 1, column 626:
    PL/SQL: Statement ignored
    Completing Execution WMREPORT_INCR_DAILY_FCT_SIMP

    Thanks David for your reply.
    But your suggestion did not work. I am still getting the same error.
    OMBSTART PROCESS_FLOW 'WMREPORT_INCR_DAILY_FCT_SIMP' IN '$OWFLOCATION' OVERRIDE CUSTOM_PARAMETER ('PF_SCHEMA_NAME') VALUES ('"ADVIEWPROD"')
    Starting Execution WMREPORT_INCR_DAILY_FCT_SIMP
    RPE-01003: An infrastructure condition prevented the request from completing.
    RPE-01038: Failed to evaluate expression declare "$LOOP_DETECT$" NUMBER :
    ORA-06550: line 1, column 651:
    PLS-00201: identifier 'ADVIEWPROD' must be declared
    ORA-06550: line 1, column 608:
    PL/SQL: Statement ignored
    Completing Execution WMREPORT_INCR_DAILY_FCT_SIMP
    Can you please help?

  • How to execute OMB scripts from the command prompt of OS

    Hi
    I want to deploy the mapping from one environment to other environment using OMB script language. But I dont want to run the OMB scripts from OMB plus COmmand prompt?
    All I need is , is there any way/scripts to access OMB command prompt from the general command prompt of the OS Machine?
    or Can I call this OMB command from java program but not JDeveloper?
    It would be a great help for me by sharing your knowledge?
    Cheers
    Pradeep

    This way from MS-DOS:
    set ORACLE_HOME=c:\oracle\OWB10gR2 (change to your Oracle Home)
    call C:\oracle\OWB10gR2\owb\bin\win32\OMBPlus.bat C:\...\my_script.tcl > C:\...\my_log.log
    my_script.tcl contains something like this:
    set OMBLOG "c:\\...\\some_kind_of.log"
    # Disconn just in case you have called a previous script
    OMBDISC
    source C:\\...\\script_with_omb_procedures.tcl
    OMBCC my_project
    OMBCONNECT CONTROL_CENTER "USER/PASSWORD@HOST:PORT:SERVICE" USE REPOSITORY 'MY_REPOSITORY_OWNER'
    OMBDCC
    DEFAULT_CONTROL_CENTER MY_CONTROL_CENTER
    proc_from_script_with_omb_procedures
    exit
    Hope this helps you to begin.
    Instead of using script_with_omb_procedures.tcl you can have your procedures directly inside my_script.tcl, but I like using a script apart to reuse my procedures.

  • Spawn a new PDF using Java Script within LC Designer

    I am trying to spawn a new PDF file to be created from an existing PDF using Java Script within the LC designer
    I have this example but I can't get it to work
    function createPdf()
        pdf = pdf$();
        pdf.addText('Hello World');
        pdf.writeToFile('c:/temp/hello_world.pdf');
        window.open('file://c:/temp/hello_world.pdf');
    Is it possible to create a PDF like this within LC Designer?

    Hi
    I would like to see if it was possible.  I thought it would be easy, as
    there is a standard batch processing sequence (Print 1st page of all) using
    Java that comes with Acrobat 7.  This allows you to print the first page of
    a number of files that you select when the sequence is run.  Its code is:
    /* Print 1st Page */
    /* This sequence prints the first page of
       each document selected to the default printer.
    this.print
    To my uninformed mind it seemed logical that the same code, slightly
    modified to print all pages, should work from within a form.
    Anyway, if there is a way to choose individual files, I would appreciate
    that.
    Thanks
    Rob

Maybe you are looking for