Executing migration scripts outside of OMWB

I'm getting an SP2-0027 error (input > 2499 characters) when trying to execute some of the migration script produced by OMWB. I'm using SQL*Plus Worksheet. OMWB will create the stored procedure or function in the Oracle DB, so the syntax is OK. Is there a different way to run the migration script outside of OMWB to get around the SQL*Plus line limit?
Thanks.

After a week with no replies, I'm considering three possibilities:
1) I posted this question to the wrong forum
2) Everybody (except me) already knows the answer, and is too busy laughing to respond
3) Nobody knows the answer
Will someone be kind enough to buy me a clue?
Thanks.

Similar Messages

  • Can't execute cgi scripts outside the default

    I had this working fine on my old imac.
    On my new mac (Running Latest Lion)...
    I edited /etc/apache2/httpd.conf
    Updated
    User wtfuser
    Group staff
    Updated
    DocumentRoot "/Users/wtfuser/Sites"
    Updated:
    # This should be changed to whatever you set DocumentRoot to.
    <Directory "/Users/wtfuser/Sites">
        # Possible values for the Options directive are "None", "All",
        # or any combination of:
        #   Indexes Includes FollowSymLinks SymLinksifOwnerMatch ExecCGI MultiViews
        # Note that "MultiViews" must be named *explicitly* --- "Options All"
        # doesn't give it to you.
        # The Options directive is both complicated and important.  Please see
        # http://httpd.apache.org/docs/2.2/mod/core.html#options
        # for more information.
        Options Indexes FollowSymLinks MultiViews ExecCGI
        # AllowOverride controls what directives may be placed in .htaccess files.
        # It can be "All", "None", or any combination of the keywords:
        #   Options FileInfo AuthConfig Limit
        AllowOverride None
        # Controls who can get stuff from this server.
        Order allow,deny
        Allow from all
    </Directory>
    I can execute cgi scripts if they are placed in /Library/Webserver/CGI-Executables
    But if I put a test.cgi file inside /Users/wtfuser/Sites/test.cgi
    I get permission denied and errors:
    [Wed May 02 22:38:45 2012] [error] [client ::1] Options ExecCGI is off in this directory: /Users/wtfuser/Sites/sandbox/test.cgi
    [Wed May 02 22:38:45 2012] [error] [client ::1] File does not exist: /Users/lonewolf/Sites/favicon.ico
    [Wed May 02 22:40:07 2012] [error] [client ::1] File does not exist: /Users/lonewolf/Sites/favicon.ico
    [Wed May 02 22:40:14 2012] [error] [client ::1] File does not exist: /Users/lonewolf/Sites/favicon.ico
    [Wed May 02 22:40:24 2012] [error] [client ::1] File does not exist: /Users/lonewolf/Sites/favicon.ico
    [Wed May 02 22:40:25 2012] [error] [client ::1] File does not exist: /Users/lonewolf/Sites/favicon.ico
    [Wed May 02 22:40:25 2012] [error] [client ::1] File does not exist: /Users/lonewolf/Sites/favicon.ico
    Any help is appreciated

    I will send an update.
    I changed this line
    ScriptAliasMatch ^/cgi-bin/((?!(?i:webobjects)).*$) "/Users/wtfuser/Sites/$1"
    This allowed me to successfully change the location of cgi scripts to a more convenient location, or simply because I wanted to do it! Just because!
    It seems like the AddHandler, and the ExecCGI isn't working. This should allow me to run .cgi files from anywhere, regardless of the script alias.
    So I'm open to suggestions as to why this isn't working.  FYI. I copied my httpd.conf file from my old imac running lion onto my new imac, and it still didn't work. But it works as expected on my old imac.
    Confused. But at least I have a work-around and I know the httpd.conf file I'm modifying is the right one, etc...
    ANd what in gods name is that crap with the favicon.ico?
    This is a brand new out of the box imac, or so I thought. Is this normal??

  • Error: Executing OWB Scripts Outside the OWB Tool

    We aim to extract OWB scripts (ddls, pl/sql, etc) and run them outside of the OWB tool in Beta and Production.
    Thus far, we’re able to execute ddls and compile OWB generated pl/sql procedures. We’re encountering errors on all attempts to execute the pl/sql code outside of OWB.
    Package created.
    Package body created.
    SQL> execute RECORDED_MEDIA_MAP;
    BEGIN RECORDED_MEDIA_MAP; END;
    ERROR at line 1:
    ORA-06550: line 1, column 7:
    PLS-00221: 'RECORDED_MEDIA_MAP' is not a procedure or is undefined
    ORA-06550: line 1, column 7:
    PL/SQL: Statement ignored
    Based on previous discussions with Oracle Sales Rep., we were under the impression that this could be done.
    Can OWB generated pl/sql execute outside of the tool? If so, what are the steps?
    Thanks,
    Carol-Ann

    OWB generates mapping as package of procedures. This package has the only external procedure/function (depend on OWB version: 9.2.0.4 - function, prev. releases - procedure).
    So, mapping that you have deployed could be executed by the following code (as for 9.2.0.4 version of OWB):
    DECLARE
    l_res NUMBER;
    l_env WB_RT_MAPAUDIT.WB_RT_NAME_VALUES;
    BEGIN
    l_res := MAP_PACKAGE.MAIN(l_env);
    END;

  • Execute Calc Script from another application

    Hello Guru's,
    i have two applications (Planning and HPCM). Both 11.1.1.3.
    I write a calc.script in HPCM (with XREF) that provide me a data from Planning to HPCM. Now i am trying to execute a script in planning. So that a planning user can load the data by clicking a business rule.
    Is it possible?
    Many thanks,
    WhiteBaer

    VB is a system wide scripting engine, so you can run it from outside InDesign. You create an InDesign object to address InDesign. This can be done by another application as well.
    Javascript is a scripting engine provided soley by InDesign. Unless you have some method of telling InDesign to run the script, it's a non-starter. You can probably create a dll to tell InDesig to run a javascript, but I think a simple VB is WAY simpler...
    All you really need to do is write a very short VB and feed the javascript to the VB as a string anc call app.doScript() providing the javascript to the doScript method.
    HTH,
    Harbs

  • Trouble with Post Migration Scripts

    I try to run the volrepair script but am getting errors. I have run the Update NDS option from nssmu but still now luck.
    ccs_fs1:~ # /opt/novell/migration/sbin/serveridswap/scripts/repair/volrepair.rb -a admin.ccboe -p darabc -f /var/opt/novell/migration/
    Information: Checking NSS status ...
    Information: Getting GUID for NSS Pool ADMIN
    Information: Executing LC_ALL=en_US;ldapsearch -LLL -s sub -H "ldaps://192.168.0 .6" -x -D "admin.ccboe" "(&(CN=CCS_FS1_ADMIN_POOL)(objectClass=nssfsPool)) " "g uid" -W
    Error: Failed to get guid for pool ADMIN
    Information: Getting GUID for NSS Pool APPS
    Information: Executing LC_ALL=en_US;ldapsearch -LLL -s sub -H "ldaps://192.168.0 .6" -x -D "admin.ccboe" "(&(CN=CCS_FS1_APPS_POOL)(objectClass=nssfsPoo l))" "gu id" -W
    Error: Failed to get guid for pool APPS
    Information: Getting GUID for NSS Pool SYS
    Information: Executing LC_ALL=en_US;ldapsearch -LLL -s sub -H "ldaps://192.168.0 .6" -x -D "admin.ccboe" "(&(CN=CCS_FS1_SYS_POOL)(objectClass=nssfsPool ))" "gui d" -W
    Error: Failed to get guid for pool SYS
    Information: Getting GUID for Volume APPS
    Information: Executing LC_ALL=en_US;ldapsearch -LLL -s sub -H "ldaps://192.168.0 .6" -x -D "admin.ccboe" "(&(CN=CCS_FS1_APPS)(objectClass=Volume))" "guid" -W
    Error: Failed to get guid for Volume APPS
    Information: Getting GUID for Volume SYS
    Information: Executing LC_ALL=en_US;ldapsearch -LLL -s sub -H "ldaps://192.168.0 .6" -x -D "admin.ccboe" "(&(CN=CCS_FS1_SYS)(objectClass=Volume))" "guid" -W
    Error: Failed to get guid for Volume SYS
    Information: Updated NSS Pool objects successfully
    Information: MPVGUID v1.1 - Modify Pool or Volume GUID
    List is Empty, there are no Volumes
    GUIDModify failed, status -1
    Failed to Parse the XML from Buffer
    Information: Updated NSS volume objects successfully
    Information: MPVGUID v1.1 - Modify Pool or Volume GUID
    List is Empty, there are no Volumes
    GUIDModify failed, status -1
    Failed to Parse the XML from Buffer
    Warning: The following NSS Pools does not exist on the source server. Use "nssmu " option "Update NDS" for these Pools to repair.
    Warning: ADMIN
    Warning: APPS
    Warning: SYS
    Warning: The following NSS Volumes does not exist on the source server. Use "nss mu" option "Update NDS" for these Volumes to repair.
    Warning: APPS
    Warning: SYS

    $(UYou need to have the same set of pools and volumes on the source server and target server (atleast the names should be identical).
    The error says the pools or volumes that exists on the target server doesn't match with those on the source server.
    Try updating them from nssmu or iManager.
    Refer section "9.0 Preparing for Transfer ID -> 9.1. Prerequisites " of http://www.novell.com/documentation/....html#bookinfo
    -Ramesh
    >>>
    From:
    dmilam<[email protected]>
    To:
    novell.support.open-enterprise-server.migration
    Date:
    05/03/2010 11:06 PM
    Subject:
    Trouble with Post Migration Scripts
    I try to run the volrepair script but am getting errors. I have run the
    Update NDS option from nssmu but still now luck.
    ccs_fs1:~ #
    /opt/novell/migration/sbin/serveridswap/scripts/repair/volrepair.rb -a
    admin.ccboe -p darabc -f /var/opt/novell/migration/
    Information: Checking NSS status ...
    Information: Getting GUID for NSS Pool ADMIN
    Information: Executing LC_ALL=en_US;ldapsearch -LLL -s sub -H
    "ldaps://192.168.0 .6" -x -D "admin.ccboe"
    "(&(CN=CCS_FS1_ADMIN_POOL)(objectClass=nssfsPool)) " "g uid" -W
    Error: Failed to get guid for pool ADMIN
    Information: Getting GUID for NSS Pool APPS
    Information: Executing LC_ALL=en_US;ldapsearch -LLL -s sub -H
    "ldaps://192.168.0 ..6" -x -D "admin.ccboe"
    "(&(CN=CCS_FS1_APPS_POOL)(objectClass=nssfsPoo l))" "gu id" -W
    Error: Failed to get guid for pool APPS
    Information: Getting GUID for NSS Pool SYS
    Information: Executing LC_ALL=en_US;ldapsearch -LLL -s sub -H
    "ldaps://192.168.0 .6" -x -D "admin.ccboe"
    "(&(CN=CCS_FS1_SYS_POOL)(objectClass=nssfsPool ))" "gui d" -W
    Error: Failed to get guid for pool SYS
    Information: Getting GUID for Volume APPS
    Information: Executing LC_ALL=en_US;ldapsearch -LLL -s sub -H
    "ldaps://192.168.0 .6" -x -D "admin.ccboe"
    "(&(CN=CCS_FS1_APPS)(objectClass=Volume))" "guid" -W
    Error: Failed to get guid for Volume APPS
    Information: Getting GUID for Volume SYS
    Information: Executing LC_ALL=en_US;ldapsearch -LLL -s sub -H
    "ldaps://192.168.0 .6" -x -D "admin.ccboe"
    "(&(CN=CCS_FS1_SYS)(objectClass=Volume))" "guid" -W
    Error: Failed to get guid for Volume SYS
    Information: Updated NSS Pool objects successfully
    Information: MPVGUID v1.1 - Modify Pool or Volume GUID
    List is Empty, there are no Volumes
    GUIDModify failed, status -1
    Failed to Parse the XML from Buffer
    Information: Updated NSS volume objects successfully
    Information: MPVGUID v1.1 - Modify Pool or Volume GUID
    List is Empty, there are no Volumes
    GUIDModify failed, status -1
    Failed to Parse the XML from Buffer
    Warning:The following NSS Pools does not exist on the source server.
    Use "nssmu " option "Update NDS" for these Pools to repair.
    Warning: ADMIN
    Warning: APPS
    Warning: SYS
    Warning: The following NSS Volumes does not exist on the source server.
    Use "nss mu" option "Update NDS" for these Volumes to repair.
    Warning: APPS
    Warning: SYS
    dmilam
    dmilam's Profile: http://forums.novell.com/member.php?userid=11991
    View this thread: http://forums.novell.com/showthread.php?t=409414

  • Error while executing the script adgetlnxver.sh

    Error while executing the script adgetlnxver.sh on apps&db tier during upgrade from 11.5.9 to 11.5.10.2
    -bash: [: -lt: unary operator expected
    [aptinst@dba5 TINST_dba5]$ sh adapcctl.sh restart
    adapcctl.sh version 115.55
    /u01/app/tinst/tinstappl/ad/11.5.0/bin/adgetlnxver.sh: line 123: [: -lt: unary operator expected
    Apache Web Server Listener :httpd ( pid 8645 ) is running.
    Restarting the Apache Web Server Dedicated HTTP Listener..
    Apache Web Server Listener (PLSQL) :httpd ( pid 8673 ) is running.
    Restarting the Apache Web Server Dedicated PLSQL Listener..
    adapcctl.sh: exiting with status 0
    In adgetlnxver.sh: line 123 says
    if [ ${setflag}x = "x" -a $os = "RH" ]; then
    redhatver=`grep -oP "Enterprise Linux [a-z A-Z 0-9]* release [0-9]+" /etc/redhat-release | sed 's/Enterprise Linux [a-z A-Z 0-9]* release //g'`
    if [ $redhatver -lt 5 ]; then
    LD_ASSUME_KERNEL="2.4.19"
    export LD_ASSUME_KERNEL
    fi
    fi
    Thanks,
    Vamsi

    Hi Vamsi.
    The exactly erro refers to a problems when you try upgrade from these version to 11.5.10.
    Can you read this note and apply solution? The note refers a patch, but the problem is the same.
    After Patch 4334965, adstrtal.sh & adstpall.sh is failing with errors [ID 360046.1]
    BR Rafael Ceolim

  • Afraid of executing a script on server

    I have to make a script which deletes all the folders and files in the following directories on Windows Server 2008:
    D:\frotxy\out\backup\
    D:\frotxy\in\backup\
    Yesterday I tried executing the script from my Desktop to delete the files in a test folder but unfortunately I had mistaken the path to this folder. What happened was my Desktop files were deleted - ARGHH! 
    So my question is is there a safer way to do the script and check it before executing it on the server as it is important not to delete some other directory or file from the server :)
    This is the script:
    set folder="D:\frotxy\out\backup"
    cd /d %folder%
    for /F "delims=" %%i in ('dir /b') do (rmdir "%%i" /s/q || del "%%i" /s/q)
    set folder="D:\frotxy\in\backup"
    cd /d %folder%
    for /F "delims=" %%i in ('dir /b') do (rmdir "%%i" /s/q || del "%%i" /s/q)
    And where should I place the file containing the script?
    I am not into scripts at all so please help!

    If the folder doesn't exist, you have no error checking there to handle the failure of the cd command, and you continue on with the "delete everything" part.  You can either check for the existence of the folder first, check for an error after
    the CD command, or not use relative paths at all and just pass folder in to the dir command (which would be my preference.)  Here's my example (note the quotation marks have been removed from the set folder line; they're hard-coded later on):
    set folder=D:\frotxy\in\backup
    for /F "delims=" %%i in ('dir /b "%folder%\*"') do (rmdir "%folder%\%%i" /s/q || del "%folder%\%%i" /s/q)
    Note:  I'm not sure what's going on with that (rmdir || del) bit.  To my knowledge, there's no "||" operator in batch files, and "|" doesn't make any sense here, but I've left the original code alone and only changed the bits related
    to where things will be deleted, not how they are deleted.
    Edit:  On a side note, this would be much safer and easier in PowerShell, which is Microsoft's current command-line interface and scripting language.  For example:
    $folder = 'D:\frotxy\in\backup'
    Get-ChildItem -Path "$folder\*" -Recurse -Force | Remove-Item -Force -WhatIf
    That -WhatIf switch on the end of the Remove-Item command is a common parameter in PowerShell.  It shows you what the command would have done, allowing you to make sure you like the results first.  Then you run it again without -WhatIf, and it deletes
    things for you.

  • How to execute vb script with out using Remote manager in oim 11g r2

    Hi Currently,
    i have a requirement to execute  vb script (present on a remote machine in which connector server is installed) from oim machine while using Exchange connector (11.1.1.6).
    This can be achieved by using remote manager,but i dont want to use remote manager.
    Hence decided to use Action scripts.
    As per connector configuration,
    i have configured Action scripts in Lookup.Exchange.UM.Configuration lookup definition, by means of three entries
    After Create Action Language      Shell
    After Create Action Target           Resource
    After Create Action File              /home/scripts/Disable.bat
    Disable.bat has the following ,
    Powershell.exe -File C:\scripts\Setup.vbs
    -%Log on Name%
      Exit
    As Setup.vbs is expecting a parameter of log on name, i was providing the same.
    But while creating the user,as this script gets called, getting the following error and hence 'create User' is getting failed.
    Problem while PowerShell execution System.Management.Automation.RemoteException: This task does not support recipients of this type. The specified recipient XXXXXXXXXXX...XXXXX is of type UserMailbox. Please make sure that this recipient matches the required recipient type for this task.
    While provisioning the user to Exchange , i have selected 'Recepient type' as 'User Mail box' explicitly, but still getting the error.
    Please provide any pointers to resolve the issue.
    Thanks in advance
    Kumar

    As far as I know Oracle and MySQL are two different products.
    Why do you clutter an Oracle forum with MySQL questions?
    If MySQL is such a tremendous RDBMS, like many people state (as 'free' means per definition better),
    why don't you visit a MySQL forum where fellow MySQL aficionados can answer you MySQL questions?
    In short, why don't you stop abusing Oracle forums?
    Sybrand Bakker
    Senior Oracle DBA

  • Dump while executing SAP Script

    Hello,
    My program is throwing a dump while executing this script. Request you all to please help me in removing this.
    /E   MAIN_DATA
    /:    BOX FRAME 10 TW
    PA To,  ,,Invoice No. & Date,,  &JVBRK-VBELN&  &JVBRK-FKDAT&
    PA M/s  &JKNA1-NAME1(35)&,,Your P.O. No.,,  &JVBAK-BSTNK&
    /*           &JKNA1-NAME2(35)&,,Truck No.,,  &JLIKP-TRAID&
    PA         &JKNA1-NAME2(35)&,,Truck No.,,  &WRK_VEHNO&
    PA         &JKNA1-ORT01(20)&,,LR No.& Date,,  &WRK_LRNO&   &JJ_1IEXCDTL-EXDAT& 
    /*           &JKNA1-REGIO(20)&,,Net Qty.in kgs.,,  &JLIPS-NTGEW(10.3L)&
    PA         &JKNA1-REGIO(20)&,,Net Qty.in kgs.,,  &W_NETWT(12.3L)& KG
    PA         ,,Material,,  &JVBRP-ARKTX(30)&
    My Report has the following code:
    FORM write_to_layout_set.
      PERFORM write_layout_set USING 'MAIN' 'SET' 'BODY' 'MAIN'.
      PERFORM write_layout_set USING '' 'SET' 'BODY' 'LOGO'.
      PERFORM write_layout_set USING '' 'SET' 'BODY' 'HEADER2'.
      PERFORM write_layout_set USING 'HEADER' 'SET' 'BODY' 'TEST2'.
      PERFORM write_layout_set USING 'FOOTER' 'SET' 'BODY' 'FOOTER2'.
      PERFORM write_layout_set USING '' 'SET' 'BODY' 'SIGN'.
    ENDFORM.                               " WRITE_TO_LAYOUT_SET
    FORM write_layout_set USING wrk_element
                                wrk_function
                                wrk_type
                                wrk_window.
      CALL FUNCTION 'WRITE_FORM'
         EXPORTING
               element       =  wrk_element
               function      =  wrk_function
               type          =  wrk_type
              window         =  wrk_window
       IMPORTING
            PENDING_LINES =
           EXCEPTIONS
                element       = 1
                function      = 2
                type          = 3
                unopened      = 4
                unstarted     = 5
                window        = 6
                OTHERS        = 7.
    +
      IF sy-subrc NE 0.
        PERFORM protocol_update.
      ENDIF.
    +
    ENDFORM.                               " WRITE_LAYOUT_SET

    As per my first reply you have to change the perform
    PERFORM write_layout_set USING 'MAIN' 'SET' 'BODY' 'MAIN'.
    to
    PERFORM write_layout_set USING 'MAIN_DATA' 'SET' 'BODY' 'MAIN'.
    and now check and one more thing whether this main_data element is in main window or not just check.
    if it does not work then just change &W_NETWT(12.3L)&  to
    &W_NETWT& and check

  • Error to execute the script through command prompt

    I tried to execute the script through command prompt. I got some following error. Could you please advice me how to rectify this.
    cscript D:\JS\Test.js
    Microsoft (R) Windows Script Host Version 5.6
    Copyright (C) Microsoft Corporation 1996-2001. All rights reserved.
    D:\JS\Test.js(1, 1) Microsoft JScript runtime error: 'app' is undefined.
    Thanks,
    Prabudass

    I haven't use CS for quite some time and file associations may not work with the command prompt.
    You can try using Windows Explorer to browse to a .js file then right click on that file. From the popup menu choose Open With. Even if you see Photoshop in the file list choose Browse at the bottom. Browse to Photoshop and make sure to check 'Always use selected program...'
    If that doesn't work you will need to create an action that runs your script and make a droplet from that action. You can then use the droplet in the command prompt. You may also need to create a 'dummy' image file to launch the droplet with if you script doesn't require an open document at startup. See http://www.ps-scripts.com/bb/viewtopic.php?t=967

  • ABAP program to execute shell script !

    Hi Friends,
    I have created some shell scripts and need to be executed through ABAP prog in order to automate some process. can any one tell me how to execute these scripts through ABAP program? i know that we have to setup those scripts through SM69 but i dont have clear idea about this.can some one tell me step by step how to do this. ur help will be awarded in terms of points.
    Thanks

    Define the scripts as commands in SM69. Test them in SM69/SM49 to see if they work.
    Next, go to SE37, run FM SXPG_COMMAND_EXECUTE, and specify your command there. Does it work?
    If yes, you can just code a 'CALL FUNCTION' to this FM in your ABAP program, and you are ready to invoke your script from your ABAP.
    For  a list of functions that work with commands (defined in SM69), do a drop-down on SXPG_COMMAND* in SE37.
    A sample code may look like this
    concatenate zsys_id z_infile z_extfile into parm
        separated by space.
    *C_FTP_COMMAND is a script defined in SM49
        CALL FUNCTION 'SXPG_COMMAND_EXECUTE'
          EXPORTING
            COMMANDNAME                   = C_FTP_COMMAND
            ADDITIONAL_PARAMETERS         = parm
            OPERATINGSYSTEM               = SY-OPSYS
          TABLES
            EXEC_PROTOCOL                 = PROT
          EXCEPTIONS
            NO_PERMISSION                 = 1
            COMMAND_NOT_FOUND             = 2
            PARAMETERS_TOO_LONG           = 3
            SECURITY_RISK                 = 4
            WRONG_CHECK_CALL_INTERFACE    = 5
            PROGRAM_START_ERROR           = 6
            PROGRAM_TERMINATION_ERROR     = 7
            X_ERROR                       = 8
            PARAMETER_EXPECTED            = 9
            TOO_MANY_PARAMETERS           = 10
            ILLEGAL_COMMAND               = 11
            WRONG_ASYNCHRONOUS_PARAMETERS = 12
            CANT_ENQ_TBTCO_ENTRY          = 13
            JOBCOUNT_GENERATION_ERROR     = 14
            OTHERS                        = 15.
        IF SY-SUBRC <> 0.
          MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
                  WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
        else.
          write: /, 'FTP Function module executed with no errors.'.
        ENDIF.

  • How can I execute a script before connection?.

    Hi ,
    I want to execute a script before retrieving the data.How can I do this?.
    Thanks...

    When you say create a command line, what exactly are you referring to? I assume you have a logical schema mapped to the ebs instance you want to run the fnd_global function in (the same one you will have reverse engineered the models from etc), just set that as the schema on the step parameters and ODI will connect through for you as a SQL session.
    Technology set to Oracle ?
    What does the error actually say in the operator log?
    ETA : might be worth checking a few of these links as the refer to EBS with ODI : Oracle EBS and ODI
    Some of the pre-shipped KM's must do something similar to what you are trying to achieve for the apps security.

  • Can you get the file name of the current executing TSQL script?

    Can you get the file name of the current executing TSQL script? I wrote entries to a generic log file and would like to include the script name.

    Okay, So What you can do is
    1. Read get the version from your  database and redirect it to a text file(SQLCMD outout can be directed to text file using -o option or windows redirection operator >)
    2. Now you can read this value from the text file either inside a batch file or a powershell script and decide what operations you can do. 
    Satheesh
    My Blog |
    How to ask questions in technical forum

  • Migrate script to Smartforms

    Hello ,
    <b>Background :</b>
    1) After I migrate Script to smartforms . I get around 200 windows .
    As 200 windows have been defined in a script .( 1 window per box).
    2) The layouts are pretty complex and it would take around 2-3 days to create a new smartform .
    3) I cannot use the existing scripts for a few modifications have to be made to header and footer and it's easier to make them in smartforms
    4)The output after migration is good . A few Modifications But it's fine.
    <b>Problem  :</b>
    i)Would it lead to a performance problem due to presence of 200 windows if I migrate .
    ii)Would it lead to  maintainance problem if I migrate as  I cannot see all the 200 windows at once in the form painter . I can see only the window on which I have placed the cursor .
    Kindly Help me find a solution.

    Thanks Sooness .
    Actually there are around 12 scripts .
    So Total Development time will be around 30 days if I create a new smartform. since the layout is very  complex .
    And 9 days if I migrate scripts to smartforms with changes ..
    So the Conflict in my my mind is whether to go for less Development Time now and maintainance problem later
    <b>Would a  good TS / FS  documented as follows suffice :</b>
    1) By taking a printout of the layout .
    2)Writing the variable name in each window .
    3)Scanning it and using it as FS.
    I feel FS/TS is usually not read afterwards .
    So even after documentation , Maintainace problem will not be solved .
    I do not have that much time . So I would have to put extra efforts at night for creation of new smartforms.
    i have to deliver them in 15/20 days .
    So Do you suggest putting extra efforts now to make a new smartforms to avoid maintainence problem later .
    Kindly give your valuable suggestion.
    Message was edited by:
            Gaurav
    Message was edited by:
            Gaurav

  • Some tags are not showing in SQL when executing the script as per Date

    A) When i am executing below script
    Select ToP 10000 [T_idx],[T_Tag], [T_date], [T_counter] from dbo.[total] ORDER BY T_DATE desc
    i am able to see all tags with respect to date except some tags prefix with ----PO, this 'PO' tags also present in the same table, with same time and date like other tags
    B) When executing below script
    Select top 10000 * FROM dbo.[total] where T_Tag like '%PO%' ORDER BY T_DATE DESC
    i am able to see all tags related to  PO
    How i can all tags including 'PO' with one script. can any one help me ??
    acmi

    Venkat,
    Select ToP 10000 [T_idx],[T_Tag], [T_date], [T_counter] from dbo.[total] ORDER BY T_DATE desc
    The above query MAY or MAY NOT give the records with taag ---PO as they might belong to a later data which might not fit into the top 10,000 dates of the table. This shud be the problem.
    If you want to see all the data irrespective of the number of rows, then below shud help:
    Select
    [T_idx],[T_Tag], [T_date], [T_counter]
    from dbo.[total]
    ORDER BY T_DATE desc
    If you need the rows that CONTAIN --PO then folowing shud do it:
    SELECT
    [T_idx],[T_Tag], [T_date], [T_counter]
    FROM dbo.[total]
    WHERE T_Tag like '%PO%'
    ORDER BY T_DATE desc
    If you need just the top 10,000 rows of the above result, then just add a TOP clause as below:
    SELECT
    TOP 10000
    [T_idx],[T_Tag], [T_date], [T_counter]
    FROM dbo.[total]
    WHERE T_Tag like '%PO%'
    ORDER BY T_DATE desc
    Thanks,
    Jay
    <If the post was helpful mark as 'Helpful' and if the post answered your query, mark as 'Answered'>

Maybe you are looking for