How to view and current directory to run an SQL script
HelloQuestions about a few simple things in sql command line plusent, but they are really hard to find in the documentation:
1. is there an easy way to set an environment variable changing a working directory where a script is running?
2. How can I view path environment?
Kind regards
Valerie
SQLPATH? Example:
C:\>type \tmp\test.sql
select 1 from dual;
C:\>sqlplus test/test
SQL*Plus: Release 10.2.0.1.0 - Production on Fri Aug 28 11:47:56 2009
Copyright (c) 1982, 2005, Oracle. All rights reserved.
Connected to:
Oracle Database 10g Express Edition Release 10.2.0.1.0 - Production
SQL> @test
SP2-0310: unable to open file "test.sql"
SQL> exit
Disconnected from Oracle Database 10g Express Edition Release 10.2.0.1.0 - Production
C:\>set SQLPATH=c:\tmp
C:\>sqlplus test/test
SQL*Plus: Release 10.2.0.1.0 - Production on Fri Aug 28 11:48:19 2009
Copyright (c) 1982, 2005, Oracle. All rights reserved.
Connected to:
Oracle Database 10g Express Edition Release 10.2.0.1.0 - Production
SQL> @test
1
----------
1
SQL>
Tags: Oracle
Similar Questions
-
How to view and print PDF files
How to view and print PDF files
Hi daniel Meyer
You can use Adobe Reader... It's a free app. You can view and print your PDF files using this.
If you want to edit and create new PDF files, please purchase the Adobe Acrobat software.
Please, see: http://get.adobe.com/uk/reader/otherversions/
-
Compensation of the sequences, run the sql script
Hello
I use OWB 10.1.0.4.0 and I use a sequence to create a surrogate key in my paintings. For the tabels deleted during the process, I want these sequences set to 1 again.
Is it possible to run an sql script in a mapping or the flow of process (with a drop, create, grant the declaration for the sequence)?
Thanks in advance,
ArjanWrite these SQL statements in a procedure and the procedure in the import map.
-
I choose the computer name of the machine running a SQL script
Hello. I am looking for a way to select the computer name of the machine running a SQL script. Is this possible?
I tried the following, but it does not work. Any suggestions?
Select % computername % of double;http://www.Oracle.com/technology/oramag/code/tips2003/011903.html
Check this link see if it helps.
Concerning
REDA
-
Running PL/SQL scripts...
Hello:
I'm new to PL/SQL and am learning by writing that a few basic Queries.I using TOAD as a tool to write queries I got stuck in this query I posted below.
Here I have a table with data.
EMPLOYEE_ID SALARY BONUS
----------- ---------- ----------
90-1000
100 2000
110 1890
130 2132
120 1255
I wrote a query which take the value from the table (of particular employee_id) salary and multi with 0.01 and once again will store in the variable bonus (so far everything works fine).
but when I execute the script with the function to update its time consuming process (ends without result).
DECLARE
bonus NUMBER (8.2);
emp_id NUMBER (6): = 100;
BEGIN
SELECT salary * 0.10 IN bonus
Employees
WHERE employee_id = emp_id;
dbms_output.put_line (bonus);
update set employees.bonus = bonus employees where employee_id = emp_id;
END;
I tried the same thing through the sql-plus tool.
I stored the file above in note ++ (.sql extension) and through sql-plus I tried to run
SQL > @[path] [file]
but this does not work please help me in this. Please help me solve both ways...
See you soon...
It shouldn't take long at all.
SQL > create table emp2 in select * from emp;
Table created.
SQL > ed c:\give_bonus.sql
In my case, I have...
>
declare
number of bonuses;
emp_id number: = 7788;
Start
Select sal * 1.1
as a bonus
from emp2
where empno = emp_id;dbms_output.put_line ('Sal with bonus: ' | bonus);
Update emp2
Sal value = give_bonus.bonus
where empno = emp_id;commit;
end;
/And then again in SQL * more I call it...
SQL > set timing on
SQL > @c:\give_bonus.sql
SAL with bonus: 3300PL/SQL procedure successfully completed.
Elapsed time: 00:00:00.03
Very fast.
Perhaps you lack the ' / ' the end of your script that tells SQL * Plus to run the code? And he's sitting there waiting for input?
-
How to view and monitor running tasks?
I need to be able to monitor a running task, and it does not work:
While ($clntask.Info.State - eq 'running' - or $clntask.Info.State - eq "pending")
{
$clntask = get - see $clntask. MoRef
Write-Host "on hold".
}
I'll assume that you used a SDK method to start the task.
I'll take the method of ExitMaintenanceMode_Task for example.
*) the SDK .. ._Task methods return a MoRef (a kind of pointer) on a Task object.
*) to get the task of object properties use us the cmdlet Get-view to get a copy of the actual object of the task
*) we check the property which gives the status of the task. The State can be: error in waiting, running or success.
*) If the status is "running" or "pending" wait US 2 seconds and get a new copy of the Task object. The VI will not update the properties of our copy of the Task object
*) Where the State is not 'running' or 'pending' out us the while loop
...... $taskMoRef = $esx.ExitMaintenanceMode_Task(0) $task = Get-View $taskMoRef while ($task.Info.State -eq "running" -or $task.Info.State -eq "queued") { sleep 2 $task = Get-View $taskMoRef }
Just saw your response. My comments are still valid.
-
How to view and control a VI remotely from a web browser
Hello
I want to see and order a vi using a web browser.
I followed the steps recommended in the help, and I can see and order the front of my vi.
So far, everything is OK.First problem:
A button activates a simple storefront a message (a dialog box button). The dialog box opens on the server computer, but cannot be seen in brouser, and can not be closed remotely.The second problem:
Another button activates another window (vi) loaded dynamically. The reentrant VI, is open with option 0xC0 ('Enable simultaneous calls on reentrant VIs' and "Ready to call and forget"). By clicking on the button, it opens multiple instances of the VI properly and is running on the server computer, but is not visible on the client computer.
I created, once the same algorithm, the HTML file corresponding to the dynamically loaded VI and it was recorded at the same place with the main HTML file of the program.What to do what the client computer can operate main VI and the adjacent windows in the browser?
Thank you
CristianYou can't if you use remote façade panels - they do not allow for additional/popup windows. You must rewrite your VI to include everything on the main façade.
-
How to view the current EQ settings?
Is it possible to display the parameters of frequency of an audio clip using Audition? We recorded a project with a blue snowball, using Adobe Captivate. But on some slides someone changed settings (from '1' to '3') at the back of the microphone, then a few slides sounds a little muffled. I used the parametric equalizer to boost the higher frequencies, and I am able to get the sounds to match a little better by doing this. But I was wondering if maybe there is an easier way just to match the frequency of the audio clips, or may display Equalizer/frequency of each clip settings I can adjust manually them as close as possible?
If you use the frequency analysis window, you can see differences in response. If you select a section, scan and store in one of the memories, select another section and that scan and save, you will be able to see what are the differences between them, which should allow you to make adjustments more accurately than by listening on average.
There are a few autour plugins that will allow you to corresponding EQ so that might help. He runs the process I described above, only it automates it so that the EQ on the section you want to change is the "reference" EQ from a file of your choice. It's expensive, but Ozone can do that. An alternative, which is a little cheaper, is a program called "Hebert" which is specially designed to match sound settings exactly - but until you get used to it, it's a bit of a pain to use. And I'm sure that there are others also.
-
How Illustrator 32 and 64 bit can run in different languages twoo?
I have a subscription to creative cloud. My OS is a Danish version of W7. I want Adobe programs run in English. I put the handler appliczation language preferences to English and it works in some cases but not always. For example, 32-bit Illustrator works perfectly in English, whereas the version 64-bit show all menus and dialogs in Danish. Is it possible to fix this?
Go to/Applications/Utilities/Adobe install and uninstall Illustrator. Download/update Application Manager and install Illustrator by changing the preference of the Application Manager to English and it should appear in English.
AAM Mac: http://www.adobe.com/support/downloads/detail.jsp?ftpID=4774
-
How to view and move an object in mxml, as a project of the Ball.as file
Hello
I want to set up a ball (and later, I will propose), in my mxml project.
I created a class Ball in the Ball.as file
I've referenced it in my MXML project in < mx:Script >
public var myball:Ball = new Ball();
//------------------------------------------
public function putUpTheBall():Sub
{
myball = new Ball();
addChild (myball);
}
I have also: mx:Button click = "{putUpTheBall ()}" / >
When I click on the button, I get:
TypeError: Error #1034: Type coercion failed: cannot convert Ball@5b63381 to mx.core.IUIComponent.
It's the addChild() which creates the runtime error.
How can I see the ball?
(BTW, I had no problem with this in an actionscript project).
-Jean
You must wrap the ball in a UIComponent, then add:
ball: ball of var = new Ball();
var uic:UIComponent = new UIComponent();
uic.addChild (ball);
this.addChild (uic);
If this post answers your question or assistance, please mark it as such.
-
How to view and delete certificate exceptions that I did.
Accidentally, I clicked on 'Add exception' a Web site certificate error and want to reverse that.
You should see this exception in the certificate on the servers tab Manager.
- Tools > Options > advanced > certificates: display certificates
Leave no permanent you see here because they are there for a reason.
-
Why google everywhere and current firefox to run, fox is set def browser
Google is in 2 different locations with search engine, and when I put a site in the browser bar, say, craigslist, hit enter or click on the arrow. Google displays the results. Firefox default put in the computer and browser settings. Yet I see and get more google, Firefox, on everything. I tried troubleshooting takes also note ect. Thank you
Hello
Google is the search engine by default when you install Firefox. You can change this in your search bar - or click on the Google icon, or press the arrow down and select a different search engine.
For more information, see using the search bar in Firefox
EDIT: When you change the search engine in the search bar, this will change all other search bars in Firefox to use the new search engine - I guess in your post the second place you saw Google was on the Start Page of Firefox.
-
How to get the current URL to run in actionscript
Hi all
I try to get implementation actioscript URL,
Please give me a way to do it.
Thanks in advance,
Prashant Shelke.You can use stage.loaderInfo.loaderURL to get the URL from which the SWF file has been loaded.
-
How to escape the quotes when I run the .sql Unix script
Hello
I have a ddl script files...
to keep specific information from the environment, I use a placeholder $variable (for example, the names of patterns etc.)
and creating a document and say the dba this export variable = value.
Use of variable for the following cases?
CREATE DATABASE LINK "abc.ge.com".
CONNECT TO $SRC_SCHEMA_NAME
IDENTIFIED BY $SRC_SCHEMA_PWD
With the HELP of 'abc.ge.com '.
I want to create a varaiable with value abc.ge.com How can I do this from the command have single and double quotes...
Thanks and greetings
REDAYou don't need quotation marks in your CREATE DATABASE LINK statement. Just leave and forget any of this escape.
Are you sure you must export all these variables, i.e. will they be mentioned in sublayers without be passed as parameters?
-
Hi, I would like to ask how to view the current settings of the sequence, I'm already working the same information that is displayed when you open for the first time a new sequence
for example.
General
Editing mode: QuickTime DV PAL
Time Base: 25.00fps
Video settings
Image size: 720: 576v (1.4587)
Frame rate: 25.00 FPS
Format of the pixels: PAL D1/DV widescreen 16:9 (1.4587)
Fields: Bottom field first
Audio settings
Sample rate: 48000 samples/second
Default sequence
Total of the video tracks: 3
Master the track type: stereo
Audio tracks:
Audio 1: Standard
Audio 2: Standard
Audio 3: Standard
I forgot what setting I chose for my current sequence and tried to look under project settings , as well as the sequence settings
but do not show the news that you see when you open a new sequence for the first time, especially if the edit mode is PAL or NTSC etc.
How can I find this information which my current sequence is on?
Thank you
Sequence / sequence of setting you will find all the information.
If his pal, you're on 25 or 50 fps.
the rest is ntsc.
Maybe you are looking for
-
I can't get new tabs to open using the key ctrl + T command or the plus sign to the right of the open tab. It seems that the tabs have been disabled because I can't open new tabs.
-
Pavilion of locking up at shutdown
Hi, I am having my first ever problem with my laptop and I hope someone can help me solve this problem. The laptop was closed using the usual routine hutdown and poster display "stop". It was assumed that the machine would be closed as usual and it w
-
Re: Satellite A210-1This PSAELE - I need XP drivers
I need driver XP for Satellite A210-1This PSAELE, be cause I have a lot of Pentecost problems Vista OS. Thank [email protected]
-
Why do I receive error code 8007045d why install updated vista sp1
title says it all
-
Windows Update for IE changed my home page and gave me three commercials
How am I suppose to trust Windows Update for important updates in the update important that I just installed changed my home page in Internet Explorer and gave me three pages of ADVERTISING instead. What kind of scam unsolicited is?