Valid sesion for run jython script from a plan

If I run a cr_clij script i have to do
app.execStr('udb.login -u user -p password') once and do not produce the login information anymore.
It is possible to do the same with the sessionID, if I run the script from a plan on the BUI? Or do I have to add the '-s sessionID' option to all clui commands?
Thanks

Hi TemPart:
string cmdArg = “C:\\Scripts\\test.ps1″;
Runspace runspace = RunspaceFactory.CreateRunspace();
runspace.Open();
Pipeline pipeline = runspace.CreatePipeline();
pipeline.Commands.AddScript(cmdArg);
Collection [PSObject] results = pipeline.Invoke(); // please Update [] bracket with less then and greater then bracket
runspace.Close();
Had to modify this slightly:
string cmdArg = “Powershell.exe -file C:\\Scripts\\test.ps1″;
Runspace runspace = RunspaceFactory.CreateRunspace();
runspace.Open();
Pipeline pipeline = runspace.CreatePipeline();
pipeline.Commands.AddScript(cmdArg);
Collection [PSObject] results = pipeline.Invoke(); // please Update [] bracket with less then and greater then bracket
runspace.Close();
If this is helpful please mark it so. Also if this solved your problem mark as answer.

Similar Messages

  • Can "Planners" run calc script from the Planning web?

    This is probably a really naive question.
    However, can planners run a simple calc script(created in Essbase/AAS) from Workspace/Planning Web? If so what access would they be need to setup in Shared Service?
    Or do we have to convert the calc script into a Business Rule and then grant access to the users?

    John,
    Here are the roles that i assigned my user and he can view/launch the calc scripts from Planning Web without actually being an admin( i think)
    Analytic Servers : server access
    Business Rules: Administrator
    Planning App : Interactive User
    APS : Provisioning Manager
    I would also like to conver the calc script to a BR as suggested, but not sure why i see no users available in the Business Rules-> administration tab.
    As indicated above, the use has been provisioned as a BR admin!
    Also, i tried refreshing the app with filters, refreshing the user list from BR->admin(right mouse), de-provision and re-provision the user! Any ideas??

  • Running  sql scripts from different directory

    Hi
    I have sql scripts in different directories as follows:
    D:\myapp\sql
    - load.sql
    - init.sql
    D:\myapp\sql\schema
    -users.sql
    -structure.sql
    D:\myapp\sql\populate\
    - data1.sql
    - data2/sql
    load.sql call all the other scripts as below:
    @init.sql
    @schema\users.sql
    @schema\structure.sql
    @populate\data1.sql
    @populate\data2.sql
    All my scripts run correctly when I run load.sql from D:\myapp\sql on comand prompt.
    I need a way to run this script from a different directory say D:\ or C:\
    I am writing a installer which will execute from a different directory.
    Right now I get a file not found error for scripts within schema an populate folder.
    Please let me know how can I make this work from a different directory.
    Thanks
    kelvin

    Hi peter. i think you cannot run files spread across different locations.
    --the method which u specified always looks to the defined path                                                                                                                                                                                                                                                                                       

  • Run a script from a script

    Can anyone help me run a script from a script to kill an event listener?
    There is an event listener on save. The same script may be run multiple times before changing workflows (which require different sets of scripts).
    The eventual goal is to have a time stamp in a specific text frame that will already have content. The new stamp will overwrite the old, and only happen before close. Right now it's set for "on save" because I can't figure out an if else statement for "before close". I don't want to have to end the session to be able to work different job types. I need to be able to kill the event listener when exiting documents that create one.
    I'm throwing crap at the wall, hoping it will stick. I'm sure there's a better way to handle it. Anyone have ideas.
    CS3 & CS4 javascript
    Thanks

    Here's the kind of thing I use:
      function runShortRanges() {
        var shortRangesScript = File(getScriptPath().parent.parent + "/IndexExtras/ShortRanges.jsx");
        if (shortRangesScript.exists) {
          app.doScript(shortRangesScript);
    In this case, I want to run a particular script in a known location, only if it exists. It's a way of adding optional functionality to a script.
    Dave

  • When I run my script from a shortcut ExtendScript is invoked, but it is not when I run it the menu

    I am using Photshop CS2 on Win XP
    I have configured a keyboard shortcut (Crtl+Alt+P) to run a .jsx file from the ...\Presets\Scripts\ folder.
    When I activate the script via the Keyboard Shortcut ExtendScript is invoked, and breaks execution on the main() statement (see below).
    When I activate the script via the File/Scripts menu ExtendScript is not invoked and the script runs to completion.
    The .jsx file is a wrapper for a .vbs script which does the 'real' work.
    The .jsx is:-
    function main()
        var VBSscript=File("C:/Program Files/Adobe/Adobe Photoshop CS2/Presets/Scripts/GGN_PS_Code_v1_2.vbs");
        if(VBSscript.exists) VBSscript.execute();
    main();
    Does anyone have any ideas as to how to disable the invokation of ExtendScript when I run the script from the skortcut?

    Thanks Paul.
    I am out of the office at the moment, but your answer rings true. Certainly the .jsx extension is associated with ExtendScript. I'll delete the association and try again when I am back in the office.
    Many thanks

  • Running sqlplus scripts from Java code?

    hi
    I need to programmatically run sqlplus scripts from Java code on a machine that doesn't have sqlplus installed.
    Is there any Java class library available for doing this?

    The Ant approach could probably work for me, thanks for the tip.
    The setup seems rather complex however, given the simplicity of the task. I would prefer just running a Java based SQL*Plus from in a separate process or doing this via an API that would allow me to run SQL*Plus scripts (parse script, substitute variables, run statements).
    Oracle SQL Developer v1.1 appears to include an API that does exactly this.
    The ScriptParser, Substitution and SQLPLUS classes in the oracle.dbtools.raptor.scriptrunner package (oracle.sqldeveloper.jar) seem to do just what I need based on my tests.
    Can I use these classes for this purpose in my application? Is repackaging allowed?
    Does Oracle have any plans for releasing this sort of functionality separately e.g. as part of the Instant Client?

  • IDCS5-win. Error while running a script from indesign(not via estk)

    Hi all,
    After running the script from indesign, I get following error
    ASSERT '(engine->getDebugFlags() & ScScript::kExtendedErrors) == ScScript::kExtendedErrors' in ..\..\..\source\components\script\javascript\JavaScriptRunner.cpp at line 412 failed.
    ..\..\..\source\components\script\javascript\JavaScriptRunner.cpp (412)
    any idea about this?
    The script runs fine when run from ES tool kit.
    Thanks

    Hi,
    My colleague found the problem. We were using extendables library and we still haven't figured out what was actually happening, but removing it solved the problem.

  • How to run a script from Oracle Form (Beside using HOST command)

    I would like to run a script from Forms 6.0. I know that we can actually issue this command :
    host('plus80.exe' username/password@connect_string @c:\scriptname);
    BUT, is there any other alternative ?

    Sqlplus is a different program, so one way or the other you have to leave Forms to run sqlplus. What is you objection against HOST?
    You can also run sqlplus from the database, but again you need a stored java procedure to call sqlplus (sort of HOST command that runs in the database).
    Francois' solution works if your script just has a query to run, but if you have specific sqlplus commands (spool etc.) forms_ddl is probably not a solution.

  • Running SQLPLUS script from command prompt on SUN

    We are making a migration from VMS to SUN ( SunOS 5.10) and from 9i to 10g. We have encountered an unanticipated problem with running scripts from the command line in SUN(SQLPLUS execution from the command line). All of our packages have a naming convention such as "DM$LOAD.PKB". I know it is a strange naming convention.
    The problem is that when the package creation script is run in SQLPLUS at the command prompt SQLPLUS can not open the file.
    SQL> @dm$load.pb
    SP2-0310: unable to open file "dm$load.pb"
    SQL> host ls
    dm$load.pkb
    SQL>
    Setting the escape character does not seem to help.
    SQL> set escape '\'
    SQL>
    SQL> @dm\$load.pb
    SP2-0310: unable to open file "dm$load.pb"
    SQL>
    Unfortunately, we can not rename the scripts. This can be done from a shell script, but our Tech Services refuse to run the SQL scripts from a shell script
    Any ideas on how to get SQLPLUS to run the scripts from the SUN command line?

    I did not notice that the cut and paste was poor. It should have read
    SQL> @dm$load.pkb
    SP2-0310: unable to open file "dm$load.pkb"
    SQL> host ls
    dm$load.pkb
    Any ideas will be greatly appreciated.

  • Running ISA Scripts from SSL enabled IOP server?

    When attempting to run a script from an SSL enabled IOP server, scripts no longer run.
    Is there a setting to enable the script to utilize the appropriate SSL port?
    Thank you.

    Can you please elaborate some more information on the above post.

  • Running Oracle Scripts from Command Line

    Hi,
    How can i run Oracle scripts from command line.
    Actually i need to run these scripts from MSBuild before running Unit test projects

    C:\>sqlplus @myscript
    That would be the easiest variation
    C:\>sqlplus user/passwd@tns_alias @myscript
    would be an often used variation
    And then there is of course the version with parameter passing:
    C:\>sqlplus user/passwd@tns_alias @myscript param1 ... paramx
    Dunno about MSBuild

  • How can i run unix script from my apex page

    how can i run unix script from my apex page and take the output of unix script as a hidden variable and display it on the report region of that page

    I had a requirement to run a Fortran program against some data that woudl be extracted from the database after the user set up their filtering criteria and made some additional input. SInce the program was to complex to conver to PL/SQL, we decided to try and invoke it from Apex. This is how I did it.
    1. I followed the steps in Tim Archer's excellent article "Oracle External Procedure to Run Host Commands" (http://www.timarcher.com/?q=node/9). If the link does nto work, google the article's title.
    Using this steps I created a function which accepts any OS command, including calling my own shell scripts, and runs them. I called my PL/SQL function "shell" instead of "USF_RUN_HOST_CMD " as Tim did in his example (step 9).
    2. In Apex,
    a. I created a button to run my shell command. (I named it P2_RUN_SHELL)
    b. I created a PL/SQL process whose source looks as follows:
    shell('/home/ackness/scripts/cr_xcf_file.sh > /tmp/cr_scfp_file.log');
    and which was conditioned on the the button P2_RUN_SHELL.
    It works like a charm.
    Note: since you can run your own scripts using this method, you can encapsulate a series of commands in a UNIX shell script and invoke that script from Apex. This allows you to be able to test or run you commands from the command line as well as Apex and makes it easier to develop/debug/enhance the scripts in the future.
    Ackness

  • I have an AT&T locked phone valid contract for another year. I am planning for India visit for 3 months and I want to unlock my phone to use for my purpose. Apple care can help on this? or AT&T Customer care?

    I have an AT&T locked phone valid contract for another year. I am planning for India visit for 3 months and I want to unlock my phone to use for my purpose. Apple care can help on this? or AT&T Customer care?

    It's not going to happen. Even a cursory reading of the forums would have revealed this fact.
    Apple can NOT help you. AT&T WILL NOT help you.
    Leave your iPhone at home or in airplane mode while you're in India and buy yourself a cheap disposable phone to use while you're in India. I believe AT&T still has a program where they will put your account "on hold" while you are gone for a small fee.

  • What are CLASSPATH settings to run WLST scripts from JYTHON

    Hi,
    I am trying to run a Jython script that uses WLST calls.
    Following steps were done
    1. Run WLST.sh
    2. writeinit("wl.py")
    3. Invoke Jython and then do "import wl"
    The import fails with error
    from weblogic.management.scripting.utils import WLSTUtil
    ImportError: No module named weblogic
    Looking at the wlst.sh, it extends classpath for bunch of jars like
    if [ -d "${WLST_HOME}/lib" ] ; then
    for file in "${WLST_HOME}"/lib/*.jar ; do
    CLASSPATH="${CLASSPATH}${CLASSPATHSEP}${file}"
    done
    fi
    Question - what are all the files to be added to classpath ? Is there a script to explicitly set classpath for all relevant jars for WLST usage ?
    Any help will be appreciated

    You shouldn't need to press the Sync button. In the Pod options menu for the share pod, with the PPT loaded, you will see an option for Show Presentation Playbar. Use that to get the Play button for the Hosts and Presenters in the room, and press play. The presentation will now play in a looped mode for everyone in a synchronized mode. You can also then hide the playbar to keep other Hosts and Presenters from stopping the playback and the Participants will never see the playbar or have the option to stop the presentation.
    Additionally, if your focus is on the Share pod (has the focus highlight), you can use the 'P' key to begin playing the presentation without revealing the playbar to anyone. Adobe Connect 9 * Accessibility features

  • Can you open a file in PS & run a script from LR?

    So one of my commercial clients wants their product files in a variety of formats, including PNG with transparency. I'd love to be able to provide them with this from LR, but you can't export as a PNG. So I've written a script which takes the active document in PS, turns off the relevant layers, converts to sRGB, and saves as a PNG. Is there any way for me to invoke this script from LR, as I am opening the document? Ideally, I'd like to include it in the "Edit in" menu, as a menu item which would invoke PS and run the script. That way I could simply select the images, and get them processing while I do something else. Or do I have to open all the files and then run the script on all the open files?

    99jon (à Johannes de Vilder) il y a 2 mois
    Images are automatically saved back to the LR library but you need to follow a logical sequence for LR to render the export copy. You need to start the round trip from LR as follows and use the save command (Ctrl+S) not save as:
    1) Ctrl+E in the Library to export selected image with develop settings (I choose PSD but tiff is also available in the prefs)
    2) Edit in Photoshop; then Ctrl+S to replace (overwrite) Lightroom export copy
    3) Ctrl+W to close in Photoshop and update Lightroom thumbnail. The saved copy is usually stacked next to the original so don't worry about XMP.
    On Mac OSX Cmd+E; Cmd+S; Cmd+W

Maybe you are looking for

  • Image rotation with spry

    <cfsetting enableCFoutputOnly="yes" showDebugOutput="no"> <cfinclude template="../includes/XMLExport/XMLExport.cfm"> <cfquery name="get_ads" datasource="#dns#"> SELECT * FROM BannerAds WHERE type = 'c' AND realastate = 3 AND active = 1 </cfquery> <cf

  • RAC : User equivalence  check failed

    Hi All, Platform linux CentOS 4.5 and oracle 10g. I facing an issue with " user equivalence failed" while executing cluvfy command. On accessing node 2 from node 1 using ssh it is asking for password(oracle user) after configuring SSH. I have configu

  • Fade causes distortion

    I'm trying out Soundbooth and find that when I add a fade to a track, it creates a high pitched distortion.  The harder the fade, the worse the distortion.  At first I thought it was the Dell soundcard, but it does the same when I use an external aud

  • PDF EXPORT - TRANSLATION QUERY

    with Export PDF - if I scan a document with text & pictures for conversion to Word, is there a facility for the final document to be printed off in Englsih, rather than the original (Spanish)

  • How can i import a Numbers'08

    I've just bought Numbers'09 and i need to import my numbers'08 files. Numbers'09 tells me that my file is to much old!!!