Using Relative Path instead of Full Path OMBPlus

Can we use relative paths in OMBPlus scripts instead of full paths. For example all my OMBplus (tcl) scripts are in folder;
C:\tfsroot2\Interfaces and Extracts\branches\Interfaces and Extracts1.1\000 - OWB Prototype\deploy\ora.stg
and the MDX file I would like to deploy is in
C:\tfsroot2\Interfaces and Extracts\branches\Interfaces and Extracts1.1\000 - OWB Prototype\deploy\ora.stg\scripts\dwextract\tables
but when I try to use
OMBIMPORT MDL_FILE '../scripts/dwextract/tables/$tblName.mdx'
instead of
OMBIMPORT MDL_FILE 'C:/tfsroot2/Interfaces and Extracts/branches/Interfaces and Extracts1.1/000 - OWB Prototype/deploy/ora.stg/scripts/dwextract/tables/$tblName.mdx'
It does not work.
I use
call "C:\OraHome_1\owb\bin\win32\OMBPlus.bat" "C:\tfsroot2\Interfaces and Extracts\branches\Interfaces and Extracts1.1\000 - OWB Prototype\deploy\ora.stg\OMB_DEPLOY_TBL.tcl" XTRCT_WRK_INPUT_FILE
in order to execute.
I think it is because It set the OMBPlus.bat location is a base folder. Any way to overcome this issue and use relative paths instead of the full path?

