Host command not executing Excel File
Hi,
I am trying to open a Excel file through a bat file.
And calling this bat file from Oracle Forms 10g - Forms [32 Bit] Version 9.0.4.0.19 (Production).
But some how nothing is happening.
But if I issue - host("echo hello > c:\hello.txt"); --> this works fine.
Host command is as - host('cmd.exe /c c:\temp_dir\File_test.bat');
and the bat file contains following lines -
File_test.bat
cd c:\temp_dir
PATH c:\Program Files\Microsoft Office\Office11\
EXCEL Book2.xls
Can anyone please provide some guidance in this regard?
Thanks in advance!
Avinash.
Pune- India.
Hey Guys,
Thanks for your replies,
But it seems I couldn't communicate my point to you.
I want to execute the command on application server and not on client machine.
I guess by using WEBUTIL_HOST it will execute the the command on client side and not on application server.
I hope i made my point clear.
Thanks for your help, looking forward to get more help!
Thanks again!
Avinash.
Pune - India.
Similar Messages
-
Oracle AS Version 10.1.2.0.2, Oracle Forms Version 10.1.2.0.2, Windows XP.
I am using HOST command to read a files from the directory (on the server). But HOST does not working. When i click the button to read the file, it just hangs on and no error on the console.
Does host work on forms 10g?
actually i was using client_host of webutil and its working fine. But it pick the directory from the client. Whereas i need to pick it from the server where AS is. That why i went for HOST command.
Any suggestion.Hi,
Try this.
1. Create a batch file (which would first set the required variables as when you do the "set".)
2. Add the following to the batch file.
C:\javasoft10g\jre\bin\javaw -classpath C:\javasoft10g\jre\lib\rt.jar;C:\javasoft10g\paths;;C:\javasoft10g\paths\dusjava.jar; %1 %2 %3 %4 %5 %6 %7Save the batch file in some location (say c:\mybatchscript.bat).
From forms, call it like
host('cmd /c c:\mybatchscript.bat > c:\temp\testlog.log' );Now, does it work?
-Arun
P.S : Looks to me like, you are setting some variables (or calling another batch file - set , which sets up the variables). So, make sure you set all the required variables in the batch script itself.
-Arun -
Error: can not execute binary files SAP on Linux
Dear Gurus.
I have installed SAP test drive netweaver 2004 on my Linux. when ever i am trying to get the hardware key by the command Saplicense - get, I am getting the error message that " can not execute binary file."
pls do let me know how to get rid of this.
Abhishek> I have installed SAP test drive netweaver 2004 on my Linux. when ever i am trying to get the hardware key by the command Saplicense - get, I am getting the error message that " can not execute binary file."
Please post the output of the commands (as use <sid>adm):
file `which saplicense`
uname -a
Markus -
How to find out each Cell having Data or Not in Excel File by Using WDJ
Hi Friends,
I have one doubt on WDJ.
I have to Upload Excel File. Click on Upload Button in Excel file Data will move to One Bapi. This is I was done. But my Requirement is if any empty Cell in Excel That File not uploaded it display one error message Please upload Correct Excel File
How to find out each Cell having Data or Not in Excel File by Using WDJ. Please tell me.
By Using this Code I have Upload Excel File
InputStream text = null;
int temp = 0;
//wdComponentAPI.getMessageManager().reportSuccess("filePath Vijay:::");
try
File file = new File(wdContext.currentContextElement().getResource().getResourceName().toString());
FileOutputStream op = new FileOutputStream(file);
if (wdContext.currentContextElement().getResource()!= null)
text = wdContext.currentContextElement().getResource().read(false);
while((temp=text.read())!= -1)
op.write(temp);
op.flush();
op.close();
path = file.getAbsolutePath();
//wdComponentAPI.getMessageManager().reportSuccess("Path Name :::::"+path);
catch(Exception ex)
ex.printStackTrace();
But my Requirement is If excel having any Empty Cell that excel file not uploaded.How to do this...
Regards
Vijay KalluriHi my friend
I would like to share you some APACHE APi´s that i use when i have to read excel files in Web Dynpro.
JAR = poi-3.2-FINAL-20081019.jar
Some Example:
POIFSFileSystem fs;
HSSFWorkbook wb;
HSSFSheet sheet;
String myMexican_ValueFromExcelis = "";
try {
fs = new POIFSFileSystem(new FileInputStream();
// and select the cell "y"
cell = row.getCell( 0 );
myMexican_ValueFromExcelis = cell.getCellValue();
}cach(Exception e){
REgargds -
SQLPLUS HOST Command Not Supported
Hi,
I am facing strange problem. I have lots of scripts where I have used the HOST command from within SQLPLUS.
Now, on Windows Server 3000 Standard Edition, Version 5.2, I find that both HOST and its equivalent $, both are not supported when used with SQLPLUS on Oracle 10g Enterprise Edition.
Please HELP, and suggest some alternative.
PrashantThere is no such thing as Windows Server 3000. The latest product appears to be Windows Server 2008.
I'm not sure what the version of the Oracle database has to do with it. This is about SQL*Plus and you still haven't told us what version of that you are using. For example:
SQL*Plus: Release 11.1.0.6.0 - Production on Sat Dec 6 15:56:12 2008
Copyright (c) 1982, 2007, Oracle. All rights reserved.
Connected to:
Oracle Database 11g Enterprise Edition Release 11.1.0.6.0 - Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options
SQL> host cd
y:\sql
SQL>This is sqlplus.exe (never sqlplusw.exe) version 11.1.0.6.0 on Windows XP Pro 2002 SP3. It's not the best example because SQL*Plus and the database are at the same version - they are often different. For example:
/Users/williamr: sqlplus william/x@//vm.starbase.local:1521/eleven
SQL*Plus: Release 10.1.0.3.0 - Production on Sat Dec 6 16:01:21 2008
Copyright (c) 1982, 2004, Oracle. All rights reserved.
Connected to:
Oracle Database 11g Enterprise Edition Release 11.1.0.6.0 - Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options
SQL> ho uname -a
Darwin starbase-2.local 8.11.1 Darwin Kernel Version 8.11.1: Wed Oct 10 18:23:28 PDT 2007; root:xnu-792.25.20~1/RELEASE_I386 i386 i386
SQL> I've never known the host command not work, but perhaps someone with the same setup as you can confirm they don't have the same problem. I'm also a bit puzzled by the error message "Command not success." That doesn't sound like an Oracle command - apart from being vague and ungrammatical it doesn't start with the standard "SP2-nnnn" prefix, for example:
SQL> x
SP2-0042: unknown command "x" - rest of line ignored.Can you copy and paste the exact commands and results you get?
Edited by: William Robertson on Dec 6, 2008 4:04 PM -
Host command not working properly
Hi,
I am using oracle forms 10.1.2.0.2.
In my form, I need to call a unix shell script.
{ Oracle forms will run on application server.
Unix will run in a development server.
(Both the servers are different)
From forms, if I click a button, it should call the unix shell script in a specified path.
Internally, the unix script will call oracle to generate a file.
In the file, some manipulations are done using unix.
After doing some manipulations, the file is stored in a specified path in the unix box. }
To achieve the above, I did the below things.
To execute a unix shell script from my oracle forms (10g),
1) the below configuration i added in the webutil.cfg file
install.syslib.0.user.1=ffisamp.dll|40960|1.0|true
transfer.database.enabled=TRUE
transfer.appsrv.enabled=TRUE
transfer.appsrv.workAreaRoot=c:\temp
transfer.appsrv.accessControl=TRUE
#List transfer.appsrv.read.<n> directories
transfer.appsrv.read.1=c:\temp
#List transfer.appsrv.write.<n> directories
transfer.appsrv.write.1=c:\temp
2) I have attached webutil.pll library to my form
3) I have subclassed object group from webutil.olb to my form.
4) The host command i used is (these code are present in when-button-pressed trigger of a button)
host('rsh selvas -l administrator sh <foldername>/if_csv.ksh',NO_SCREEN);
if form_failure then
emessage('hi selva');
emessage(SQLERRM);
else
emessage('failure selva');
end if;
when I click the button, I am getting the below messages,
hi selva
normal, successful completion
Also, the script is not executing and it is not giving me the desired result.
Can any one help me, where I am missing.
Thanks,
Selvarajhi steve,
Thanks for your response
after the host command i added like this
host.....;
pause;
if form_failure then
emessage('hi selva');
else
emessage('failure selva');
end if;
when I executed,
I got the below messages
PLEASE ACKNOWLEDGE
-- when i clicked ok,
it showed me failure selva
but still the shell script has not executed.
Note:
In /tmp directory, no log files are available.
Can you plz help
thanks,
selvaraj -
Hi:
I am using WIN7 ultimate 64 bit and excel 2010 (office 2010 Pro plus).
I can not open any excel file(.xls and .xlsx) with a double click on the file. if I double click on the file, the application launches and excel starts, but no file is loaded and no error message, I have to manually go file open and select the file and
then it opens correctly...
I have tried every solutions I can find from internet, but none worked....
1.Repair the office 2010 instalation.------doesn't work.
2.Right-click the file >>Select "Open With" and select [Excel 2010]>> Check always use this program. ------doesn't work.
3.Options>>Advanced>>General section>>unchecked "Ignore Other Applications that use Dynamic Data Exchange (DDE)".------doesn't work.
4.Run>> input "Excel /regserver". ------doesn't work.
5.Create new user profiles.------doesn't work.
6.Delete EXCEL folder under "HKEY_CURRENT_USER\Software\Microsoft\Office\14.0\".------doesn't work.
Is there any other solutions can fix this problem? Any help are appreciated.
Yong.Hello Yong,
Thanks for posting in our forum. Seems you've already tried lots of things, and I can see that those are all steps that reportedly have worked for others.
Here is one more thing that you might want to have a try:
Open Registry Editor
Go to the registry key HKEY_CLASSES_ROOT\Excel.Sheet.12\shell\Open\command
Highlight the key, select the (Default), select "Modify..."
from the pull-down menu and then enter the value below: "C:\Program Files\Microsoft Office 15\Root\Office15\EXCEL.EXE"
"%1" (include the quote marks)
Then OK your way out
Please have a try and feel free to post back.
Regards,
Ethan Hua
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. -
Host command not showing the output
Hi,
I am not able to view the host command's output from sqlplus(i am using an windows XP OS).
The commands i tried:
SQL> $whoami
SQL> host whoami
SQL> !whoami
-Thanks
Boopathy VasagamSolomon Yakobson wrote:
And keep in mind, SQL*Plus command host will open a command window, execute command and will close command window To avoid this you can use:
host cmd /k echo %USERNAME%or
host cmd /k echo %USERDOMAIN%\%USERNAME%Then SQL*Plus will open command window, execute echo command and will not close command windows (since /k was used). You will have to manually issue exit command in command window to close it.
SY. -
PSFTP mput command not executing.
Hello Guys,
In my below mentioned script, everything is working fine, I'm able to push file on server through put command. But when I'm using mput command to upload multiple files script stucks with no output. I did lot of research but no success. Could anyone of you
can tell me where exact issue is ?
strHostname = "transfer.com"
strUsername = "User1"
strPassword = "password"
strLocalDir = "C:\data"
strRemoteDir = "Sales"
PSFTP_DIR = "c:\windows\"
PSFTP_EXE = PUTTY_DIR & "psftp.exe"
strFile1="*.txt"
'strGetFile ="abc.txt"
strFtpScriptFile = "c:\myscript.txt"
strOutputFile = "C:\output.txt"
Set WshShell=CreateObject("Wscript.Shell")
Set fso=CreateObject("Scripting.FileSystemObject")
Set oFile=fso.OpenTextFile(strFtpScriptFile,2,true)
oFile.WriteLine "lcd " & chr(34) & strLocalDir & chr(34)
oFile.WriteLine "cd " & chr(34) & strRemoteDir & chr(34)
oFile.WriteLine "ls" & chr(34)
'oFile.WriteLine "get " & chr(34) & strGetFile & chr(34)
File.WriteLine "mput " & strFile1
oFile.WriteLine "quit" & chr(34) & vbCrLf
oFile.Close
Set fso = Nothing
PSFTP = "C:\windows\psftp.exe -v -be -bc " & " -l " & strUsername & " -pw " & strPassword & " " & _
strHostname & " -b " & strFtpScriptFile & " >> " & strOutputFile & " 2>&1"
MsgBox PSFTP
WshShell.Run PSFTP,1.True
WScript.Echo oScriptExec.ExitCode
Set oFile = Nothing
'WScript.Echo oScriptExec.StdErr.AtEndOfStream
WScript.Quit
Below is a output when I execute mput command..
Looking up host "transfer.com"
Connecting to <IP ADDRESS> port 22
Server version: SSH-2.0-Internet Server SSHD
Using SSH protocol version 2
We claim version: SSH-2.0-PuTTY_Release_0.63
Doing Diffie-Hellman group exchange
Doing Diffie-Hellman key exchange with hash SHA-1
Host key fingerprint is:
ssh-rsa 1024 xx:xx:xx:xx:xx:xx:xx:xx:xx
Initialised AES-256 SDCTR client->server encryption
Initialised HMAC-SHA1 client->server MAC algorithm
Initialised AES-256 SDCTR server->client encryption
Initialised HMAC-SHA1 server->client MAC algorithm
Using username "User1".
This is MFT KIILA QA env DMZ ServerAttempting keyboard-interactive authentication
Access granted
Opening session as main channel
Opened main channel
Started a shell/command
PTmput command worked perfectly. As there was no indication of file uploading progress in %, I assumed script stucked in mid.
Apart from question I asked I have few queries:
1. As my log states above "Server version: SSH-2.0-Internet Server SSHD". I'm in need of codes list returned by
server.
2. Can it be possible to get file transfer rate means progress in %?
3. Currently Which file is in use (means uploading). How can it be tracked?
PT -
-bash: sqlplus: command not found / Oracle file permissons
Hi,
I am running Oracle EE 10.2.0.1.0, on a RHEL 4-U2 server.
When I try to use sqlplus from a non dba account I get the following error:
[pemarten@orclserv ~]$ sqlplus pemarten/mypassword
-bash: sqlplus: command not foundAll my environment variables are set and $ORACLE_HOME/bin has been added to the PATH.
The problem seems to be that the file permissions of the oracle flexible architecture are wrong:
[oracle@orclserv 10.2.0]$ pwd
/u01/app/oracle/product/10.2.0
[oracle@orclserv 10.2.0]$ ls -l
totaal 8
drwx--x--- 56 oracle oinstall 4096 dec 12 14:15 db_1
drwxr-x--- 46 oracle oinstall 4096 dec 12 14:14 htmldbThe permission of the db_1 directory is to strict (should be at least chmod 711 I think)
On my other test server (DB version 10.1) the permissions are:
[oracle@locserv 10.1.0]$ pwd
/u01/app/oracle/product/10.1.0
[oracle@locserv 10.1.0]$ ls -l
total 4
drwxr-xr-x 53 oracle oinstall 4096 Oct 12 02:54 db1So I have tried to chmod the directories to at least 711 up to the sqlplus binary, but when I try to execute sqlplus after that I get the following error:
[pemarten@orclserv ~]$ sqlplus pemarten/mypassword
sqlplus: error while loading shared libraries: libsqlplus.so: cannot open shared object file: No such file or directorySo this doesn't seem to be an option. My biggest concern is why are the file permissons wrong after installation?
Before installing the oracle software umask 022 was added to the .bash_profile of the oracle user (used to install the software)
Has anyone experienced similar problems?
Does anyone knows how to solve this?
Thank You.
PieterIvan,
Thanks for your reply.
I have changed the file permissions of +- 5 files in the lib directory, every time that I changed the permission of 1 file, I got an error for another one.
Now I am getting the following error
[pemarten@orclserv ~]$ sqlplus pemarten/mypassword
SP2-1503: Unable to initialize Oracle call interface
SP2-0152: ORACLE may not be functioning properlyAccording to oerr there are still lib files with wrong permissions...
What I would like to know is :
1) Are the file permissions changed in 10.2 (only DBA's can use sqlplus on the database server) ? If not I probably did something wrong and I will do a reinstall
2) Can anyone who has version 10.2 installed post an ls -l of his $ORACLE_HOME directory please, so I can compare the file permissions ?
Thank You,
Pieter -
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,
AnkitThe 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 -
Itunes & numbers will not import excel files
I have tried with several different files and with different types. But numbers will not import any excel files to my ipad. Is there something i am missing?
Have you copied the files from iTunes to the Numbers program? Go to the My Spreadsheets page in Numbers and tap the in box (Open box with in arrow). You will see a couple of option with one of those being "Copy from iTunes". Try that and the file should appear in My Spreadsheets.
-
Hi all,
We are getting the following error when trying to index some MS Excel files:
14011 - Filter: The file is password protected or encrypted
We are using TREX 7.10 rev 34.
We have found that the cause of this is when the Excel file has been set to protect the worksheet with a password (in Excel, go to Tools -> Protection -> Protect Workbook -> set password). It seems odd to me that TREX cannot index a file like this because it should be able to open it. I would think that it only would have problems if it were trying to write to the file (which it is not trying to do).
Does anyone have any ideas as to why it's like this or what can we do about this other than remove the workbook password? We have dozens of files like this, and I need to find a solution other than removing the password.
Thanks!
-StephenSHi Stephen,
I couldn't find any release note specific to this issue however I do know that there are newer filter versions available in the most recent TREX revisions so the upgrade is usually a good option to resolve such issues. Of course I cannot say for certain if Revision 39 will resolve it without trying to index your specific document on that version myself.
Anyway I know there are some Oracle filter issues ongoing with TREX 7.1 so I think an upgrade to a newer revision may be inevitable at some stage, but perhaps in this scenario it would be best to wait for confirmation of the exact revision that contains the fix from the TREX experts in your message.
Kind regards,
Lorcan. -
/etc/hosts ; exit;
/etc/hosts: line 7: 127.0.0.1: command not found
/etc/hosts: line 8: 255.255.255.255: command not found
/etc/hosts: line 9: ::1: command not found
logoutWhat are you attempting to do?
-
We developed a web site,There are file upload function.
Web site running on the NetWeaver
Can upload .rar .pdf .bin files. But when upload Excel file ,It Often failed,Occasionally, the success of.
I have imp notes for update sevletinputstreamreadtimeout parameter, now it is 180000.
Pls help meHi,
I have had issues with sporadic document upload problems. There are several SAP notes. Primarily there is an issue with Internet Explorer and keepalive timouts. Try each/all of these three options.
1) Examine the keepalivetimeout settings (see SAP note 900804)
2) Examine MaxRequestContentLenght setting (see SAP note 898637)
3) Ensure that your Temporary directories for the J2EE server are set correctly use the Config Tool to add new parameters
-Djava.io.tmpdir=[a suitable temp directory ([SID]ADM user needs read write acces)]
-Dcm.tmpdir=e:\EP_TEMP (example) (see SAP Note 898637)
Hope this helps
Regards
Alex
Maybe you are looking for
-
Very frustrated with new layout of discussion forums... How do I search key words within threads within a specific support community? For Example I want to search the phrase 'couldn't collect' within the Apple Remote Desktop community.
-
Can I recover pictures erased in my iPhone ?
I want to recover some pictures erased from my iPhone
-
How to search more than one table in database?
Hello i am new to java I create 5 tables. I want search 5 table. I use stored procedure. we give one keyword that keyword in all tables that column will be display. for ex: One tables contains IT employee details of one company and they are working d
-
Protect images / content in PDF...
Hi, How can I set up securities to protect copying of images / general content of a PDF? I went through the settings in Acrobat, but could not find what the name of this feature is. Thanks!
-
F-02; Discount Amount, where can it be seen and What does it Affect?
Gurus, Customer is given Posting key 14; discount too is also given 5% of the amount. But when simulated; the discount amount is not shown. Where to see it?