Initiating batch scripts from Maxl Script Editor in Admin Console??

Guys,
Is it possible to initiate batch scripts from Maxl script editor in Admin Console.
I dont want to automate the scripts as my data loading process can happen at any time.
Thanks in advance
A

Hi A,
I'm not sure what you're asking? Do you want to run a batch of Maxl scripts, or a batch file, or a single Maxl Script? Why do you choose to use the Admin console to do this? Could you run what you're trying to run in batch from the command line?
Executing MaxL and MDX Scripts
To execute a MaxL script or an MDX script:
Open or create the script.
From the server drop-down list on the toolbar, select the Analytic Server to execute the script against.
The drop-down list contains only Analytic Servers that are displayed in your Enterprise View. For more information about connections, see Connecting to Analytic Servers in MaxL and MDX Script Editors.
Specify how errors should be handled during execution. See Setting MaxL and MDX Execution Options.
Specify how you want results to be displayed in the Results tab. See Viewing MaxL and MDX Results.
If the script contains variables, specify how undefined variables are resolved during execution. See Resolving Undefined Variables.
To execute the entire script, right-click and select Execute from the pop-up menu.
To execute only part of the script, highlight the statement or statements that you want to execute, right-click, and select Execute from the pop-up menu.
The script executes against the specified Analytic Server, and the results are displayed in the Results panel.Regards,
Robb Salzmann