OK, a couple of things. First, you need to remember that TCL treats back-slashes as an escape character. Always use forward slashes in your paths, or double up the back slashes .
So, this should work:
CD "C:\tfsroot2\Interfaces and Extracts\branches\Interfaces and Extracts1.1\000 - OWB Prototype\deploy\ora.stg"
call OMBPlus.bat "C:\\tfsroot2\\Interfaces and Extracts\\branches\\Interfaces and Extracts1.1\\000 - OWB Prototype\\deploy\\ora.stg\\OMB_DEPLOY_TBL.tcl" XTRCT_WRK_INPUT_FILEor this:
CD "C\tfsroot2\Interfaces and Extracts\branches\Interfaces and Extracts1.1\000 - OWB Prototype\deploy\ora.stg"
call OMBPlus.bat "C:/tfsroot2/Interfaces and Extracts/branches/Interfaces and Extracts1.1/000 - OWB Prototype/deploy/ora.stg/OMB_DEPLOY_TBL.tcl" XTRCT_WRK_INPUT_FILEAs an FYI for OMB, if you are prone to doing a lot of scripts and so building libraries of common functions, you can also easilly use the "file" command in order to determine the current directory at runtime so you can plunk your script anywhere with it's required libraries and it will be able to source them at runtime.
For example, all our scripts have this basic bit of code at the beginning so we can pass them between developers and it doesn't matter where anyone put their script directory - the scripts will find the libraries as long as they are co-located:
#  Get Current Directory and time
set dtstmp     [ clock format [clock seconds] -format {%Y%m%d_%H%M}]
set scrpt      [ file split [file root [info script]]]
set scriptDir  [ file dirname [info script]]
set scriptName [ lindex $scrpt [expr [llength $scrpt]-1]]
set cnfg_lib "$scriptDir/ombplus_config.tcl"
set owb_lib  "$scriptDir/omb_library.tcl"
set sql_lib  "$scriptDir/omb_sql_library.tcl"
#  Import Lbraries
#      Assumes that owb_config, omb_library, and omb_sql_library are in the same directory as this
#      script.
#get config file
if [catch { set retstr [ source $cnfg_lib ] } errmsg] {
   puts "**********************************************************************"
   puts "* Libraries are missing from the current directory. Exiting.... *"
   puts "**********************************************************************"
   return -code 2
#get standard library
source $owb_lib
source $sql_lib
#  Set Logfile
#    This will overwrite anything set in the config file.
set LOG_PATH "$scriptDir/logs"
file mkdir $LOG_PATH
set    SPOOLFILE  ""
append SPOOLFILE $LOG_PATH "/log_"  $scriptName "_" $tabName "_" $dtstmp ".txt"
# Now the main script body goes from here.Cheers,
Mike
Edited by: zeppo on Aug 4, 2009 7:02 AM
Edited by: zeppo on Aug 4, 2009 7:03 AM

Similar Messages

  • Why do windows only use 2GB Ram instead the full 8GB running 32bit Windows 7

    Why do Windows 7 only said 2.17GB usable when there is 8GB RAM available? running 32bit Windows 7 in Bootcamp?

    Check out this link, https://discussions.apple.com/message/13367683#13367683

  • How do I see the full path in Yosemite's spotlight?

    How do I see the full path in Yosemite's spotlight? (cmd shows only partial path)
    Seeing the full path would make work much easier finding my articles which I have put in distinct catalogues.

    CazooMAC,
    Holding ( Command ) to show the path of a file that is displayed at the bottom of the preview pane in Spotlight is the only way to display the path in the Spotlight app its self.
    If you hold ( Command ) and double click the item you are looking to get a path of it will open that items containing folder in Finder. From there you can get the full path using a bunch of different methods. An Example would be using Finders Get Info option. The Keyboard shortcut is ( Command ) ( I ).
    There is another thread that covers the topic of getting a clean path in Finder. Or basically a path that one doesn't have to type out manually, without those little arrows in between folders. It can be found here: How to get a clean file path in OS X Yosemite?
    My Suggestion to get a clean path there is as follows:
    Another way you can get the path, and yes I'm aware its cumbersome, is you can open the "Go to Folder" window and drag your folder or file into it and it will give you the path. Free of modifiers and without opening another application.
    I find it works best if when you start there is no Finder windows open. If you leave one open you just have to open another one as it doesn't let you drag and drop from the one with the "Go to Folder" window in it.
    Finder has to be Active > Select Go ( Menubar ) > Go to Folder...
    Or you can use the keyboard shortcut ( Command ) ( Shift ) ( G )
    At this point I like to clear out the address field as if there is anything in there it will stay.
    Next Open a new Finder window.
    Examples on how to: Select File > New Window, or the keyboard shortcut ( Command ) ( N )
    Find the File or Folder your interested in then drag and drop it in the Address Field of the "Go to Folder" window and it will give you the path.
    If you would like to send Apple feedback about this you can do so here: https://www.apple.com/feedback/macosx.html
    Hope that helps,
    Weston

  • Getting complete full path of a file name

    Greetings Java developer!
    I am having a problem in my JSF program to get a complete full path of a file name if I runs it using a browser other than IE.
    Here is the code I used to retrieve the complete full path of a fine name in my program.
    UploadedFile uploadedFile =
    fileUpload1.getUploadedFile();
    String uploadedFileName =
    uploadedFile.getOriginalName();
    note: fileUpload1 is a UI component of sun.rave.web.ui.model.
    The expected result would be i.e.:
    C:\\abc\file.txt or /abc/file.txt
    It works in the IE browser, but does NOT in Mozilla, Firefox, and Netscape. Is anyone have a clue to resolve this problem? Please advice.
    Thanks!
    jsfNewbie
    Message was edited by:
    jsfNewbie

    Hi,
    The tutorial on file upload
    http://developers.sun.com/jscreator/learning/tutorials/2/file_upload.html
    has been updated to include this information. Pasting the relevant code from the tutorial:
    public String uploadFileButton_action() {
    UploadedFile uploadedFile = fileUpload1.getUploadedFile();
    String uploadedFileName = uploadedFile.getOriginalName();
    // Some browsers return complete path name, some don't
    // Make sure we only have the file name
    // First, try forward slash
    int index = uploadedFileName.lastIndexOf('/');
    String justFileName;
    if ( index >= 0) {
    justFileName = uploadedFileName.substring( index + 1 );
    } else {
    // Try backslash
    index = uploadedFileName.lastIndexOf('\\');
    if (index >= 0) {
    justFileName = uploadedFileName.substring( index + 1 );
    } else {
    // No forward or back slashes
    justFileName = uploadedFileName;
    }

  • Specifying the Universal path, while defining constant path

    Hello All,
                   Whenever I am declaring the constant path, i have to define the path like "E:/ New folder/......vi", which can't be run whenever i shift my project to another pc or if i run the application at another pc, so is there any other possibilities to define the path so that it can be defined as the universal path that, whenever it runs, it take that vi from that universal path, not from static path.
    Thank you,
    Rujuta

    Hi friends,
                   What problem you are facing now, i was facing that long back. So finally i came with good method. 
    In projects always use relative path instead of absoute path. In the same folder create one udl file & for your VI create path for UDL file as follow...
    #1 > use for build path(From shortcut menu)
    #2 > First(Top) path input use as application directory.vi..
    #3 > in the second(Below) input type only udl file name with extension.
    #4 > Output will be always relative.............
                                              Now you can also verify this folder into another directory or other PC as well.
    With Regards
    Ranjeet Singh 
    Kudos are always welcome if you got solution to some extent.
    I need my difficulties because they are necessary to enjoy my success.
    --Ranjeet

  • [svn:bz-trunk] 17772: Update the url in the tests to use a relative path instead of the default localhost : 8400 so that the tests can pass on appservers other than the default Tomcat .

    Revision: 17772
    Revision: 17772
    Author:   [email protected]
    Date:     2010-09-20 15:02:50 -0700 (Mon, 20 Sep 2010)
    Log Message:
    Update the url in the tests to use a relative path instead of the default localhost:8400 so that the tests can pass on appservers other than the default Tomcat.
    Modified Paths:
        blazeds/trunk/qa/apps/qa-regress/testsuites/config/tests/EnforceEndpointValidation/Enforc eEndpointValidationFalseTest/Remoting_NetConnectionTest.mxml
        blazeds/trunk/qa/apps/qa-regress/testsuites/config/tests/EnforceEndpointValidation/Enforc eEndpointValidationTrueTest/Remoting_NetConnectionTest.mxml

    Revision: 17772
    Revision: 17772
    Author:   [email protected]
    Date:     2010-09-20 15:02:50 -0700 (Mon, 20 Sep 2010)
    Log Message:
    Update the url in the tests to use a relative path instead of the default localhost:8400 so that the tests can pass on appservers other than the default Tomcat.
    Modified Paths:
        blazeds/trunk/qa/apps/qa-regress/testsuites/config/tests/EnforceEndpointValidation/Enforc eEndpointValidationFalseTest/Remoting_NetConnectionTest.mxml
        blazeds/trunk/qa/apps/qa-regress/testsuites/config/tests/EnforceEndpointValidation/Enforc eEndpointValidationTrueTest/Remoting_NetConnectionTest.mxml

  • Can you customize the Portal Page_Path item to use relative paths?

    Why does the built-in Portal page_path item generate absolute paths instead of relative paths? It would seem to me to make sense that a breadcrumb (page_path) link would always be on the current site and that relative paths would make sense.
    Is there a setting that can be changed for it to generate relative paths?
    Thanks,
    Jeff

    I don't think that the portlets lend themselves to a viewing (compact) vs. using (maximized) distinction, beyond what the "Show/Hide Folders" button provides.
    In other words, with the folders hidden, things are as small as we felt we could make them for both viewing and editing. The layout is quite liquid and can be stretched and shrunk to fit, given the realities of the items in each portlet (large quantities, long titles, etc.). The visitor tools allow you to arrange the portlets however you'd like.
    Admittedly, the WYSIWYG editor is quite large and we'd like to provide options for the user to size it for their screen or to show/hide it in a future release.
    One thing that would help would be user-selectable columns in tables I suppose. That way you could hide more columns to save space.
    At one point we put the portlet in maximized mode when the user edited something, but that required a full post of the browser, negating the benefits of the AJAX portlet refreshing only itself.
    Do you have any specific examples of what you'd like to see more compact?
    Your feedback is much appreciated.

  • Can any one suggest me how can I use relative path inside SSIS pacakge to access config file ?

    Can any one suggest me how can I use relative path inside SSIS pacakge to access config file ? Please help me as its urgent.THanks for your help in advance.

    Hi Jay,
    SSIS can only recognize the absolute path of a XML Configuration file, the relative path is not supported. Furthermore, if the XML Configuration file is already generated, we can use the Environment variable package configuration type instead so that
    SSIS runtime automatically looks for the configuration file from the path defined in the environment variable. This is convenient when we need to deploy a package to different environment. We only need to define the environment variable for package configurations
    once on each server, and then the variable can be used by all the packages on this server.
    Regards,
    Mike Yin
    TechNet Community Support

  • How to get the full path instead of just the file name, in �FileChooser� ?

    In the FileChooserDemo example :
    In the statement : log.append("Saving: " + file.getName() + "." + newline);
    �file.getName()� returns the �file name�.
    My question is : How to get the full path instead of just the file name,
    e.g. C:/xdirectory/ydirectory/abc.gif instead of just abc.gif
    import java.io.*;
    import java.awt.*;
    import java.awt.event.*;
    import javax.swing.*;
    import javax.swing.filechooser.*;
    public class FileChooserDemo extends JFrame {
    static private final String newline = "\n";
    public FileChooserDemo() {
    super("FileChooserDemo");
    //Create the log first, because the action listeners
    //need to refer to it.
    final JTextArea log = new JTextArea(5,20);
    log.setMargin(new Insets(5,5,5,5));
    log.setEditable(false);
    JScrollPane logScrollPane = new JScrollPane(log);
    //Create a file chooser
    final JFileChooser fc = new JFileChooser();
    //Create the open button
    ImageIcon openIcon = new ImageIcon("images/open.gif");
    JButton openButton = new JButton("Open a File...", openIcon);
    openButton.addActionListener(new ActionListener() {
    public void actionPerformed(ActionEvent e) {
    int returnVal = fc.showOpenDialog(FileChooserDemo.this);
    if (returnVal == JFileChooser.APPROVE_OPTION) {
    File file = fc.getSelectedFile();
    //this is where a real application would open the file.
    log.append("Opening: " + file.getName() + "." + newline);
    } else {
    log.append("Open command cancelled by user." + newline);
    //Create the save button
    ImageIcon saveIcon = new ImageIcon("images/save.gif");
    JButton saveButton = new JButton("Save a File...", saveIcon);
    saveButton.addActionListener(new ActionListener() {
    public void actionPerformed(ActionEvent e) {
    int returnVal = fc.showSaveDialog(FileChooserDemo.this);
    if (returnVal == JFileChooser.APPROVE_OPTION) {
    File file = fc.getSelectedFile();
    //this is where a real application would save the file.
    log.append("Saving: " + file.getName() + "." + newline);
    } else {
    log.append("Save command cancelled by user." + newline);
    //For layout purposes, put the buttons in a separate panel
    JPanel buttonPanel = new JPanel();
    buttonPanel.add(openButton);
    buttonPanel.add(saveButton);
    //Explicitly set the focus sequence.
    openButton.setNextFocusableComponent(saveButton);
    saveButton.setNextFocusableComponent(openButton);
    //Add the buttons and the log to the frame
    Container contentPane = getContentPane();
    contentPane.add(buttonPanel, BorderLayout.NORTH);
    contentPane.add(logScrollPane, BorderLayout.CENTER);
    public static void main(String[] args) {
    JFrame frame = new FileChooserDemo();
    frame.addWindowListener(new WindowAdapter() {
    public void windowClosing(WindowEvent e) {
    System.exit(0);
    frame.pack();
    frame.setVisible(true);

    simply use file.getPath()
    That should do it!Thank you !
    It takes care of the problem !!

  • Word 2013 shows full UNC path instead of local "Documents" folder on file Open and Save

    Normally Word (and Excel) by default will show the user's local "Documents" folder when opening or saving a file. That is what we want. However, after using Windows Server Folder Redirection to redirect the Documents folder to the network (Windows
    Server 2012R2), Word now shows the full UNC path to the network share.
    Instead of seeing:
    "MyPC  Documents"
    users see
    \\sever1\redirect$\username\documents
    Folder redirection is supposed to be transparent to the user. Virtually all our other applications, including Office 2003, respect this convention and continue to show "Documents". As you can see, Word even exposes a hidden share.
    Even if we go to File / Options / Save and browse to the local Documents folder as the place Word should open and save files from, Word immediately removes the path you have browsed to, and replaces it with the UNC path.
    Is there a way to suppress this behavior? Thanx!
    Dana

    Hi,
    Based on my understanding, you only want others to see some part of path name, rather than full UNC path name. It is right?
    It seems that we can’t implement your requirement. When we open a file from “My Pictures”, it shows “My picture” instead of showing the full path “C:\Users\User\Pictures”. “My Picture” is set as a library in Windows, so it hides
    full path by design. We can't set \\sever1\redirect$\username\documents as a library.
    As a workaround, you can upload these files to OneDrive and share link to others.
    If I have anything misunderstood, don't hesitate to tell me.
    Regards,
    Greta Ge
    TechNet Community Support
    It's recommended to download and install
    Configuration Analyzer Tool (OffCAT), which is developed by Microsoft Support teams. Once the tool is installed, you can run it at any time to scan for hundreds of known issues in Office
    programs.

  • Can not connect the database via query string (C#). The SQL Server Management Studio is showing the full path of a location instead of database name.

    I can not connect to the database via C#. The database is showing full path of the database file instead of the database name. See the pic: a database showing only name 'emart' and the other database showing the full path.
    : Robby

    Hi,
    According to your post, I know that the database name is showing file path of the database rather than the database name in SQL Server Management Studio. You were not able to
    establish a connection to the database using C#.
    As Olaf said, was any error message thrown out when the connection failed? How did you create these databases?
    You can use the following T-SQL to attach the database and see if the issue persists.
    CREATE DATABASE
    databasename
        ON (FILENAME = 'filepath _Data.mdf'),
        (FILENAME = 'filepath_Log.ldf')
    FOR ATTACH;
    Thanks.
    Tracy Cai
    TechNet Community Support

  • How to know the full path which is being used in the dataconnection .

    How to know the full path which is being used in the dataconnection without going and looking into coding.
    I am new to crystal reports.
    Plz advice.Thanks in advance
    Jay

    This forum is dedicated to topics related to custom application development or deployment with Crystal Reports in .Net. This includes full versions of Crystal Reports as well as those versions of Crystal Reports bundled with Microsoft Visual Studio .Net.
    As you do not want to do any coding, this query is in the wrong forum. However, in most versions of Crystal Reports, you can look up the database connection information by simply opening the report in the CR designer. Then go to the database menu and select "Set Datasource Location..."
    Ludek

  • Using 'A Variable' in "Help URL" instead of file path

    Hi,
    When we edit 'Title' Tab of analysis we get options such as:
    1. Title
    2. Logo
    3. Subtitle
    4. Started Time
    5. Help URL
    In "Help URL" we can refer a file from an exposed directory (bydefault it's analyticRes). Syntax for refering a file is as follows:
    fmap: Filename OR
    fmap: Custom Folder Name/Filename
    But, I want to check if A Variable (eg: Repository) can be used instead for giving path of the file?
    Regards,
    Jitendra

    Not Possible..why don't you use the subtitle box instead of help url?

  • LoadMovie without having to use full path/URL

    I've always used loadMovie to call external swf files from a
    main/menu swf file, but it seems that some new security settings
    and restrictions, I'm not able to do this anymore - at least not
    online. All my swf files are in the same directory, and when I play
    the swf locally, it loads all the external swfs without a problem.
    I tried changing the path to my swf in the loadMovie command
    to the pull path on the server, and this worked. The problem is, I
    have to hand off my website to another company, and it will go
    through many rounds of testing (and servers) before eventually
    going online. Is there any way to avoid having to use the full
    path/domain in the loadMovie command for a situation like this
    where the domain/path will change?
    I have this in the Flash embed tag:
    <PARAM NAME="allowScriptAccess" VALUE="sameDomain" />
    I have this as my loadMovie command:
    loadMovie ("flashfile.swf", 1);
    But it only works when I have it like this, which is a
    problem because the URL will change many times before launch.
    loadMovie ("
    http://www.website/media/flashfile.swf",
    1);
    Any help would be appreciated!

    Yes, I've done this all the time too, and never had this
    problem, which is why I'm stumped.
    I've changed my code to this, with module_proxy being an
    empty movie clip. This works. But when I take out the URL and path,
    even though the swf files are in the same directory, it's doesn't
    play.
    loadMovie ("
    http://www.website/media/01_Mixie_Pixie_Telegram_Service.swf",
    "module_proxy");
    _parent.gotoAndPlay("dim_menu");
    //openCountdownFile();
    stop();
    Then, I tried to create a varible for the URL/domain, so I
    can change it out more easily (although when I hand this off, I
    won't be able to do that):
    var domainPath = "
    http://www.website/media/"
    function (openCountdownFile){
    var linkToSWF = domainPath + eval(PgFile[item_chosen]);
    loadMovie (linkToSWF, "module_proxy");
    parent.gotoAndPlay("dim_menu");
    var swfPageLabel = item_chosen.toString();
    gotoAndPlay(swfPageLabel);
    This doesn't seem to work either. So, if swf files SHOULD be
    able to communicate using loadMovie, why am I having this problem?
    Thanks.

  • How to read file WITHOUT full path using TEXT_IO?

    We have a scenario like this:
    -- We have a Telco application.
    -- That has 3 types of installations. English and Spanish
    -- We have 2 App Servers (Eng & Spa) for the 2 installation types.
    -- But there is only ONE DB. I.e. users logging into Eng or Spa AS versions login to the same DB.
    -- We have to maintain 2 login forms because of Eng and Spa, because the menu labels have to come in 2 langs.
    -- I am trying to have one tree menu for this.
    -- To do this I did this.
    -- Put a text file in the Forms directory of the AS.
    -- The file has just one line. ENGLISH or SPANISH.
    -- I read this file and find out the language and then show labels according the language.
    Problem is that when I used TEXT_IO and gave file name like this filename:=GET_FILE_NAME('Avabill_AS_Language.txt', File_Filter=>'Text Files (*.txt)|*.txt|');
    I get a error saying file not found.
    I found out that with TEXT_IO you need FULL PATH of the file. Thing is path of the installation depends of installation to installation. I cannot create a parameter in the DB since the DB is COMMON. I HAVE TO use a text file in the AS directory.
    Is there any other way like reading the Default.env file or FormsWeb.cfg? Is there a parameter in any of these files which specifies the forms directory absolute path. I studied both file but could not find an entry.
    Any workaround would be greatly appreciated.

    Thanks BaiG for the quick response.
    U r right about that GET_FILE_NAME.
    I removed that and put the file name only and tried. Still get the same error.
    FUNCTION Avabill_Deployment_Type RETURN VARCHAR2 IS
    v_language VARCHAR2(100);
    in_file Text_IO.File_Type;
    BEGIN
    in_file := Text_IO.Fopen( *'Avabill_AS_Language.txt'* , 'r');
    Text_IO.Get_Line(in_file, v_language );
    Text_IO.Fclose(in_file);
    RETURN v_language;
    EXCEPTION
    WHEN OTHERS THEN
    Text_IO.Fclose(in_file);
    ALERT_MESSAGE(1,'FILE NOT FOUND: ' || SQLERRM);
    RETURN 'Normal';
    END;
    I get this error:
    *302000: non-ORACLE exception*
    As for you query:
    -- We have 2 app servers. One English and One Spanish.
    -- So we have 2 sets of forms. One English with English labels in the forms and the other with Spanish Labels.
    -- So we HAVE to have 2 menu forms as well, don't we? When the menu form is run how does it know whether the app server is English or Spanish.
    -- There is no way to find out. We cannot use a DB variable since BOTH use the same DB (at the same time). Eng users will enter in English while Spanish users will enter in Spanish.
    I don't see how we can have one menu form for this purpose. Can u elaborate your method further please?

Maybe you are looking for

  • Itunes radio missing on my ipod touch 5th gen

    I just got a new ipod 5th gen but the radio is missing from the Music app.what should I do? I have the latest iOs 8 btw

  • How to add 16 bit message sequential number to the byte array

    hi iam trying to implement socket programming over UDP. Iam writing for the server side now.I need to send an image file from server to a client via a gateway so basically ive to do hand-shaking with the gateway first and then ive to send image data

  • Setting up local DNS

    Dear all, with the help of this forum I was abel to set up the Domain, external-IP, DNS-A and PTR-Records at the domainname-server of my IPS. Now I tried to setup the mac mini server as a DNS server. Here you can see my settings: http://dl.dropbox.co

  • Acrobat 9 Pro Scan Problem

    Using Adobe Acrobat 9 Pro version 9.5.1 - All of a sudden scanned documents are showing all dark grey. It was working perfect 2 days ago. All documents are scanned through the Epson scanner.  I searched updates, checked plug-ins and even did a 'repai

  • Displaying multiple asian character sets?

    Hi all, Just wondering is there anyway to display multiple asian keysets in a java application? Right now I can set the locale to say Chinese with the command line property: -Duser.language=zh I could do the same with Japanese or Korean. But I was wo