Importing mappings using OMBPLUS

we just started using OWB, and in our environment we do not want to migrate mappings from DEV to TEST to PRODUCTION using GUI. i heard that importing and deploying can be done using OMB scripting ..
can any please give some example scripts for importing mapping and deploying mappings on to a different box.
Thanks

Do you need to move the mapping definitions over to each box? Or just deploy them to different boxes?
If you want a single design repository where you deploy from to multiple runtime areas, then this is acheived through creating multiple configurations and changing your project configuration prior to each deployment.
If, on the other hand, you want to MOVE the current mapping definitions to each box where you will, in effect, be setting up a new design AND runtime repository, then there is added complexity.
For example, scripting dropping old mappings prior to importing the new version of the project to avoid legacy objects hanging around becomes a potential issue. for that, you would need to script deployemnt plans of type DELETE for objects no longer wanted. This also helps script the new deployment as you don't have to code which mappings are being CREATEd, and which are being REPLACEd.
I have an OMB+ script I am just testing right now to load a project MDL file and deploy it to a new repository. I have a partial script for unloading and old version of the project, but it is not ready yet. This one also assumes a clean install where I even have to go so far as to register my runtime user, and define and register all schemas to be used by the control center. We also do not deploy normal database objects via OWB. This script assumes that the proper database setup for tables, sequences, views, etc. has been done prior to deploying the OWB mappings and process flows. We use Designer as the repository of record for all non-OWB database objects.
I don't claim to be an experienced TCL or OMB+ developer, but it might help you out as a starting point. Note that the config file and file of library functions used by this script (such as the exec_omb you will see that I use) are also appended to this post.
File: owb_import.tcl
#get db connection info
source c:\\omb\\owb_config.tcl
#get standard library
source c:\\omb\\omb_library.tcl
#  Connect to repos
# Commit anything from previous work in this session, otherwise OMBDISCONNECT will fail out.
exec_omb OMBCOMMIT
# If already connected, disconnect first.
set print [exec_omb OMBDISCONNECT]
  # Test if message is "OMB01001: Not connected to repository." or "Disconnected."
  # any other message is a showstopper!
