Host command in reports 6i

Is there a host command in reports 6i? I used this in forms 6i. When I tried to use in Reports 6i, I received a compile error.
Thanks

basically all I need to do is to get directory information. This can be easily done in forms using the host command. Is there any built in package or function to achieve this?

Similar Messages

  • Host command in report

    i want to use host command in report
    but error happened
    any thing instead of host

    i use rep2excel
    i put button in report
    when a user press abutton in report appear
    report in excel format
    and i put this code
    procedure U_1ButtonAction is
    v_conn_str varchar2(50) := 'scott/ghrbia'; --To be changed
    v_rep2excel_path varchar2(100) := 'C:\thepath\rep2excel.exe';--To be changed
    v_cache_path varchar2(100) :='c:\Temp\';--To be changed
    v_random_name varchar2(100);
    v_cmd_rwrun varchar2(300);
    v_cmd_rep2excel varchar2(300);
    v_input_path varchar2(300) ;
    v_output_path varchar2(300) ;
    Begin
    select to_char(round(dbms_random.value(100000, 999999)))||to_char(sysdate,'DDHH24MISS')
    into v_random_name from dual;
    v_input_path := v_cache_path||v_random_name||'.htm' ;
    v_output_path := v_cache_path||v_random_name||'.xls' ;
    v_cmd_rwrun := 'RWRUN60 REPORT=D:\work\banner\report\excel.rdf USERID='||v_conn_str;
    v_cmd_rwrun := v_cmd_rwrun || ' DESTYPE=FILE DESFORMAT=HTML' ;
    v_cmd_rwrun := v_cmd_rwrun || ' DESNAME='||v_input_path||' batch=yes';
    v_cmd_rwrun := v_cmd_rwrun || ' P_dept='||:dept_id;
    --:cmd1 := v_cmd_rwrun ;
    host(v_cmd_rwrun);
    v_cmd_rep2excel:='cmd /c start '||v_rep2excel_path||' -i:'||v_input_path ||' -o:'||v_output_path ||' -open' ;
    -- :cmd2 := v_cmd_rep2excel;
    HOST(v_cmd_rep2excel);
    end;

  • How to run a HOST command from Report 2.5

    Hello everybody,
    I want to pass an unix command from a Report. I am running the report (Report 2.5) on an Unix server and I want to pass a unix host command inside the Before Report Trigger of the report. But Report2.5 is not recognising the HOST built-in. Is there is any way around?
    Thank in advance.
    Samujjwal Basu

    First off is that openssl command correct? Should it be this instead:
    openssl pkcs8 -inform der -nocrypt -in test.der -out result.pem
    Try out your openssl command within a command prompt so that you know that it works ok. I think the command line you specified waits on stdin (well it does for me).
    After that.....
    runtime.exec creates a Process object. If you do this:
    Process openssl = runtime.exec("....")
    then you can examine the return code from openssl to see the exit code - for instance if the input file does not exist then exit = 1. You can test for this with Java
    Alternatively you could get the stderr from the process and look inside it - if it is 0 length then all is good, if it has some text in there then it has likely failed. You could then throw an exception and include the stderr output in the exception messgae. You may need to experiment with this, runnig it first when openssl is happy then running it again when openssl is upset.
    M

  • Host command in forms/reports

    Is there a host command in reports 6i? I used this in forms 6i. When I tried to use in Reports 6i, I received a compile error.
    basically all I need to do is to get directory information. This can be easily done in forms using the host command. Is there any built in package or function to achieve this in reports?
    thanks

    there is no "host" command in reports 6i (or earlier versions). you might want to consider using forms+reports combination (calling the report from within a form, in which you can execute the host command and do whatever you want to do, then pass the related parameters to the report). I am using this approach to handle some complex end user reporting requirements.
    hope this proves useful
    regards

  • Can Reports 3.0 run a host command?

    Can Reports 3.0 run a host command like in Forms 5?
    null

    Hi! Bill
    ANS: NO
    Bill Fox (guest) wrote:
    : Can Reports 3.0 run a host command like in Forms 5?
    null

  • Is there anything like HOST command in Forms in Reports ??

    Hello everybody
    Is there any command in reports like a HOST command in Forms through which I can call a system command.
    My goal is I want to invoke a shell script from my report that will run in the background, do few things and come back to the report once a button is pressed.
    Thanks in advance :-)

    You can4t use the host command, but there is a solution available if you are running 8i with java see http://technet.oracle.com:89/ubb/Forum3/HTML/003262.html
    or
    http://asktom.oracle.com/pls/ask/f?p=4950:8:102326::NO::F4950_P8_DISPLAYID,F4950_P8_B:150612348067,Y
    Hope that will help you

  • How can I use variable name as a prameter value in HOST Command ???

    Hi All,
    How can it possible to use variable value in parameter in HOST command ??
    Following in my code:
    host('rwclient server=reptest report=c:\cust_print.rdf p_1= s_sam_cust_id userid=wh1/wh1@dwh desformat=pdf desty=file desname=c:/temp/'||v_sam_cust_id||'.pdf');
    Regards

    Hello,
    The Syntax of the builtin HOST is :
    SyntaxPROCEDURE HOST
    (system_command_string VARCHAR2);
    PROCEDURE HOST
    (system_command_string VARCHAR2,
    screen_action NUMBER);
    So , you can build the system_command_string as any VARCHAR2
    Example are provided in online help :
    http://www.oracle.com/webapps/online-help/forms/10g/topics/f1_help/builth_m/host.html?tp=true
    Regards

  • Host command in Oracle Reprots 10g

    How to run an executable file from Oracle Reports?
    Can I use a host command?
    What is the syntax?

    Hello,
    To import a java class in a Reports , use the menu :
    Program -> Import java classes ...
    in the Reports Builder.
    The document 361857.1 is available on My Oracle Support :
    https://support.oracle.com/CSP/main/article?cmd=show&type=NOT&doctype=HOWTO&id=361857.1
    Regards

  • Alternative for "Commode" parameter in Host command

    Dear Buddies
    As we use "Commode" parameter to run report (using Run Product built-in), so can we use it in "Host ifrun60" command too to run our reports in "Asynchronous" communication mode?? I've tried this in my Host command like this
    .....commode=asynchronous....
    Or is there any alternative for this parameter to use in Host command?

    Host built in is used to invoke any executable from forms. It can be used to invoke calc , word or any exe
    I dont think its a good idea to use host built since you will not get the status.
    Use run_product or run_report_object
    Rajesh ALex

  • Issues with host command

    Hi All
    We are running Forms 10gR2 under linux. We are having issues with the host command. We use host command to call ProC* modules in the appsvr. It used to work in Forms 6i. Host commnd no longer works in forms10g. Do we need to any setup to run commands using host.
    We need to resolve this issue immediately.
    any help is appreciated.
    Rgds
    Arvind Balaraman

    Arvind has said the command needs to run on the app server so HOST is correct, not CLIENT_HOST.
    I noticed when I installed 10g (on solaris) that the default.env file has a setting for PATH which does not include /usr/bin so HOST would not be able to find standard unix commands, so I added it in:
    PATH=/usr/bin:/home/oracle/product/AS101202/bin
    Alternatively you could include the full path on any unix commands run by HOST.
    Surpisingly I have not seen this documented anywhere. Could this be the problem ?
    I have a related problem I have not solved yet. I have one particular HOST command which works OK until after I run reports from forms, then it just stops working without producing any error.

  • Forms HOST command no longer works after database upgrade from 10g to 11g

    Hi,
    After upgrading the database 10g to 11g the forms HOST command no longer works on Unix server. The form used to work fine prior the upgrade. I read all the threads I could find and did not see any solutions. Adding PATH and LD_LIBRARY_PATH does not work because it does not even run a basic shell script. (I saw this solution, adding PATH and LD_LIBRARY_PATH, in many questions / threads).
    1. I wouldn't expect the database upgrade to be an issue, but it is the only change we had.
    2. Note, 11g is Oracle Fusion Middleware which is quite a bit different than 10g.
    I even tried the most basic commands like "echo" which is a build-in Unix command and there is no directory for it (ie. no /usr/bin - so variable PATH is irrelvent). i.e HOST('echo hi'); and HOST('echo "hi" '); and even HOST ('echo hi > /my_file.txt'); all returns FORMS_FAILURE (actually the if is IF FORM_SUCCESS THEN ... else ... and the else part always runs now - whereas it didn't before.).
    Or basic commands like /usr/bin/ls as in HOST(/usr/bin/ls). At that point I was just testing the Unix command would return FORM_SUCCESS even though I could not see the results (because they weren't writing to a log file). Notice that I'm using the direct path /usr/bin so no Unix environment variables were needed.
    The form does use webutil but that part works. For example, we have webutil_file_transfer( ....) The file shows up on the application server and in the expected directory.
    Here's the main goal. Upload a file from clients local PC to the datebase server. The form uploads the file to the Application server, then we have a Unix script to scp (secure copy) the file from the application server to the database server. IF webutil, or any other Oracle functions could put the file on the database server that would be better. But, I don't know of any procedures that do that - or would have done it cleanly (i.e. storing to database and write back to server and then using a blob etc. )
    Anyway, I was hoping someone would help with either of these.
    1) Get the HOST command to work. - If we can get that to work then I wouldn't need any more help. We can just call the already existing Unix script to copy the file from the application server to the database.
    2) OR be able to upload directly to the database server - wanted to do that originally
    Any help would be appreciated

    Solution for those interested and for anyone else searching this forum for a solution
    I found this on My Oracle Support:
    <h3>Host Command from Forms Not Working in 11g in Sun Solaris Sparc OS [ID 1157346.1]</h3>
    Applies To: Oracle Forms - Version 11.1.1.1.0 and later
    Sun SPARC Sun OS
    Symptoms:
    When trying to execute a Shell script or any OS command using the host() Built-in from Forms 11g, the host()command is not getting executed. The same functionality works on other operating systems and in previous versions like 10gR2.
    Steps to be followed:
    1) Take a backup and edit the $DOMAIN_HOME/config/fmwconfig/servers/WLS_FORMS/applications/formsapp_11.1.1/config/default.env or any custom environment file.
    2) Locate the following environment variable:
    LD_PRELOAD=/ora10gas/app/11.1.0/Middleware/as_1/jdk/jre/lib/sparcv9/libjsig.so
    3) Comment out this variable. After the changes, it will look like the following:
    #LD_PRELOAD=/ora10gas/app/11.1.0/Middleware/as_1/jdk/jre/lib/sparcv9/libjsig.so
    3) a) Instead of LD_PRELOAD, kindly use LD_PRELOAD_64 as given below :
    LD_PRELOAD_64=/ora10gas/app/11.1.0/Middleware/as_1/jdk/jre/lib/sparcv9/libjsig.so
    (This makes HOST AND RUN_REPORT_OBJECT work fine).
    4) Save the file and execute your forms. The Host() built-in will work as expected
    The LD_PRELOAD setting in default.env is only required for the working of signal chaining facility in JVM version 1.5 and later. If you are not using theSignal chaining facility, this variable is not required. For more information, refer to the following documentation
    http://download.oracle.com/docs/cd/E14571_01/doc.1111/e14772/forms.htm#CJAJGAFF

  • Host command is not working on linux

    Hi
    I m using linux for application server n windows for client. I need to create folder from client machine by cliking a button of forms10g runtime.HOST command is not working which was working fine in windows.
    Any help is appriciateable.
    kazi mokarem

    Hi
    I had the same issue on linux a few weeks back. What tuned out was, when you install the Oracle app svr it does not include the system paths by default.
    The path where mkdir is located may not be visible to the app.
    Try to hardcode the path for mkdir as /bin/mkdir .... and seee if that works.
    If the above statement works then add that path in the paths variable in default.env file located in $ORACLE_HOME/forms/server directory
    HTH
    Arvind

  • Host command in forms 10g

    hi all
    i am using host command in forms 10g. but it is not executing .
    is there any distinct syntax or pre-requirement for executing this command
    kindly help
    thanks

    i am using the following code create a text file in root directory.
    the textfile should contain the list of folders,files present in the root directory.
    XCMD:=NULL;
    XCMD:='CD\' ;
         CLIENT_HOST('CMD /C' || XCMD);
    XCMD:='dir >C:foldnm.txt' ;
         CLIENT_HOST('CMD /C '|| XCMD);
    but the file is creating in the specific users directory. ie.
    \ documents and settings\username\desktop
    kindly help

  • HOST command not working in forms 10g

    Hi,
    I have migrated forms 6i to forms 10g, and having a requirement to open sqlplus prompt using a form menu. I have used the below command: -
    "host('sqlplus '||user_name||'/'||pass||'@'||sid, no_screen);"
    But I am not able to get the sqlplus window, and the main form is still in process for long time, till i bounce the server.
    The forms are deployed on Oracle Applications Server 10g and i want to run it on server side.
    Please help me with the problem.
    Thanks,
    Ankit

    The deployment architecture is different between forms 10g and forms 6i.
    In Forms 6i HOST built-in command will run on the client machine since you are running as client/server, but in WebForms (Forms10g) the HOST built-in command will run on the middle tier which is your application server machine.
    In order to run hosts commands in WebForms you need to use webutil and use CLIENT_HOST in the webutil.
    check the [Forms 10g R2 Demo|http://download.oracle.com/otndocs/demos/Forms_Demos_10gr2.zip] for sample codes of webutil.
    You are using NO_SCREEN in your example, this will hide the window.
    Tony
    Edited by: Tony Garabedian on Nov 26, 2009 2:43 PM

  • Use Host command in Oracle forms 6i

    hi
    all
    i use Oracle forms 6i i run in a web and in that i have connect one server so,
    i have to use Host Command and i have to fire this command
    host (' net use \\windchillsvr\e\jyotionline /user:dwg_users dwg_users');
    But it's Not Connect
    My Forms in run in Web
    so help

    JavaBean does d othe job for you but it requires signing process; I used it when I was working on forms6i for our project.
    I could use another approach that is the file type command executable which it stays in client's PC to do it and it does not requires signing at all since I am now working on the Java EE project for downloading and launching the third party tool in client's PC.
    I plan to write a article for forms use, which could do all the heavy WebUtil can do, but not need to go thru the signing process.

Maybe you are looking for