exp [merged 2 old threads by JD] [message #668284] |
Fri, 16 February 2018 06:39 |
shahzad-ul-hasan
Messages: 640 Registered: August 2002
|
Senior Member |
|
|
declare
Fil varchar2(150);
begin
fil:='D:\accounts\';
Host('Exp accsch/abc file='||fil||'Acc'||sysdate||'.dmp');
exit_form;
end;
The above code is working properly. but i have reinstall the oracle XE. the following line i received.
Quote:
Export done in WE8MSWIN1252 character set into and AL16UTF16 NCHAR character set
Export done in AR8MSWIN1256 character set into and WE8MSWIN1252 (Possibly convertsion set)
how i can fix this error.
Quote:
Host('Exp accsch/abc file='||fil||'Acc'||sysdate||'.dmp statistics=none'); ---to solve problem.
i want to not use statistics. have this any operation on dmp file. ??????
and without (statistics) this dmp is ok for import.??? advised.
[Updated on: Thu, 16 May 2019 08:18] by Moderator Report message to a moderator
|
|
|
Re: exp [message #668285 is a reply to message #668284] |
Fri, 16 February 2018 06:42 |
John Watson
Messages: 8962 Registered: January 2010 Location: Global Village
|
Senior Member |
|
|
Quote:The above code is working properly.
Really?orclx> declare
2 Fil varchar2(150);
3 begin
4 fil:='D:\accounts\';
5 Host('Exp accsch/abc file='||fil||'Acc'||sysdate||'.dmp');
6 exit_form;
7 end;
8 /
Host('Exp accsch/abc file='||fil||'Acc'||sysdate||'.dmp');
*
ERROR at line 5:
ORA-06550: line 5, column 2:
PLS-00201: identifier 'HOST' must be declared
ORA-06550: line 5, column 2:
PL/SQL: Statement ignored
ORA-06550: line 6, column 1:
PLS-00201: identifier 'EXIT_FORM' must be declared
ORA-06550: line 6, column 1:
PL/SQL: Statement ignored
orclx>
|
|
|
|
|
|
|
Re: exp [message #675966 is a reply to message #675951] |
Thu, 02 May 2019 06:59 |
cookiemonster
Messages: 13961 Registered: September 2008 Location: Rainy Manchester
|
Senior Member |
|
|
Use || to add variables to a string
host ('exp '||user||'/'||password||' @xe file=d:\backup\'||filename);
Though you'll have to make the user re-enter the password into a form item so you can get the value.
|
|
|
|
|
|
|
Re: exp [message #675979 is a reply to message #675978] |
Fri, 03 May 2019 03:22 |
cookiemonster
Messages: 13961 Registered: September 2008 Location: Rainy Manchester
|
Senior Member |
|
|
As Michel says host is a forms built-in that takes a string and runs it on the command line.
You need to take the string you are passing as the parameter to host and run that manually.
Also you don't need to select user from dual, you can just use user directly.
|
|
|
|
|
|
|
|
|
Re: exp [message #676009 is a reply to message #676005] |
Mon, 06 May 2019 12:09 |
|
Michel Cadot
Messages: 68728 Registered: March 2007 Location: Saint-Maur, France, https...
|
Senior Member Account Moderator |
|
|
Quote:2. Password is static for and same for all users... it will be hard coded....
3. There is no security risk....my password is xyz for all my users....
[Updated on: Mon, 06 May 2019 12:10] Report message to a moderator
|
|
|
Re: exp [message #676013 is a reply to message #676005] |
Tue, 07 May 2019 03:06 |
cookiemonster
Messages: 13961 Registered: September 2008 Location: Rainy Manchester
|
Senior Member |
|
|
M HANIF wrote on Mon, 06 May 2019 09:34
3. There is no security risk....my password is xyz for all my users....
That is a security risk.
If you're going to live with it then all you need to do is debug your host command in the way we already described and fix it appropriately.
|
|
|
|
|
Re: exp [message #676018 is a reply to message #676014] |
Tue, 07 May 2019 04:04 |
cookiemonster
Messages: 13961 Registered: September 2008 Location: Rainy Manchester
|
Senior Member |
|
|
You need to learn how to debug your own code.
Assign the string of text you are going to pass to host to a variable.
Display the variable on screen (assign it to a datablock item then you can easily copy it).
Copy the text and run it directly on the DB server.
See what error you get.
Fix the exp command so that it works.
Fix the forms code so that it makes a string that works.
If you can't work out what's wrong with it paste the command you are trying to run here along with the error message you get on the server.
|
|
|
|
Re: exp [message #676139 is a reply to message #676005] |
Wed, 15 May 2019 12:25 |
joy_division
Messages: 4963 Registered: February 2005 Location: East Coast USA
|
Senior Member |
|
|
M HANIF wrote on Mon, 06 May 2019 04:34
1. Yes forms software is running on the same DB Server....
Somehow I doubt this.
What version of forms are you running? What you are saying is that it is either not multi tier or you have the Weblogic server on the same server as the database server. If it's the former, you would most likely not have export commond on your PC and if it is the latter, I never heard of a situation where the DB and Forms Server are n the same server.
|
|
|
|
|
Re: Executing imp command through a form [message #676595 is a reply to message #676145] |
Fri, 21 June 2019 01:41 |
|
M HANIF
Messages: 20 Registered: April 2019
|
Junior Member |
|
|
cookiemonster wrote on Thu, 16 May 2019 04:47does get_application_property(password) actually return anything?
What exactly did you try in the host call?
Really Thanks & best regards to all of you.
From your kind reply & guidline. I ultimately became able to create backup with when button pressed trigger!!!
I'm really glad & happy to see the result.
Nice work.
Thanks to all of you once again!
[EDITED by LF: removed huge bold formatting and superfluous commas and dots]
[Updated on: Fri, 21 June 2019 06:12] by Moderator Report message to a moderator
|
|
|