if [string match Disconn* $print ]  {
   log_msg LOG "Success Disconnecting from previous repository...."
} else {
   # We expect an OMB01001 error for trying to disconnect when not connected
   if [string match OMB01001* $print ] {
      log_msg LOG "Disconnect unneccessary. Not currently connected...."
   } else {
      log_msg ERROR "Error Disconnecting from previous repository....Exiting process."
      log_msg ERROR "$print"
      #exit
set print [exec_omb OMBCONNECT $OWB_DEG_USER/$OWB_DEG_PASS@$OWB_DEG_HOST:$OWB_DEG_PORT:$OWB_DEG_SRVC USE REPOSITORY '$OWB_DEG_REPOS']
if [omb_error $print] {
    log_msg ERROR "Unable to connect to repository."
    log_msg ERROR "$print" "1"
    log_msg ERROR "Exiting Script.............."
    return
} else {
    log_msg LOG "Connected to Repository"   
# Connect to project
set print [exec_omb OMBCC '$PROJECT_NAME']
if [omb_error $print] {
   log_msg LOG "Project $PROJECT_NAME does not exist. Creating...."
   set print [exec_omb OMBCREATE PROJECT '$PROJECT_NAME']
   if [omb_error $print] {
      log_msg ERROR "Unable to create project '$PROJECT_NAME'"
      log_msg ERROR "$print"
      log_msg ERROR "Exiting Script.............."
      exec_omb OMBROLLBACK
      return
   } else {
      log_msg LOG "Created Project '$PROJECT_NAME'"
      exec_omb OMBCOMMIT
      exec_omb OMBSAVE
      exec_omb OMBCC '$PROJECT_NAME'
} else {
   log_msg LOG "Switched context to project $PROJECT_NAME"
# Check Existance of Oracle Module
set print [exec_omb OMBCC '$ORA_MODULE_NAME']
if [omb_error $print] {
   log_msg LOG "Oracle Module $ORA_MODULE_NAME does not exist. Creating...."
   set print [exec_omb OMBCREATE ORACLE_MODULE '$ORA_MODULE_NAME']
   if [omb_error $print] {
      log_msg ERROR "Unable to create module '$ORA_MODULE_NAME'"
      log_msg ERROR "$print"
      log_msg ERROR "Exiting Script.............."
      exec_omb OMBROLLBACK
      return
   } else {
      log_msg LOG "Created Oracle Module '$ORA_MODULE_NAME'"
      exec_omb OMBCOMMIT
      exec_omb OMBSAVE
      exec_omb OMBCC '$ORA_MODULE_NAME'
} else {
   log_msg LOG "Switched context to module $ORA_MODULE_NAME"
#switch back up to project level. You cannot attach locations to a module if you are in it.
exec_omb OMBCC '..'
log_msg LOG "Switched context back up to project $PROJECT_NAME"
# Check Existance of OWB Registered USer
set lst [OMBLIST USERS]
if {[string match *$DATA_LOCATION_USER* $lst]} {
   log_msg LOG "Verify USer $DATA_LOCATION_USER Exists."
} else {
   log_msg LOG "registering User $DATA_LOCATION_USER."
#   set print [ exec_omb OMBREGISTER USER '$DATA_LOCATION_USER' SET PROPERTIES (DESCRIPTION, ISTARGETSCHEMA, TARGETSCHEMAPWD) VALUES ('$DATA_LOCATION_USER', 'true', '$DATA_LOCATION_PASS')]
   if [omb_error $print] {
      log_msg ERROR "Unable to register user '$DATA_LOCATION_USER'"
      log_msg ERROR "$print"
      log_msg ERROR "Exiting Script.............."
      exec_omb OMBROLLBACK
      return
   exec_omb OMBCOMMIT
# Import MDL File
#switch back up to root level to ensure import succeeds.
exec_omb OMBSAVE
exec_omb OMBCC '..'
log_msg LOG "Switched context back up to root level."
set print [exec_omb OMBIMPORT MDL_FILE '$IMPORT_FILE_PATH/$IMPORT_FILE_NAME' USE UPDATE_MODE MATCH_BY NAMES OUTPUT LOG TO '$IMPORT_LOG_PATH/$IMPORT_LOG_NAME' ]
if [omb_error $print] {
   #We expect to get warnings due to differences in Control center names etc,
   if {[string match OMB05105* $print]} {
      log_msg LOG "MDL File $IMPORT_FILE_NAME imported with warnings"
   } else {
       log_msg ERROR "Unable to import $IMPORT_FILE_PATH/$IMPORT_FILE_NAME. "
       log_msg ERROR "$print"
       log_msg ERROR "Exiting Script.............."
       exec_omb OMBROLLBACK
       return
} else {
   log_msg LOG "MDL File $IMPORT_FILE_NAME imported with no warnings.............."
exec_omb OMBCOMMIT
exec_omb OMBCC '$PROJECT_NAME'
log_msg LOG "Switched context back to project level."
# Validate to Control Center
set lst [OMBLIST CONTROL_CENTERS]
if [string match *$CONTROL_CENTER_NAME* $lst] {
   log_msg LOG "Verify Control Center $CONTROL_CENTER_NAME Exists."
   log_msg LOG "Setting Passwords to enable import and deploy"
   set print [exec_omb OMBALTER LOCATION '$DATA_LOCATION_NAME' SET PROPERTIES (PASSWORD) VALUES ('$DATA_LOCATION_PASS')]
   if [omb_error $print] {
      log_msg ERROR "Unable to log onto location '$DATA_LOCATION_NAME' with password $DATA_LOCATION_PASS"
      log_msg ERROR "$print"
      log_msg ERROR "Exiting Script.............."
      exec_omb OMBROLLBACK
      return
   exec_omb OMBCOMMIT
   set print [exec_omb OMBALTER LOCATION '$WFLOW_LOCATION_NAME' SET PROPERTIES (PASSWORD) VALUES ('$WFLOW_LOCATION_PASS')]
   if [omb_error $print] {
      log_msg ERROR "Unable to log onto workflow location '$WFLOW_LOCATION_NAME' with password $WFLOW_LOCATION_PASS"
      log_msg ERROR "$print"
      log_msg ERROR "Exiting Script.............."
      exec_omb OMBROLLBACK
      return
   exec_omb OMBCOMMIT
   log_msg LOG "Connecting to Control Center $CONTROL_CENTER_NAME"
   set print [exec_omb OMBCONNECT CONTROL_CENTER USE '$DATA_LOCATION_PASS' ]
   if [omb_error $print] {
      log_msg ERROR "Unable to add Location $DATA_LOCATION_NAME to Control Center $CONTROL_CENTER_NAME"
      log_msg ERROR "$print"
      log_msg ERROR "Exiting Script.............."
      exec_omb OMBROLLBACK
      return
   exec_omb OMBCOMMIT
   log_msg LOG "Connected.............."
} else {
   log_msg LOG "Need to create Control Center $CONTROL_CENTER_NAME."
   log_msg LOG "Creating Code Location."
   # For Global_names = FALSE
   # set print [exec_omb OMBCREATE LOCATION '$DATA_LOCATION_NAME' SET PROPERTIES (TYPE, VERSION, DESCRIPTION, BUSINESS_NAME, HOST, PORT, SERVICE, CONNECT_AS_USER, PASSWORD, DATABASE_NAME) VALUES ('ORACLE_DATABASE','$DATA_LOCATION_VERS','ERS Datamart Code User','$DATA_LOCATION_NAME', '$DATA_LOCATION_HOST','$DATA_LOCATION_PORT','$DATA_LOCATION_SRVC', '$DATA_LOCATION_USER','$DATA_LOCATION_PASS','$DATA_LOCATION_SRVC' ) ] 
   set print [exec_omb OMBCREATE LOCATION '$DATA_LOCATION_NAME' SET PROPERTIES (TYPE, VERSION, DESCRIPTION, BUSINESS_NAME, HOST, PORT, SERVICE, CONNECT_AS_USER, PASSWORD) VALUES ('ORACLE_DATABASE','$DATA_LOCATION_VERS','ERS Datamart Code User','$DATA_LOCATION_NAME', '$DATA_LOCATION_HOST','$DATA_LOCATION_PORT','$DATA_LOCATION_SRVC', '$DATA_LOCATION_USER','$DATA_LOCATION_PASS') ] 
   if [omb_error $print] {
      log_msg ERROR "Unable to create location '$DATA_LOCATION_NAME'"
      log_msg ERROR "$print"
      log_msg ERROR "Exiting Script.............."
      exec_omb OMBROLLBACK
      return
   exec_omb OMBCOMMIT
   log_msg LOG "Creating Workflow Location."
   set print [exec_omb OMBCREATE LOCATION '$WFLOW_LOCATION_NAME' SET PROPERTIES (TYPE, VERSION, DESCRIPTION, BUSINESS_NAME, HOST, PORT, SERVICE_NAME, PASSWORD, SCHEMA) VALUES ('ORACLE_WORKFLOW','$WFLOW_LOCATION_VERS','ERS Datamart Workflow User','$WFLOW_LOCATION_NAME', '$WFLOW_LOCATION_HOST','$WFLOW_LOCATION_PORT','$WFLOW_LOCATION_SRVC', '$WFLOW_LOCATION_PASS','$WFLOW_LOCATION_USER') ] 
   if [omb_error $print] {
      log_msg ERROR "Unable to create Workflow location '$WFLOW_LOCATION_NAME'"
      log_msg ERROR "$print"
      log_msg ERROR "Exiting Script.............."
      exec_omb OMBROLLBACK
      #return
   exec_omb OMBCOMMIT
   log_msg LOG "Creating Control Center"
   set print [exec_omb OMBCREATE CONTROL_CENTER '$CONTROL_CENTER_NAME' SET PROPERTIES (DESCRIPTION, BUSINESS_NAME, HOST, PORT, SERVICE_NAME, USER, SCHEMA, PASSWORD) VALUES ('ERS Datamart Control Center','$CONTROL_CENTER_NAME', '$DATA_LOCATION_HOST','$DATA_LOCATION_PORT','$DATA_LOCATION_SRVC', '$DATA_LOCATION_USER', '$CONTROL_CENTER_SCHEMA','$DATA_LOCATION_PASS') ]
   if [omb_error $print] {
      log_msg ERROR "Unable to create control center '$CONTROL_CENTER_NAME'"
      log_msg ERROR "$print"
      log_msg ERROR "Exiting Script.............."
      exec_omb OMBROLLBACK
      return
   exec_omb OMBCOMMIT
   log_msg LOG "Adding Location $DATA_LOCATION_NAME to Control Center $CONTROL_CENTER_NAME"
   set print [exec_omb OMBALTER CONTROL_CENTER '$CONTROL_CENTER_NAME' ADD REF LOCATION '$DATA_LOCATION_NAME' SET PROPERTIES (IS_TARGET, IS_SOURCE) VALUES ('true', 'true') ]
   if [omb_error $print] {
      log_msg ERROR "Unable to add Location $DATA_LOCATION_NAME to Control Center $CONTROL_CENTER_NAME"
      log_msg ERROR "$print"
      log_msg ERROR "Exiting Script.............."
      exec_omb OMBROLLBACK
      return
   exec_omb OMBCOMMIT
   log_msg LOG "Adding Workflow Location $WFLOW_LOCATION_NAME to Control Center $CONTROL_CENTER_NAME"
   set print [exec_omb OMBALTER CONTROL_CENTER '$CONTROL_CENTER_NAME' ADD REF LOCATION '$WFLOW_LOCATION_NAME' SET PROPERTIES (IS_TARGET, IS_SOURCE) VALUES ('true', 'true') ]
   if [omb_error $print] {
      log_msg ERROR "Unable to add Location $DATA_LOCATION_NAME to Control Center $CONTROL_CENTER_NAME"
      log_msg ERROR "$print"
      log_msg ERROR "Exiting Script.............."
      exec_omb OMBROLLBACK
      #return
   exec_omb OMBCOMMIT
   log_msg LOG "Setting Control Center as default control center for project"
   exec_omb OMBCC 'DEFAULT_CONFIGURATION'
   set print [exec_omb OMBALTER DEPLOYMENT 'DEFAULT_DEPLOYMENT' SET REF CONTROL_CENTER '$CONTROL_CENTER_NAME' ]
   if [omb_error $print] {
      log_msg ERROR "Unable to set Control Center $CONTROL_CENTER_NAME in default configuration"
      log_msg ERROR "$print"
      log_msg ERROR "Exiting Script.............."
      exec_omb OMBROLLBACK
      return
   exec_omb OMBCOMMIT
   exec_omb OMBCC '..'
   log_msg LOG "Connecting to Control Center $CONTROL_CENTER_NAME"
   set print [exec_omb OMBCONNECT CONTROL_CENTER USE '$DATA_LOCATION_PASS' ]
   if [omb_error $print] {
      log_msg ERROR "Unable to add Location $DATA_LOCATION_NAME to Control Center $CONTROL_CENTER_NAME"
      log_msg ERROR "$print"
      log_msg ERROR "Exiting Script.............."
      exec_omb OMBROLLBACK
      return
   exec_omb OMBCOMMIT
   log_msg LOG "Registering Code Location."
   set print [exec_omb OMBALTER LOCATION '$DATA_LOCATION_NAME' SET PROPERTIES (PASSWORD) VALUES ('$DATA_LOCATION_PASS')]
   exec_omb OMBCOMMIT
   set print [exec_omb OMBREGISTER LOCATION '$DATA_LOCATION_NAME']
   if [omb_error $print] {
      log_msg ERROR "Unable to register Location $DATA_LOCATION_NAME"
      log_msg ERROR "$print"
      log_msg ERROR "Exiting Script.............."
      exec_omb OMBROLLBACK
      return
   exec_omb OMBCOMMIT
   log_msg LOG "Registering Workflow Location."
   set print [exec_omb OMBALTER LOCATION '$WFLOW_LOCATION_NAME' SET PROPERTIES (PASSWORD) VALUES ('$WFLOW_LOCATION_PASS')]
   exec_omb OMBCOMMIT
   set print [exec_omb OMBREGISTER LOCATION '$WFLOW_LOCATION_NAME']
   if [omb_error $print] {
      log_msg ERROR "Unable to register Workflow Location $WFLOW_LOCATION_NAME"
      log_msg ERROR "$print"
      log_msg ERROR "Exiting Script.............."
      exec_omb OMBROLLBACK
      return
   exec_omb OMBCOMMIT
# Assign location to Oracle Module
log_msg LOG "Assigning Code Location to Oracle Module."
set print [ exec_omb OMBALTER ORACLE_MODULE '$ORA_MODULE_NAME' ADD REFERENCE LOCATION '$DATA_LOCATION_NAME' SET AS DEFAULT ]
if [omb_error $print] {
   log_msg ERROR "Unable to add reference location '$DATA_LOCATION_NAME' to module '$ORA_MODULE_NAME' "
   log_msg ERROR "$print"
   log_msg ERROR "Exiting Script.............."
   exec_omb OMBROLLBACK
   return
set print [ exec_omb OMBALTER ORACLE_MODULE '$ORA_MODULE_NAME' SET REFERENCE METADATA_LOCATION '$DATA_LOCATION_NAME' ]
if [omb_error $print] {
   log_msg ERROR "Unable to set metadata location '$DATA_LOCATION_NAME' on module '$ORA_MODULE_NAME' "
   log_msg ERROR "$print"
   log_msg ERROR "Exiting Script.............."
   exec_omb OMBROLLBACK
   return
set print [ exec_omb OMBALTER ORACLE_MODULE '$ORA_MODULE_NAME' SET PROPERTIES (DB_LOCATION) VALUES ('$DATA_LOCATION_NAME') ]
if [omb_error $print] {
   log_msg ERROR "Unable to add db_location '$DATA_LOCATION_NAME' to module '$ORA_MODULE_NAME' "
   log_msg ERROR "$print"
   log_msg ERROR "Exiting Script.............."
   exec_omb OMBROLLBACK
   return
exec_omb OMBCOMMIT
# Assign location to Workflow Module
log_msg LOG "Assigning Location to Workflow Module."
set print [ exec_omb OMBALTER ORACLE_MODULE '$ORA_MODULE_NAME' ADD REFERENCE LOCATION '$DATA_LOCATION_NAME' SET AS DEFAULT ]
if [omb_error $print] {
   log_msg ERROR "Unable to add reference location '$DATA_LOCATION_NAME' to module '$ORA_MODULE_NAME' "
   log_msg ERROR "$print"
   log_msg ERROR "Exiting Script.............."
   exec_omb OMBROLLBACK
   return
# Begin Object Deployment
log_msg LOG "*********** Deploying: Mappings ****************"
exec_omb OMBCC '$ORA_MODULE_NAME'
set mapList [ OMBLIST MAPPINGS ]
foreach mapName $mapList {
     log_msg LOG "Deploying: $mapName"
     set print [ exec_omb OMBCREATE TRANSIENT DEPLOYMENT_ACTION_PLAN 'DEPLOY_PLAN' ADD ACTION 'MAPPING_DEPLOY' SET PROPERTIES (OPERATION) VALUES ('CREATE') SET REFERENCE MAPPING '$mapName' ]
     if [omb_error $print] {
        log_msg ERROR "Unable to create Deployment plan for '$mapName'"
        log_msg ERROR "$print"
       return
     set print [ exec_omb OMBDEPLOY DEPLOYMENT_ACTION_PLAN 'DEPLOY_PLAN' ]
     if [omb_error $print] {
        log_msg ERROR "Error on execute of Deployment plan for '$mapName'"
        log_msg ERROR "$print"
        exec_omb OMBDROP DEPLOYMENT_ACTION_PLAN 'DEPLOY_PLAN'
        exec_omb OMBCOMMIT
       return
     exec_omb OMBDROP DEPLOYMENT_ACTION_PLAN 'DEPLOY_PLAN'
     exec_omb OMBCOMMIT
log_msg LOG "*********** Deploying: Process Flows **************"
exec_omb OMBCC '..'
exec_omb OMBCC '..'
set all_Owfs [OMBLIST PROCESS_FLOW_PACKAGES]
if {$all_Owfs!="" } {
     foreach one_Owf $all_Owfs {
          set print [ exec_omb OMBCREATE TRANSIENT DEPLOYMENT_ACTION_PLAN 'DEPLOY_PLAN' ]
          if [omb_error $print] {
            log_msg ERROR "Unable to create Deployment plan for '$one_Owf'"
            log_msg ERROR "$print"
            return
          set print [ exec_omb OMBALTER DEPLOYMENT_ACTION_PLAN 'DEPLOY_PLAN' ADD ACTION 'OWFDEP$one_Owf' SET PROPERTIES (OPERATION) VALUES ('CREATE') SET REFERENCE PROCESS_FLOW_PACKAGE '$one_Owf' ]
          if [omb_error $print] {
            log_msg ERROR "Unable to alter Deployment plan for '$one_Owf'"
            log_msg ERROR "$print"
            exec_omb OMBDROP DEPLOYMENT_ACTION_PLAN 'DEPLOY_PLAN'
            return
          log_msg LOG "OWF LOCATION: $Process_Flow_Module - OWF: $one_Owf Deployment...";
          set print [ exec_omb OMBDEPLOY DEPLOYMENT_ACTION_PLAN 'DEPLOY_PLAN' ]
          if [omb_error $print] {
            log_msg ERROR "Unable to execute Deployment plan for '$one_Owf'"
            log_msg ERROR "$print"
            exec_omb OMBDROP DEPLOYMENT_ACTION_PLAN 'DEPLOY_PLAN'
            return
          set print [ exec_omb OMBDROP DEPLOYMENT_ACTION_PLAN 'DEPLOY_PLAN' ]
          log_msg LOG "OWF LOCATION: $Process_Flow_Module - OWF: $one_Owf Deployed";
     log_msg LOG "OWF LOCATION: $Process_Flow_Module - All Workflows Deployed...";
#OMBDISCONNECTWhich depends on the following two files:
OMB_LIBRARY.TCL
# Default logging function.
#  Accepts inputs: LOGMSG - a text string to output
#                  FORCELOG - if "1" then output regardless of VERBOSE_LOG setting
proc log_msg {LOGTYPE LOGMSG {FORCELOG "0"}} {
   global VERBOSE_LOG
   if { $VERBOSE_LOG == "1"} {
     puts "$LOGTYPE:-> $LOGMSG"
   } else {
       if { $FORCELOG == "1"} {
          puts "$LOGTYPE:-> $LOGMSG"
proc exec_omb { args } {
   log_msg OMBCMD "$args"
   # the point of this is simply to return errorMsg or return string, whichever is applicable,
   # to simplify error checking using omb_error{}
   if [catch { set retstr [eval $args] } errmsg] {
      return $errmsg
   } else {
      return $retstr
proc omb_error { retstr } {
   # OMB and Oracle errors may have caused a failure.
   if [string match OMB0* $retstr] {
      return 1
   } elseif [string match ORA-* $retstr] {
      return 1
   } else {
      return 0
}and a config file where all config/passowrd info is put.
# GLOBAL VARIABLE DECLARATION SECTION
#DESIGN REPOSITORY  CONNECTION INFORMATION
# Login info for the main design repository owner
set OWB_DEG_USER    owb_user
set OWB_DEG_PASS    password
set OWB_DEG_HOST    host01
set OWB_DEG_PORT    5555
set OWB_DEG_SRVC    orcl_srvc
set OWB_DEG_REPOS   owb_user
# CONTROL CENTER AND LOCATION DECLARATION SECTION
set CONTROL_CENTER_NAME          ERS_DM_CTLCNTR
set CONTROL_CENTER_SCHEMA      owb_user
#Connection info to ers_etl_app schema for deployment
set DATA_LOCATION_NAME         ERS_DM_DATA
set DATA_LOCATION_VERS         9.2
set DATA_LOCATION_USER         ERS_ETL_APP
set DATA_LOCATION_PASS         ers_etl_app
set DATA_LOCATION_HOST         newserver
set DATA_LOCATION_PORT         1555
set DATA_LOCATION_SRVC         orcl_new
#Connection info to workflow schema for deployment
set WFLOW_LOCATION_NAME        ERS_DM_WFLOW
set WFLOW_LOCATION_VERS        2.6.2
set WFLOW_LOCATION_USER        OWF_MGR
set WFLOW_LOCATION_PASS        owf_mgr
set WFLOW_LOCATION_HOST        newserver
set WFLOW_LOCATION_PORT        1555
set WFLOW_LOCATION_SRVC        orcl_new
# PROJECT,MUDULE AND DIRECTORY DECLARATION SECTION
set PROJECT_NAME      ERS_DM
set ORA_MODULE_NAME    ERS_ETL_APP
set PFLOW_MODULE_NAME  LD_DMRT
set PFLOW_PACKAGE_NAME LD_DMRT
# Directory DECLARATION SECTION
set IMPORT_FILE_NAME "ers_dply_tst_rc01.mdl"
set IMPORT_FILE_PATH "C:/OMB/import/db_imports"
set IMPORT_LOG_NAME  "ers_dply_tst_rc01_imp.log"
set IMPORT_LOG_PATH  "C:/OMB/import/logs"
# Logging Option
global VERBOSE_LOG
set VERBOSE_LOG "1"Hope that this helps you out!
Message was edited by: zeppo
Edited to: Try and correct formatting tags.

Similar Messages

  • Avoiding creation of DBlink during deployment of mappings using OMBPlus

    Hi
    we are facing an issue in our OWB 11g R2 (upgraded to patchset 10185523)
    We are deploying the mappings using OMBPlus like so
    OMBCREATE TRANSIENT DEPLOYMENT_ACTION_PLAN 'DEPLOY_PLAN' ADD ACTION '$object_type_DEPLOY' SET PROPERTIES (OPERATION)VALUES ('CREATE') SET REFERENCE $object_type '$objname'
    OMBDEPLOY DEPLOYMENT_ACTION_PLAN 'DEPLOY_PLAN'
    set OMBCONTINUE_ON_ERROR true
    OMBDROP DEPLOYMENT_ACTION_PLAN 'DEPLOY_PLAN'
    OMBCOMMIT
    The $objname is any object(in this case a mapping) that we are deploying
    OMBPlus generates a script on OWB level to create the associated DBlink each time it deploys a mapping and we get an error
    INFORMATIONAL
    multiple rows found for select into statement
    DBlink_a Create Error ORA-02011: duplicate database link name
    But the mapping deploys fine.
    Any tips how we can avoid creation of dblinks from OMBPlus whilst deploying our mappings only?
    Any help will be appreciated
    Birdy
    Edited by: birdy on 22-Nov-2011 05:22

    I dont think that you can:
    "Deploying a mapping or a process flow includes these steps:
    •Generate the PL/SQL, SQL*Loader, or ABAP script, if necessary.
    •Register the required locations and deploy any required connectors. This ensures that the details of the physical locations and their connectors are available at runtime."
    http://www.comp.dit.ie/btierney/Oracle11gDoc/owb.111/b31278/concept_deploy.htm
    But error that you get is only informational so you dont have to worry about it.

  • Problem deploying certain mappings using OMBPlus

    We've got a problem deploying certain mapings using OMBPLus. This applies to all mappings that use a function to lookup the effective date of a SCD (type 2) from a lookup table. We use that function in the dimension operator properties as the "Default Effective Time of Open Record". Though the validation of those mappings fails they can nevertheless be deployed using the Control Center Manager. And, best of all, they work fine.
    Now we have to deploy those mappings using OMBPlus because we're not allowed to work with tools on the preproduction and production systems. Deploying those mappings with OMBPlus doesn't seem to work. It works fine for all other mappings but not for those mentioned above. Has anybody a solution?
    Regards,
    Jörg

    Hi Dave,
    this is the error message I get whe I run my OMBPLus script:
    OMB05602: An unknown Deployment error has occured for Object Type PUB03205 : Validation Error: MAP_DIM_FAHRZEUGKLASSE : VLD-5010: The Default Effective Date of open records for dimension DIM_FAHRZEUGKLASSE should be an expression of type DATE. Value "FCT_GET_AKT_LL_vmon()" is not a valid date: PLS-00201: identifier 'FCT_GET_AKT_LL_VMON' must be declared
    I'm not quite sure about what you mean with creating a stub function. As you can see from the error message above I use a function called FCT_GET_AKT_LL_vmon that returns the actual date od the load from a lookup table. This function is of course present in the target schema.
    Regards,
    Jörg

  • Export/import of mappings using OMBPLUS and Collections?

    Hi,
    We've got some good TCL code to export (and import) mappings for our projects along the lines of:
    OMBEXPORT MDL_FILE '$projname.mdl' \
    PROJECT '$projname' \
    CONTROL_FILE '$controlfile.txt' \
    OUTPUT LOG '$projname.log'
    and now we're moving to organizing mappings by OWB COLLECTION and need to export/import by collection instead. Thought it might be as simple as this:
    OMBEXPORT MDL_FILE '$collname.mdl' \
    FROM COMPONENTS ( COLLECTION '$collname')
    CONTROL_FILE '$controlfile.txt' \
    but that's not working (saying "Project $collname does not exist.", so it seems to still be treating what I thought was a collection name as a project name . Can someone point out the right syntax to use COLLECTIONs in OMBEXPORT/OMBIMPORT?
    All thoughts/tips appreciated...
    Thanks,
    Jim C.

    Hi,
    If we use the below tcl script for the entire project export , does it also export the locaitons,control center,configurations along???
    If yes then can you gimme the script for altering the locations , control center/configuration connection details??
    OMBEXPORT MDL_FILE '$projname.mdl' \
    PROJECT '$projname' \
    CONTROL_FILE '$controlfile.txt' \
    OUTPUT LOG '$projname.log'
    Can you also provide me the tcl for project import??
    Thanks

  • Register and unregister locations using ombplus script

    hi
    how to register and unregister the locations using ombplus scripts.
    any help would be appreciated.
    thanks,
    Keka

    The deployment script I have posted previously to copy a project mdl over to a new repository for local deployment includes creating a control center, making it the default for your project, creating the locations, assigning them to the control center, and registering them.
    Re: importing mappings using OMBPLUS
    To unregister a location, first you want to undeploy anything deployed from it to avoid dangling references int he repository, and then unregister the location.
    I do that in the following drop_project script that we use to delete an old copy of the project before importing the new version.
    #get db connection info
    source c:\\omb\\owb_config.tcl
    #get standard library
    source c:\\omb\\omb_library.tcl
    # PVCS Version Information
    #/* $Workfile:   ers_owb_drop_project.tcl  $ $Revision:   2.1  $ */
    #/* $Author:   michael.broughton  $
    #/* $Date:   03 Apr 2008 13:43:02  $ */
    #  Connect to repos
    # Commit anything from previous work, otherwise OMBDISCONNECT will fail out.
    exec_omb OMBCOMMIT
    # If already connected, disconnect first.
    set print [exec_omb OMBDISCONNECT]
      # Test if message is "OMB01001: Not connected to repository." or "Disconnected."
      # any other message is a showstopper!
    if [string match Disconn* $print ]  {
       log_msg LOG "Success Disconnecting from previous repository...."
    } else {
       # We expect an OMB01001 error for trying to disconnect when not connected
       if [string match OMB01001* $print ] {
          log_msg LOG "Disconnect unneccessary. Not currently connected...."
       } else {
          log_msg ERROR "Error Disconnecting from previous repository....Exiting process."
          log_msg ERROR "$print"
          #exit
    set print [exec_omb OMBCONNECT $OWB_DEG_USER/$OWB_DEG_PASS@$OWB_DEG_HOST:$OWB_DEG_PORT:$OWB_DEG_SRVC USE REPOSITORY '$OWB_DEG_REPOS']
    if [omb_error $print] {
        log_msg ERROR "Unable to connect to repository."
        log_msg ERROR "$print" "1"
        log_msg ERROR "Exiting Script.............."
        return
    } else {
        log_msg LOG "Connected to Repository"   
    return
    # Connect to project
    set print [exec_omb OMBCC '$PROJECT_TO_DROP_NAME']
    if [omb_error $print] {
       log_msg LOG "Project $PROJECT_TO_DROP_NAME does not exist. No Cleanup Required...."
       exec_omb OMBDISCONNECT CONTROL_CENTER
       exec_omb OMBDISCONNECT
       return
    } else {
       log_msg LOG "Verified project $PROJECT_TO_DROP_NAME exists"
       exec_omb OMBCC '..'
    # Exporting MDL Backup of Project
    set print [exec_omb OMBEXPORT TO MDL_FILE '$EXPORT_FILE_PATH/$EXPORT_FILE_NAME' FROM PROJECT NAMES '$PROJECT_TO_DROP_NAME' OUTPUT LOG TO '$EXPORT_LOG_PATH/$EXPORT_LOG_NAME' ]
    if [omb_error $print] {
       #We expect to get warnings due to differences in Control center names etc,
       if {[string match OMB05105* $print]} {
          log_msg LOG "MDL File $EXPORT_FILE_NAME exported with warnings"
       } else {
           log_msg ERROR "Unable to import $EXPORT_FILE_PATH/$EXPORT_FILE_NAME. "
           log_msg ERROR "$print"
           log_msg ERROR "Exiting Script.............."
           exec_omb OMBROLLBACK
           return
    } else {
       log_msg LOG "MDL File $EXPORT_FILE_NAME exported with no warnings.............."
    exec_omb OMBCOMMIT
    # Validate to Control Center
    set lst [OMBLIST CONTROL_CENTERS]
    if [string match *$CONTROL_CENTER_NAME* lst] {
       log_msg LOG "Verify Control Center $CONTROL_CENTER_NAME Exists."
       log_msg LOG "Setting Passwords to enable de-registration"
       log_msg LOG "Connecting to Control Center $CONTROL_CENTER_NAME"
       set print [exec_omb OMBCONNECT CONTROL_CENTER USE '$DATA_LOCATION_PASS' ]
       if [omb_error $print] {
          log_msg ERROR "Unable to connect to Control Center $CONTROL_CENTER_NAME"
          log_msg ERROR "$print"
          log_msg ERROR "Exiting Script.............."
          exec_omb OMBROLLBACK
          return
       exec_omb OMBCOMMIT
       log_msg LOG "Deleting Existing Mappings."
       set print [exec_omb OMBALTER LOCATION '$DATA_LOCATION_NAME' SET PROPERTIES (PASSWORD) VALUES ('$DATA_LOCATION_PASS')]
       exec_omb OMBCOMMIT
       exec_omb OMBCC '$ORA_MODULE_NAME'
       set mapList [ OMBLIST MAPPINGS ]
       foreach mapName $mapList {
          log_msg LOG "Un-Deploying: $mapName"
          set print [ exec_omb OMBCREATE TRANSIENT DEPLOYMENT_ACTION_PLAN 'DEPLOY_PLAN' ADD ACTION 'MAPPING_DEPLOY' SET PROPERTIES (OPERATION) VALUES ('DROP') SET REFERENCE MAPPING '$mapName' ]
          if [omb_error $print] {
             exit_failure "Unable to create Deployment plan for '$mapName'"
          set print [ exec_omb OMBDEPLOY DEPLOYMENT_ACTION_PLAN 'DEPLOY_PLAN' ]
          if [omb_error $print] {
             exit_failure "Error on execute of Deployment plan for '$mapName'"
          exec_omb OMBDROP DEPLOYMENT_ACTION_PLAN 'DEPLOY_PLAN'
          exec_omb OMBCOMMIT
      exec_omb OMBCC '..'
      exec_omb OMBCC '..'
       log_msg LOG "Un-Registering Code Location."
       set print [exec_omb OMBUNREGISTER LOCATION '$DATA_LOCATION_NAME']
       if [omb_error $print] {
          log_msg ERROR "Unable to register Location $DATA_LOCATION_NAME"
          log_msg ERROR "$print"
          log_msg ERROR "Exiting Script.............."
          exec_omb OMBROLLBACK
          return
       exec_omb OMBCOMMIT
    } else {
       log_msg LOG "Control Center $CONTROL_CENTER_NAME does not exist - unable to de-register locations."
    # Dropping project
    exec_omb OMBDISCONNECT CONTROL_CENTER
    log_msg LOG "Renaming project $PROJECT_TO_DROP_NAME to $PROJECT_TO_DROP_NEWNAME ...."
    set print [exec_omb OMBALTER PROJECT '$PROJECT_TO_DROP_NAME' RENAME TO '$PROJECT_TO_DROP_NEWNAME']
    if [omb_error $print] {
       log_msg LOG "Failed to drop project $PROJECT_TO_DROP_NAME...."
       log_msg ERROR "$print"
       log_msg ERROR "Exiting Script.............."
    exec_omb OMBDISCONNECTThis script uses the same config and library file given in the other post that I pointed you towards. That is where you will find the definition for exec_omb, for example which is simply a wrapper for OMB+ calls
    Now, note that I don't un-deploy any tables, views, sequences etc. We use Designer as our location of record for the data model metadata so our OWB project never deploys any object metadata except for mappings. Your setup may be different, still this should point you in the right direction.
    Cheers,
    Mike

  • Re-generate toplink mappings used by db adapter

    When changes are performed in the underlying relationel model, and these need to be reflected in the xsd-mapping file and toplink-mappings used in my bpel process. How can i propagate, reverse-engineer the changes from my database into the toplink mapping files?
    For example new releases are being scheduled for our project and in these new release, changes are made to the db-model, which are non-intrusive because only attributes are added, existing attributes aren't deleted/removed.
    How can I propagate the relational db changes inside my bpel process using db adapters?
    Kind regards,
    Nathalie

    You're able to update the defined toplink mapping files by re-importing the tables in your database adapter, used in the bpel process.
    But this will only update the associated mapping file, but won't update the xsd which was created the first time you've defined the database adapter.
    Has anyone found a solution for this?
    Kind regards,
    Nathalie

  • I have just used migration assistant to import photos (using an ethernet cable) from my PC. It has worked but they have gone into a new user on my MacPro. How can I merge them into the one user account.

    I have just used migration assistant to import photos (using an ethernet cable) from my PC. It has worked but they have gone into a new user on my MacPro. How can I merge them into the one user account.

    How many pictures (or how many bytes) are we talking?  Now that the pictures are imported one way to cross users is to use a removable drive (although large volumes of files preclude this).
    The other is to login as the user where the pictures are, then copy them into the public drop box of the user where you want the picture.
    The arrow is showing (in ths example) copy files from the Pictures folder for my user to the guest user accounts public dropbox.  When you do this you may have to authenticate and you won't be able to see the results of the copy until you log in as the other user.
    All users are in the folder "/Users/"

  • Getting error while importing metadata using View Objects

    Hi All,
    I am trying to create a repository using View Object in OBIEE 11.1.5.1 but getting error while viewing the data, after importing the metadata in the repository "[nQSError: 77031] Error occurs while calling remote service ADFService11G. Details: Runtime error for service -- ADFService11G - oracle/apps/fnd/applcore/common/ApplSession".
    I am also getting error "žADFException-2015: The BI Server is incompatible with the BI-ADF Broker Servlet: BI Server protocol version = null, BI-ADF Broker Servlet protocol version = 1" during testing my sample which is deployed to Admin server. I followed BI Adminstrator help file guide in order to create the sample for creating repository using view object.
    Admin server log says
    [2011-09-27T02:59:03.646-05:00] [AdminServer] [NOTIFICATION] [] [oracle.bi.integration.adf] [tid: [ACTIVE].ExecuteThread: '2' for queue: 'weblogic.kernel.Default (self-tuning)'] [userId: <anonymous>] [ecid: b260b57746aa92d3:-1f9ca26:1328fcfd3e6:-8000-0000000000006744,0] [APP: BIEEOrders] [[
    QUERY:
    <?xml version="1.0" encoding="UTF-8" ?><ADFQuery><Parameters></Parameters><Projection><Attribute><Name><![CDATA[Deptno]]></Name><ViewObject><![CDATA[AppModule.DeptViewObj1]]></ViewObject></Attribute><Attribute><Name><![CDATA[Dname]]></Name><ViewObject><![CDATA[AppModule.DeptViewObj1]]></ViewObject></Attribute><Attribute><Name><![CDATA[Loc]]></Name><ViewObject><![CDATA[AppModule.DeptViewObj1]]></ViewObject></Attribute></Projection><JoinSpec><ViewObject><Name><![CDATA[AppModule.DeptViewObj1]]></Name></ViewObject></JoinSpec></ADFQuery>
    [2011-09-27T02:59:04.199-05:00] [AdminServer] [ERROR] [] [oracle.bi.integration.adf.v11g.obieebroker] [tid: [ACTIVE].ExecuteThread: '2' for queue: 'weblogic.kernel.Default (self-tuning)'] [userId: <anonymous>] [ecid: b260b57746aa92d3:-1f9ca26:1328fcfd3e6:-8000-0000000000006744,0] [APP: BIEEOrders] java.lang.NoClassDefFoundError: oracle/apps/fnd/applcore/common/ApplSession[[
         at oracle.bi.integration.adf.ADFDataQuery.makeQueryBuilder(ADFDataQuery.java:81)
         at oracle.bi.integration.adf.ADFDataQuery.<init>(ADFDataQuery.java:70)
         at oracle.bi.integration.adf.ADFReadQuery.<init>(ADFReadQuery.java:15)
         at oracle.bi.integration.adf.ADFService.makeADFQuery(ADFService.java:227)
         at oracle.bi.integration.adf.ADFService.execute(ADFService.java:136)
         at oracle.bi.integration.adf.v11g.obieebroker.ADFServiceExecutor.execute(ADFServiceExecutor.java:185)
         at oracle.bi.integration.adf.v11g.obieebroker.OBIEEBroker.doGet(OBIEEBroker.java:89)
         at oracle.bi.integration.adf.v11g.obieebroker.OBIEEBroker.doPost(OBIEEBroker.java:106)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:727)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)
         at weblogic.servlet.internal.StubSecurityHelper$ServletServiceAction.run(StubSecurityHelper.java:227)
         at weblogic.servlet.internal.StubSecurityHelper.invokeServlet(StubSecurityHelper.java:125)
         at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:300)
         at weblogic.servlet.internal.TailFilter.doFilter(TailFilter.java:26)
         at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
         at oracle.adf.share.http.ServletADFFilter.doFilter(ServletADFFilter.java:62)
         at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
         at oracle.security.jps.ee.http.JpsAbsFilter$1.run(JpsAbsFilter.java:111)
         at java.security.AccessController.doPrivileged(Native Method)
         at oracle.security.jps.util.JpsSubject.doAsPrivileged(JpsSubject.java:313)
         at oracle.security.jps.ee.util.JpsPlatformUtil.runJaasMode(JpsPlatformUtil.java:413)
         at oracle.security.jps.ee.http.JpsAbsFilter.runJaasMode(JpsAbsFilter.java:94)
         at oracle.security.jps.ee.http.JpsAbsFilter.doFilter(JpsAbsFilter.java:161)
         at oracle.security.jps.ee.http.JpsFilter.doFilter(JpsFilter.java:71)
         at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
         at oracle.dms.servlet.DMSServletFilter.doFilter(DMSServletFilter.java:136)
         at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
         at weblogic.servlet.internal.RequestEventsFilter.doFilter(RequestEventsFilter.java:27)
         at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
         at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.wrapRun(WebAppServletContext.java:3715)
         at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.run(WebAppServletContext.java:3681)
         at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321)
         at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:120)
         at weblogic.servlet.internal.WebAppServletContext.securedExecute(WebAppServletContext.java:2277)
         at weblogic.servlet.internal.WebAppServletContext.execute(WebAppServletContext.java:2183)
         at weblogic.servlet.internal.ServletRequestImpl.run(ServletRequestImpl.java:1454)
         at weblogic.work.ExecuteThread.execute(ExecuteThread.java:209)
         at weblogic.work.ExecuteThread.run(ExecuteThread.java:178)
    Caused by: java.lang.ClassNotFoundException: oracle.apps.fnd.applcore.common.ApplSession
         at weblogic.utils.classloaders.GenericClassLoader.findLocalClass(GenericClassLoader.java:297)
         at weblogic.utils.classloaders.GenericClassLoader.findClass(GenericClassLoader.java:270)
         at java.lang.ClassLoader.loadClass(ClassLoader.java:305)
         at java.lang.ClassLoader.loadClass(ClassLoader.java:246)
         at weblogic.utils.classloaders.GenericClassLoader.loadClass(GenericClassLoader.java:179)
         ... 38 more
    Please suggest how to make it work.

    Hi,
    Thanks for providing the online help URL, i have already completed the steps mentioned in URL
    I am able to import metadata using view object but getting above error("[nQSError: 77031] Error occurs while calling remote service ADFService11G. Details: Runtime error for service -- ADFService11G - oracle/apps/fnd/applcore/common/ApplSession".") while validating the data.
    It fails at step 5 of "To import metadata from an ADF Business Component data source:" section of above URL.

  • Error message when importing data using Import and export wizard

    Getting below error message when importing data using IMPORT and EXPORT WIZARD
    Error 0xc0202009: Data Flow Task 1: SSIS Error Code DTS_E_OLEDBERROR.  An OLE DB error has occurred. Error code: 0x80004005.
    <dir>
    <dir>
    Messages
    Error 0xc0202009: Data Flow Task 1: SSIS Error Code DTS_E_OLEDBERROR.  An OLE DB error has occurred. Error code: 0x80004005.
    An OLE DB record is available.  Source: "Microsoft SQL Server Native Client 11.0"  Hresult: 0x80004005  Description: "Could not allocate a new page for database REPORTING' because of insufficient disk space in filegroup 'PRIMARY'.
    Create the necessary space by dropping objects in the filegroup, adding additional files to the filegroup, or setting autogrowth on for existing files in the filegroup.".
    (SQL Server Import and Export Wizard)
    Error 0xc0209029: Data Flow Task 1: SSIS Error Code DTS_E_INDUCEDTRANSFORMFAILUREONERROR.  The "Destination - Buyer_.Inputs[Destination Input]" failed because error code 0xC020907B occurred, and the error row disposition on "Destination
    - Buyer_First_Qtr.Inputs[Destination Input]" specifies failure on error. An error occurred on the specified object of the specified component.  There may be error messages posted before this with more information about the failure.
    (SQL Server Import and Export Wizard)
    Error 0xc0047022: Data Flow Task 1: SSIS Error Code DTS_E_PROCESSINPUTFAILED.  The ProcessInput method on component "Destination - Buyer" (28) failed with error code 0xC0209029 while processing input "Destination Input" (41). The
    identified component returned an error from the ProcessInput method. The error is specific to the component, but the error is fatal and will cause the Data Flow task to stop running.  There may be error messages posted before this with more information
    about the failure.
    (SQL Server Import and Export Wizard)
    Error 0xc02020c4: Data Flow Task 1: The attempt to add a row to the Data Flow task buffer failed with error code 0xC0047020.
    (SQL Server Import and Export Wizard)
    </dir>
    </dir>
    Error 0xc0047038: Data Flow Task 1: SSIS Error Code DTS_E_PRIMEOUTPUTFAILED.  The PrimeOutput method on Source - Buyer_First_Qtr returned error code 0xC02020C4.  The component returned a failure code when the pipeline engine called PrimeOutput().
    The meaning of the failure code is defined by the component, but the error is fatal and the pipeline stopped executing.  There may be error messages posted before this with more information about the failure.
    (SQL Server Import and Export Wizard)
    Smash126

    Hi Smash126,
    Based on the error message” Could not allocate a new page for database REPORTING' because of insufficient disk space in filegroup 'PRIMARY'. Create the necessary space by dropping objects in the filegroup, adding additional files to the filegroup, or setting
    autogrowth on for existing files in the filegroup”, we can know that the issue is caused by the there is no sufficient disk space in filegroup 'PRIMARY' for the ‘REPORTING’ database.
    To fix this issue, we can add additional files to the filegroup by add a new file to the PRIMARY filegroup on Files page, or setting Autogrowth on for existing files in the filegroup to increase the necessary space.
    The following document about Add Data or Log Files to a Database is for your reference:
    http://msdn.microsoft.com/en-us/library/ms189253.aspx
    If there are any other questions, please feel free to ask.
    Thanks,
    Katherine Xiong
    Katherine Xiong
    TechNet Community Support

  • Subtracting Columns from Import File Using Import Script

    The file I am importing to FDM contains two amount columns, 1 Debit, 1 Credit. I want to have the Amount field populate as the Debit minus Credits. I have attempted an import script that is giving me an error in the bolded line:
    Function GBS_Amount(strField, strRecord)
    'Oracle Hyperion FDM Integration Import Script:
    'Created By:     
    'Date Created:     
    'Purpose:
    'Set variables
    dim strNatural
    dim strCurmnthDR
    dim strCurmnthCR
    dim strCurAmount
    'Store the Natural Account as Column 1 of 11 of a comma delimited file
    strNatural = Trim(DW.Utilities.fParseString(strRecord, 11, 1, ","))
    'Store the Current Month Debit Amount as Column 7 of 11 of a comma delimited file
    strCurmnthDR = Trim(DW.Utilities.fParseString(strRecord, 11, 7, ","))
    'Store the Current Month Credit Amount as Column 8 of 11 of a comma delimited file
    strCurmnthCR = Trim(DW.Utilities.fParseString(strRecord, 11, 8, ","))
    'Calculate the YTD Amount
    strCurAmount = strCurmnthDR - strCurmnthCR
    GBS_Amount = strCurAmount
    End If
    End Function
    What syntax do I need to use to subtract two defined variables?

    Hi Experts,
    I have a similar situation,I am trying to import the Multiple amount columns to be addedd and imported as one amount column.Below is the script I am using for the same,script is getting verified in Script editor but When I am trying to Load the File in import, I am gettig an error as below.but if I try to import without using the script for the amount, inport is getting done.I have attached script to amount column only.
    ERROR
    Code............................................. 9
    Description...................................... Subscript out of range
    Procedure........................................ clsImpProcessMgr.fLoadAndProcessFile
    Component........................................ upsWObjectsDM
    Version.......................................... 1112
    Thread........................................... 8380
    Scirpt being used
    Function Import_YTD(strField, strRecord)
    'Set variables
    dim strCurmnth1
    dim strCurmnth2
    dim strCurmnth3
    dim strCurmnth4
    dim strCurmnth5
    dim strCurmnth6
    dim strCurmnth7
    dim strCurmnth8
    dim strCurmnth9
    dim strCurmnth10
    dim strCurmnth11
    dim strCurmnth12
    dim strCurAmount
    strCurmnth1 = Trim(DW.Utilities.fParseString(strRecord, 20, 9, ","))
    strCurmnth2 = Trim(DW.Utilities.fParseString(strRecord, 20, 10, ","))
    strCurmnth3 = Trim(DW.Utilities.fParseString(strRecord, 20, 11, ","))
    strCurmnth4 = Trim(DW.Utilities.fParseString(strRecord, 20, 12, ","))
    strCurmnth5 = Trim(DW.Utilities.fParseString(strRecord, 20, 13, ","))
    strCurmnth6 = Trim(DW.Utilities.fParseString(strRecord, 20, 14, ","))
    strCurmnth7 = Trim(DW.Utilities.fParseString(strRecord, 20, 15, ","))
    strCurmnth8 = Trim(DW.Utilities.fParseString(strRecord, 20, 16, ","))
    strCurmnth9 = Trim(DW.Utilities.fParseString(strRecord, 20, 17, ","))
    strCurmnth10 = Trim(DW.Utilities.fParseString(strRecord, 20, 18, ","))
    strCurmnth11 = Trim(DW.Utilities.fParseString(strRecord, 20, 19, ","))
    strCurmnth12 = Trim(DW.Utilities.fParseString(strRecord, 20, 20, ","))
    If strCurmnth1="" Then strCurmnth1="0" End If
    If strCurmnth2="" Then strCurmnth2="0" End If
    If strCurmnth3="" Then strCurmnth3="0" End If
    If strCurmnth4="" Then strCurmnth4="0" End If
    If strCurmnth5="" Then strCurmnth5="0" End If
    If strCurmnth6="" Then strCurmnth6="0" End If
    If strCurmnth7="" Then strCurmnth7="0" End If
    If strCurmnth8="" Then strCurmnth8="0" End If
    If strCurmnth9="" Then strCurmnth9="0" End If
    If strCurmnth10="" Then strCurmnth10="0" End If
    If strCurmnth11="" Then strCurmnth11="0" End If
    If strCurmnth12="" Then strCurmnth12="0" End If
    'Calculate the YTD Amount
    strCurAmount = CDbl(strCurmnth1) + CDbl(strCurmnth2) + CDbl(strCurmnth3) + CDbl(strCurmnth4) + CDbl(strCurmnth5) + CDbl(strCurmnth6) + CDbl(strCurmnth7) + CDbl(strCurmnth8) + CDbl(strCurmnth9) + CDbl(strCurmnth10) + CDbl(strCurmnth11) + CDbl(strCurmnth12)
    Import_YTD =strCurAmount
    End Function

  • How to create the Export Data and Import Data using flat file interface

    Hi,
    Request to let me know based on the requirement below on how to export and import data using flat file interface.....
    Please provide the steps involved for the same.......
    BW/BI - Recovery Process for SNP data. 
    For each SNP InfoProvider,
    create:
    1) Export Data:
    1.a)  Create an export data source, InfoPackage, comm structure, etc. necessary to create an ASCII fixed length flat file on the XI
    ctnhsappdata\iface\SCPI063\Out folder for each SNP InfoProvider. 
    1.b)  All fields in each InfoProvider should be exported and included in the flat file. 
    1.c)  A process chain should be created for each InfoProvider with a start event. 
    1.d)  If the file exists on the target drive it should be overwritten. 
    1.e)  The exported data file name should include the InfoProvider technical name.
    1.f)  Include APO Planning Version, Date of Planning Run, APO Location, Calendar Year/Month, Material and BW Plant as selection criteria.
    2) Import Data:
    2.a) Create a flat file source system InfoPackage, comm structure, etc. necessary to import ASCII fixed length flat files from the XI
    ctnhsappdata\iface\SCPI063\Out folder for each SNP InfoProvider.
    2.b)  All fields for each InfoProvider should be mapped and imported from the flat file.
    2.c)  A process chain should be created for each InfoProvider with a start event. 
    2.d)  The file should be archived in the
    ctnhsappdata\iface\SCPI063\Archive directory.  Each file name should have the date appended in YYYYMMDD format.  Each file should be deleted from the \Out directory after it is archived. 
    Thanks in advance.
    Tyson

    Here's some info on working with plists:
    http://developer.apple.com/documentation/Cocoa/Conceptual/PropertyLists/Introduc tion/chapter1_section1.html
    They can be edited with any text editor. Xcode provides a graphical editor for them - make sure to use the .plist extension so Xcode will recognize it.

  • I used the utility, MozBackup.exe, to create: Firefox___.pcv and Thunderbird___.pcv. How do I import or use these files to update from AutoCADGuru to ProCADGuru

    Firefox Team,
    I used the utility, MozBackup.exe, to create:
    Firefox 3.6 (en-US) – 2013-02-10.pcv
    Thunderbird 13.0.1 (en-US) – 2013-02-10.pcv
    How do I import or use these files to update from AutoCADGuru to ProCADGuru?
    Thanks in Advance,
    Kenny

    You are giving conflicting information
    Your question started with "How do I import or use these files to update from AutoCADGuru to ProCADGuru? "
    Then you said:
    "Autodesk's legal department threatened me with a law suit, because my domain name had “AutoCAD in it. So I change it to ProCADGuru. I created” Firefox 3.6 (en-US) – 2013-02-10.pcv and Thunderbird 13.0.1 (en-US) – 2013-02-10.pcv to back everything up. Now I need to know how to use them to restore all of that saved data and update it to my new domain. "
    Then you said:
    "How do I import or use these files to update from www.AutoCADGuru.com to www.ProCADGuru.com?"
    So all that you have explained so far has been about closing down one webhost and moving to another, which has nothing to do with Firefox or Thunderbird.
    Then today you say:
    "I need to know how to use these to restore all of my Address books, email books, sent, saved, and settings for both Firefox and Thunderbird. "
    What is the problem you are trying to solve here? is this about transferring Email settings in Thunderbird, Bookmarks in Firefox, moving a website from one host to another, or something totally different?

  • After importing images from my card using LR 5.4, the GPS data does not show in the metadata panel. However, when I look at the imported images using Bridge, the GPS data is visible. Anybody know why LR is not seeing the GPS data? Camera is Canon 6D.

    After importing images from my card using LR 5.4, the GPS data does not show in the metadata panel. However, when I look at the imported images using Bridge, the GPS data is visible. Anybody know why LR is not seeing the GPS data? Camera is Canon 6D.

    Ok, the issue seem to be solved. The problem was this:
    The many hundred files (raw and xmp per image) have been downloaded by ftp in no specific order. Means - a couple of files in the download queue - both raw and xmps. Most of the time, the small xmp files have been finished loading first and hence the "last change date" of these xmp files was OLDER than the "last change date" of the raw file - Lightroom then seem to ignore the existence of the xmp file and does not read it during import.(a minute is enough to run into the problem)
    By simply using the ftp client in a way that all large raw files get downloaded first followed by the xmp files, we achieved that all "last changed dates" of the xmp files are NEWER than the related raw files. (at least not older)
    And then LR is reading them and all metadata information has been set / read correctly.
    So this is solved.

  • Importing Subtitles using Image Script

    I'm just about to make a project with seven different languages. It will have audio tracks as well as subtitle tracks.
    I've done subtitles in Encore 1.5 before using text with some success. For this production I need to import tif using an image script. I can get the script working, however once it's located the images to import it gives me an error message along the lines of
    "Sorry, an abnormal condition has been detected. Before quitting, you have one chance to save your project..."
    Note I get passed the Map Colours and Import Subtitles dialogue box. It is only when I click on this last stage that it goes bad.
    Any ideas. I kinda thought this was what the program was meant to do.
    - Geoff

    Turns out the problem I was having was due to memory. Needed to restart.
    Naartjie, not sure how to save subtitles with a background image. Encore seems to only want to work with three colours, one is the background colour, the colour of the text and the colour of the outline for the text. So unless you can make your background image from the two colours that remain on the screen - text colour and outline, I'm not sure how to do go about it.
    - Geoff

  • Code Sample: Easy RFC Lookup From XSLT Mappings Using a Java Helper Class

    Hi everyone,
    This is just a shameless plug for my article: <a href="https://www.sdn.sap.comhttp://www.sdn.sap.comhttp://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/docs/library/uuid/05a3d62e-0a01-0010-14bc-adc8efd4ee14">Easy RFC Lookup From XSLT Mappings Using a Java Helper Class</a>. I hope you're interested in reading it, and I welcome your comments in this thread.
    Kind regards,
    Thorsten

    Hi Stefan. Thanks for your post. I have already done that. It still does not work. As a base for my java helper class I have usesd Thorstens code.
    The problem is quite confusing. I will try to ouline both issues here.
    First of all, when try to test from within the Operation Mapping, I always get a java error saying it cannot find the communication channel (it is there and working because I have tested it with the RFCLookup in graphical mapping). I have found a way to work around this, and that is to uncheck the "Use SAP XMLToolkit" checkbox --> switch to test tab, enter my ReceiverService in the parameter tab (header parameter) --> switch back to Definition tab, check the "Use SAP XMLToolkit" checkbox --> switch to Test tab and run the test. Then the XSLT and call to java helper class will work. Of course this is not really something you want to do all the time. Maybe there is a bug.
    Secondly, it never works when I try to do it "live". I am using a file adapter to pick up one file, convert it and a file adapter to drop the converted file. I get the following error code in SXMB_MONI.
    <?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
    <!--  Request Message Mapping   -->
    <SAP:Error xmlns:SAP="http://sap.com/xi/XI/Message/30" xmlns:SOAP="http://schemas.xmlsoap.org/soap/envelope/" SOAP:mustUnderstand="">
      <SAP:Category>Application</SAP:Category>
      <SAP:Code area="MAPPING">TRANSFORMER_CONF_EX</SAP:Code>
      <SAP:P1>ATJ_Accounting2XML_Accounting.xsl</SAP:P1>
      <SAP:P2>http://rd.accounting.logica.com</SAP:P2>
      <SAP:P3>fd552c30-bad9-11dd-9761-c21dac1b818c</SAP:P3>
      <SAP:P4>-1</SAP:P4>
      <SAP:AdditionalText />
      <SAP:Stack>TransformerConfigurationException triggered while loading XSLT mapping ATJ_Accounting2XML_Accounting.xsl; http://rd.accounting.logica.comfd552c30-bad9-11dd-9761-c21dac1b818c-1</SAP:Stack>
      <SAP:Retry>M</SAP:Retry>
      </SAP:Error>
    Using an XSLT without a call to a java helper class, works just fine.
    I am totally at a loss here. Any more input would be much appreciated.
    /Patrik

Maybe you are looking for

  • DirectMapMapping on Toplink 10.1.3

    Hi, I am trying to map my EJB bean which has a property list that I am using directMapMapping to this property table using hashmap and having trouble compiling with weblogic.ejbc. It gave me this error. c:\maranti\msm\src\com\maranti\msm\server\objec

  • Rework in Subcontracting Process

    Hi Experts, I need some suggestion for below scenario, Finished product has been produced from subcontract vendor. Afterthat partial qty of the FG identified rejected. Now we need to send it again for rework. In the rework process vendor change some

  • Decoder error on media center

    I have media center for an hp computer: model # m7170N... it will no longer record or play television. The error message: decoder error- video has either malfunctioned or is not installed comes up. how can i fix this??

  • Multiple Versions in IE6

    Here is the situation... I have a user at my company that is trying to access two websites using Java. One uses a specific runtime and the other works with the latest but doesnt work with the older specific version. Is there a way I can set up IE on

  • Standard Domain Changes

    Hi Experts, I have developed check printing for client. I am getting ZNME1( Name of the Vendor ) field  from REGUH table . But ZNME1 field length is 35 characters. But my client wants field length is 60 characters.. i have taken access key from basis