Similar Messages

  • Call Batch file from MAxl Script

    Is it possible to call a windows batch file from a maxl script

    If you look at the documentaion you will see there is a shell command available

  • Error handling from MAXL into a batch file

    Hello all
    I need to know how do we pass a value to a batch file from MAXL script if an error occurs.
    I have used the following in my MAXL to catch an error.
    ========================
    login username password on server01;
    Iferror 'error';
    Define Label 'error';
    Exit;
    =======================
    In the batch file I used:
    If %errorlevel% NEQ 0 goto catch
    :catch
    echo an error occurred during MAXL script
    Exit
    ========================
    This doesnt give me any error even the login info is wrong in the MAXL script
    Please correct if this is wrong and provide any help if possible
    Thanks in advance

    Here's the error checking code I used in my last not-DOS-but-we-call-it-that script:
    REM     Call MaxL script with parameters
    REM The 2>&1 at the end of the below line merges CMD's STDERR into STDOUT
    %hyperion_home%\products\essbase\essbaseclient\bin\essmsh.exe %batAutomation%\%esbAppName%\MaxL\%mshScriptName%.msh %esbUsername% %esbPassword% %esbServer% %esbAppName% %mshScriptName% %batDrive% %batAutomation% >>%log% 2>&1
    REM     Test for MaxL execution errors
    IF NOT %ERRORLEVEL% == 0 (SET errormsg=Error! - MaxL script %mshScriptName%.msh failed with ERRORLEVEL %ERRORLEVEL% & GOTO ERROR)The 2>&1 command at the end of the MaxL script line merges STDOUT and STDERR into an overall log file I used for other processes as well as MaxL. It's great for that purpose, but unfortunately logs the username and password -- this would be overcome by encrypting those values. It was acceptable for the solution so I didn't lose any sleep over it.
    Regards,
    Cameron Lackpour

  • Need 750+ computers removed from FCS Admin Console

    Hi, I'm a noob with FCS, so please pardon me if I sound stupid.
    My requirement is to remove like 750+ computers from the Forefront Client Security Admin Console. We generally follow the following steps to remove a computer:
    Go to the console, expand Administration -> Computers -> Agent-managed Computers
    Select the computer that we want to remove, right-click and select Force to Unmanaged Management Mode
    Go to Unmanaged Computers and remove the computer from there
    Go to Computer Discovery Rules and remove the rule that discovers the computer intended to be removed
    This plainly cannot be done on 750+ computers one-by-one because it will consume A LOT of my time. Is there a script or anything that can help me achieve this?
    I saw the
    post, but not sure if it is the same as my requirement.
    Thank you!
    Ram

    Hi,
    Yes, it is the same as your requirement. But it has no resolution in that thread.
    You could try to use the following tool to see if it meet your requirement.
    Description of the Forefront Client Security Offline Asset Removal Tool
    http://support.microsoft.com/kb/2272146/en-us
    Best Regards,
    Joyce
    We
    are trying to better understand customer views on social support experience, so your participation in this
    interview project would be greatly appreciated if you have time.
    Thanks for helping make community forums a great place.

  • Using MaxL in batch script to get Essbase database size before proceeding

    I have a batch script which dynamically generates some MaxL before passing it to ESSMSH. I would like to insert a command at the beginning of the MaxL script, to get and assess the size of the database before proceeding. If the database is empty I would like the script to quit. This is to prevent the script from exporting data and overwriting the previous export file if the database is empty.
    The generated MaxL (modified) is currently as follows. What logic can I add to the MaxL script, to assess the database size and go to the "errorhandler" label if it is empty? Is this even possible?
    login %USER% identified by %PASS% on %SERVER%;
    iferror "errorhandler";
    /* log file */
    spool stdout on to '<directory>.log';
    iferror "errorhandler";
    /* error file */
    spool stderr on to '<directory>.err';
    iferror "errorhandler";
    /* export data */
    set timestamp on;
    execute calculation %APP%.%DB%.C_Export;
    iferror "errorhandler";
    /* reset database */
    alter database %APP%.%DB% reset data;
    iferror "errorhandler";
    /* import data */
    import database %APP%.%DB% data from server data_file "<filename>.txt" on error abort;
    iferror "errorhandler";
    /* calculate database */
    execute calculation default on %APP%.%DB%;
    iferror "errorhandler";
    /* error handler */
    spool off;
    define label "errorhandler";
    logout;
    exit;

    Hi Stuart,
    Yes I was aware of display database "app"."db"; however this will output a table rather than a specific value. And what logic can I then add to the MaxL script to assess the specific value of "Db Status" and go to the "errorhandler" label if it is empty?
    It would seem this needs to be done via a VBScript, to loop through the file rows to find the value before proceeding accordingly. But I was hoping there might be a way to do this within MaxL.

  • How to call a batch script from DI?

    Hi All,
    I'm new to DI/DS and would like to know is there a way to call a batch sciprt (.bat file) in DI?
    What I try to do is,
    1.call a batch script to move source files from a file server to the source folder before kicking off the data flow
    2. once the data flow is completed, call a batch script to move the processed source files to the achive folder.
    In other ETL tool like informatica it can be done via the command task, is there something similar in DI?
    Any help would be appreciated.
    Regards
    BL

    Thanks Suneer.
    Just want to clarify, when I create the script task in the work flow, should I put the path of my batch file or the batch script itself in?
    e.g., my batch script is movefile.bat under folder C:\Script,
    and the command is:  move /Y "C:\Input\*.*". "C:\Archive\".
    in the script task, should I put
    exec('cmd', 'C:\Script\movefile.bat')
    or
    exec('cmd', 'move /Y "C:\Input\*.*". "C:\Archive\".')
    Thanks again for your help
    Regards,
    BL

  • Batch Script to display last modified file from multiple directories

    Hello,
    I am trying to find the name of the latest file  or the last modified file from a set of given directories.
    I approached the problem by breaking it into two parts: a.  read all the directories from a .txt file and display the names of those directories and files under those directories.  b. Find the latest file present in any given directory and
    Upto this point all worked well, but when I am trying to combine both these batch scripts, I am unable to get the desired result.
    I am using BATCH SCRIPT only to complete this.
    My tried script is as below:
    a.  TO SEE ALL THE DIRECTORIES SPECIFIED IN "path_123.txt" FILE
    for /f "delims=" %%i in ('type "C:\Users\sonkar\Desktop\path_123.txt" ') do (set locall=%%i
    echo %locall%
    echo %%i
    b.  TO FIND THE LATEST FILE PRESENT IN THE DIRECTORY
    set BUILDDROP="E:\"
    for /f "tokens=*" %%a in ('dir /A:-D /B /O:-D %BUILDDROP%') do set NEWEST=%%a&& goto :next
    :next
    echo %NEWEST%
    But when combining both is not working at all.
    Any help is appreciated.

    Since batch files lack the ability to do date arithmetic you are pushing them well beyond their limits. Either VBScript of PowerShell could handle this type of task. Here is a VBScript solution. You must save the code in a .vbs file, then modify it to suit
    your exact needs.
    'Find the most recent file in a collection of folders
    '11 Sep 2014 FNL
    Dim dDate, dDate_, sFile, sFile_
    Set oFSO = CreateObject("Scripting.Filesystemobject")
    Set oList = ofso.OpenTextFile("C:\Users\sonkar\Desktop\path_123.txt", 1)
    aList = Split(olist.ReadAll, vbCrLf)
    oList.close
    dDate = cdate("01/01/2000")
    For Each sFolder In aList
        dDate_ = cdate("01/01/2000")
        ProcessFolder(sFolder)
        If dDate_ > dDate Then
            dDate = dDate_
            sFile = sFile_
        End If
    Next
    WScript.Echo "Most recent file: """ & sFile & """"
    WScript.Echo "File date: " &dDate
    Sub ProcessFolder(sFldr)
        If LTrim(sFldr) = "" Then Exit Sub
        WScript.Echo "Processing """ & sFldr & """"
        For Each oFile In oFSO.GetFolder(sFldr).Files
            If oFile.DateLastModified > dDate_ Then
                dDate_ = oFile.DateLastModified
                sFile_ = oFile.Path
            End if
        Next
        For Each oFolder In oFSO.GetFolder(sFldr).SubFolders
            ProcessFolder(oFolder.path)
        Next
    End sub

  • Calling oracle procedure from batch script

    i have a .bat file, in which i am using sqlldr to load into a staging table from csv file, and then using merge to insert / update into target table
    i have 2 doubts
    1) my first doubt is regarding batch script..how to handle the errorlevels which are greater than 1?
    so generally speaking, how do i handle all the errors at once..and make sure the control goes to
    run_sqlldr0 always? and handle the error meaningfully if its other than 0 ?
    below is my batch script, and i get error
    goto run_sqlldr2
    the system cannot find the batch label specified - run_sqlldr2
    @echo on
    call oraenv.bat
    if not exist %mainpath% goto mainpath_def
    if not exist %scripts% goto scriptspath_def
    if not exist %logs% goto logspath_def
    if not exist %data% goto datapath_def
    goto x1
    :x1
    goto run_sqlldr%ERRORLEVEL%
    echo run_sqlldr%ERRORLEVEL%
    if run_sqlldr%ERRORLEVEL% NEQ 0 goto run_sqlldr1
    echo "entering sqlldr"
    :run_sqlldr1
    echo "entered sqlldr1"
    echo "some error"
    echo mergedata%ERRORLEVEL%
    :run_sqlldr0
    echo "entered sqlldr0"
    sqlldr userid = scott/tiger@orcl control=%mainpath%\cm.ctl log=%logs%\cm.log discard=%logs%\cm.dsc bad=%logs%\cm.bad SILENT=(HEADER, FEEDBACK)
    goto mergedata%ERRORLEVEL%
    :mergedata1
    echo "entered mergedata1"
    echo cleandata%ERRORLEVEL%
    :mergedata0
    sqlplus -s scott/tiger@orcl @%scripts%\merge_stg.sql
    goto cleandata%ERRORLEVEL%
    :cleandata1
    echo "entered cleandata1"
    sqlplus -s scott/tiger@orcl @%scripts%\clean_stg.sql
    goto exit
    :cleandata0
    echo "entered cleandata0"
    echo "error in removing data"
    goto exit
    :mainpath_def
    echo "mainpath not existing as specified %mainpath%, Please edit ORAENV with correct value"
    goto exit
    :scriptspath_def
    echo "scripts path not existing as specified %scripts%, Please edit ORAENV with correct value"
    goto exit
    :logspath_def
    echo "Logs path not existing as specified %logs%, Please edit ORAENV with correct value"
    goto exit
    :datapath_def
    echo "Data path not existing as specified %data%, Please edit ORAENV with correct value"
    goto exit
    :exit
    2) my second doubt, is this the right way of calling the stored procedures merge_stg and clean_stg?
    in clean_stg, i use dynamic sql to truncate the staging table
    create or replace procedure trunstg is
    lsql varchar2(2000) := 'truncate table stg_ldrtest';
    begin
    execute immediate lsql;
    end;
    /

    i have changed the code
    @echo on
    call oraenv.bat
    if not exist %mainpath% goto mainpath_def
    if not exist %scripts% goto scriptspath_def
    if not exist %logs% goto logspath_def
    if not exist %data% goto datapath_def
    goto x1
    :x1
    goto run_sqlldr%ERRORLEVEL%
    echo run_sqlldr errorlevel: %ERRORLEVEL%
    if run_sqlldr%ERRORLEVEL% NEQ 0 goto run_sqlldr1
    echo "entering sqlldr"
    :run_sqlldr1
    echo "entered sqlldr1"
    echo "some error"
    :run_sqlldr2
    echo errorlevel: %errorlevel%
    echo mergedata%ERRORLEVEL%
    :run_sqlldr0
    echo "entered sqlldr0"
    sqlldr userid = gautam/gautam@orcl control=%mainpath%\cm.ctl log=%logs%\cm.log discard=%logs%\cm.dsc bad=%logs%\cm.bad SILENT=(HEADER, FEEDBACK)
    goto mergedata%ERRORLEVEL%
    :mergedata1
    echo "entered mergedata1"
    goto end
    echo cleandata%ERRORLEVEL%
    :mergedata0
    sqlplus -s gautam/gautam@orcl @%scripts%\merge_stg.sql
    goto cleandata%ERRORLEVEL%
    :cleandata1
    echo "entered cleandata1"
    echo "cleaning error"
    goto end
    :cleandata0
    sqlplus -s gautam/gautam@orcl @%scripts%\clean_stg.sql
    goto end
    :mainpath_def
    echo "mainpath not existing as specified %mainpath%, Please edit ORAENV with correct value"
    goto exit
    :scriptspath_def
    echo "scripts path not existing as specified %scripts%, Please edit ORAENV with correct value"
    goto exit
    :logspath_def
    echo "Logs path not existing as specified %logs%, Please edit ORAENV with correct value"
    goto exit
    :datapath_def
    echo "Data path not existing as specified %data%, Please edit ORAENV with correct value"
    goto exit
    :end
    EXIT
    so the error is ORA - 30926, unable to get a stable set of
    rows in the source tables
    my merge is
    MERGE INTO ldrtest D
    USING (SELECT code,id,row_name,col1,col2,col3,crt_tm,md_tm,crt_user,mod_usr FROM stg_ldrtest) S
    ON (d.code = s.code and d.id = s.id and d.row_name=s.row_name )
    WHEN MATCHED THEN UPDATE SET d.col1 = s.col1,
    d.col2 = s.col2,
    d.col3 = s.col3,
    d.crt_tm = s.crt_tm,
    d.md_tm = s.md_tm,
    d.crt_user = s.crt_user,
    d.mod_usr = s.mod_usr
    WHEN NOT MATCHED THEN INSERT (d.code,d.id,d.row_name,d.col1,d.col2,d.col3,d.crt_tm,d.md_tm,d.crt_user,d.mod_usr)
    VALUES (s.code,s.id,S.row_name, s.col1,s.col2,s.col3,s.crt_tm,s.md_tm,s.crt_user,s.mod_usr);
    i did not understand what this error means..
    could anyone please help me out

  • How to extract row_id from PL/SQL procedure and assign that to batch script

    Hello Team,
    I am stuck with a requirement, wherein I am running a batch script and within the batch script I am calling a procedure which inserts a record in a table (Including a column named l_id).
    I need this generated l_id to be passed on as a variable to batch script after PL/SQL procedure completion. So that I can refer this same l_id to update the same record in the table again in the same batch script in the later part.
    Looking for some suggestions!!!!
    Thanks
    -Vj.

    789153 wrote:
    I am stuck with a requirement, wherein I am running a batch script and within the batch script I am calling a procedure which inserts a record in a table (Including a column named l_id). Operating system? Scripting language or command shell used?
    I need this generated l_id to be passed on as a variable to batch script after PL/SQL procedure completion. So that I can refer this same l_id to update the same record in the table again in the same batch script in the later part.
    Looking for some suggestions!!!!Don't do this using batch scripts. Batch scripts are very much inferior compared to stored PL/SQL code when it comes to managing databases processes and performing data crunching.
    Why can't this be written entirely in PL/SQL? And execution managed from either DBMS_JOB or DBMS_SCHEDULER ? And before answering that, consider the following:
    - what is the superior language, PL/SQL or shell script?
    - what provides tighter integration with the database, PL/SQL or shell script?
    - what provides proper security and access control, PL/SQL or shell script?
    As you can call SQL*Plus from a shell script to run PL/SQL, you can call a shell script from PL/SQL instead to run external commands and processes.
    Use the right tool for the job. And shell scripting is an excellent tool - but only when correctly used. Are you using it correctly? I strongly doubt that...

  • Applescript duplicate command runs different as an Application than from Script Editor

    Hi,
    When I run my script from the Script Editor it copies (duplicates) only the new files from one folder to the other one, as desired.  That is, when the file already exists in the destination folder, it just skips to the next one until they are all done.
    However, if I save that very same script as an Application and run it, Finder throws up a dialog box for each item telling me that it already exists and asks if I'd like to Keep Both, Stop or Replace the file.
    I can't figure out why it would run differently as a Script in Script Editor, to how it would run as an Application?  Can somebody please tell me where I'm going wrong? Or perhaps there has been a change in the way Finder and Applescript operate the Duplicate command in Yosemite?
    Interestingly, this problem has only started occurring since I updated to Yosemite.  Before that, on Mavericks, I didn't have this problem!  And I've also just tried the same thing on my other MacBook Pro that's running Mavericks and it works as intended.
    Thanks so much!

    I think the replacing parameter may be broken. The first time I run this:
    tell application "Finder"
      make new folder at desktop with properties {name:"newf"} with replacing
    end tell
    I get a new folder. The second and subsequent times, I get this:
    Unless I'm completely misunderstanding how to use the replacing parameter...

  • Is it possible to start a batch script from Sharepoint?

    Hi,
    I want to start a batch script from Sharepoint which executes some sql queries.
    Can someone guide me how to start a batch (.bat) script in SP?

    Yes and no.  If your script is scheduled to run by some other process (which it should be, because it very likely has  to be run as some account and not the web app account), you should set the script to look for a setting in a sharepoint list,
    if that setting tells the script to run, then it does.  This means that, yes, you can start a batch script from sharepoint.
    To be able to execute a script directly from sharepoint...no.
    Chris Givens CEO, Architecting Connected Systems
    Blog Twitter

  • How to checkout from the batch script?

    Hello All !
    Does anybody knows how to maintain versioned files with the batch scripts? Particularly I'm talking about doing a checkout/checkin operations. Are any command-line utilities available? Is it possible at all?
    Regards, Sergey.

    you can get entire table script
    select dbms_metadata.get_ddl('TABLE','TABLE_NAME','SCHEMANAME') from dual;
    IT is not possible to get only the partition script
    As it is a part of table definition.
    You can also use the third party tool like 'TOAD' to get the script also.

  • Calling SAP Script Editor from Report

    Hi,
    Can any one solve this Problem.
    How to call SAPscript  Editor i.e. MS word editor (where we are giving Text elements or Text variables or Text.
    I want to call the above text editor from my report.
    Can any one give answer for this.
    Thanks & Regards,
    Kumar.

    Moarach,
    you need to open a editor for entering the text. You can do that using the function module HR_CALL_TEXTEDITOR. After you have entered the text and clicked on SAVE you get the data returned in an internal table EDITOR_TEXT.
    You can then save the text to a text ID using SAVE_TEXT and COMMIT_TEXT function modules.
    either:
    You will have to use the FM: READ_TEXT, EDIT_TEXT, SAVE_TEXT to achieve this functionality.
    This will basically open the text editor as a pop up box ( size will be as sap script editor) for entering some comments against a Purchase Order.
    For this FMs, you 'll require Text id, text name, text object and language as parameters to be passed.
    thead-tdname = 'Purchase Order No'. " Name
    thead-tdid = 'ZQH1'. " Text ID - E.g. To be created in your system
    thead-tdobject = 'VBBK'. " Texts: application object
    thead-tdspras = sy-langu. " Language Key
    Hope this helps.
    Amit.

  • Calling Rss feed from Script Editor webpart

    I am trying to add this script to Script Editor webpart and this doesnt work. I dont see anything on webpart. Can anyone help me
    where I went wrong. 
    <html>
    <head>
    <script type="text/javascript">
    $(document).ready(function()
    $.ajax(
    type:”GET”,
    url: "rssreader.com/englishfeeds.xml",
    datatype:”xml”,
    success:function(xml)
    $(xml).find(‘item’).each(function()
    Var Title=$(this).find(‘title’).text;
    Var link=$(this).find(‘link’).text;
    $(“body”).append(‘<div><span>’+Title’</span><span>’+Description’</span></div>’)
    error:function()
    Alert(‘Sorry Error occurred’);
    </script>
    </head>
    <body>
    </body></html>

    Not sure but somehow your quotes seems different then they should actually look.
    //Replace
    type:”GET”,
    //Replace With
    type:"GET",
    Do similar changes at other places as well both for double quotes as well as single quotes.
    Also, replace
    $(this).find(‘title’).text
    with
    $(this).find('title').text();
    Do similar change for link as well
    Also where you are appending the html, where are you getting the Description from ?? Also there is a missing + symbol after Title there.
    Do the above changes and see if that helps
    Geetanjali Arora | My blogs |

  • Run batch script from procedure

    How should we run a batch script that contains FDQM command line from a procedure?
    The command line is created using upsShell.exe.
    If anyone has tried the above scenario, kindly share your ideas regarding this.
    Edited by: Vallikannu Annamalai on Apr 9, 2012 4:33 AM

    SH, Since we use Oracle we cannot use xp_cmdshell.
    When we go for External Procedures, only routines callable from C code (not C++ code) are supported.
    For your information we cannot make use of the C program in our environment.
    Is there any other possibility to run the job from within oracle database.
    Please correct if I m wrong. Kindly need your clarification asap. Thank you.

Maybe you are looking for

  • CAF WebServices don't appear in CAF Admin's External Service Configuration

    Hi, I have developed Web Services in CAF and deployed them on the WAS but they don't appear on the CAF Administrative Tools -> External Service Configuration under Service Registry.  They appear in the Web Service Navigator running on the J2EE-Engine

  • No sound from 32c120u

    I've had my Toshiba 32c120u tv for almost a year and its been working fine but recently it started to have sound problems. It started off as frequent sound distortions then the audio completely stopped working. I tried turning off and on the tv but i

  • How can I migrate data from SQL Server 6,5 to Oracle 8?

    We have a web site based on Microsoft SQL Server 6.5.Now we plan to migrate the database to Oracle 8. We have redesigned the tables structure and created tables under Oracle 8, so we only need to migrate data from SQL Server. We've exported data from

  • Microsoft office report package

    Hi Guys, Im new to LabeVIEW but a colleague and I are working on an automated monitoring project with our company. We have the Microsoft office report package however I am looking for a few simple examples or tutorials explaining their use. I seen th

  • Stupid question: the iTunes Library

    OK, dumb question. If I want to take my entire iTunes library and upload it to a private web server as an emergency backup of everything I own, is there any harm in taking my master iTunes Library folder from my Users/myusername/Music folder and putt