Hello,
On Sun systems I can easily run SQLPlus commands\session from a UNIX shell script as show below:
$ORACLE_HOME/bin/sqlplus "/ as sysdba" << SQLPLUS_SESSION
SELECT * FROM emp;
exit
SQLPLUS_SESSION
I am clueless how to do this in a Windows 2000 standard batch file (.bat). I have been...
Hello,
I need to ensure my new database has a password file.
When the DBCA is run to create a database is a password file automatically created or do I need to manually create one using orapwd file=orapwMYDB password=secret?
Thanks for confirming,
JT
Hello,
On a Sun Solaris systen from a Bourne shell script I have several static lines (35) of text that I need to store in a variable.
The hard way would be like:
VAR="Line 1"
VAR="$VAR Line2"
VAR="$VAR Line3"
...
Or perhaps outputting it into a file then into a variable.
I think what I am...
Hello,
I use the following SQL to determine how often a Redo Log Switch occurs:SELECT group#,status,first_time FROM v\$log ORDER BY group#;
Can someone recommend SQL that takes this a step further and actually determines the average log switch interval time for the last n hours (say 24)?
I...
BillyRayPreachersSon, BabyJeffy,
That was very helpful. Simple and effective. :-)
One comment please. I noticed you did not place the p {..} tag in the same main grouping as the body, th, td tags.
Why is that?
Thanks again,
JT
Hey all,
I am wondering if I can cut down on my CSS via efficient use of inheritance. My goal is for my CSS 2.x to work with IE5+ and Mozilla 1.6+. If I can get rid of all my font-family: arial; tags for starters that would be great. Given my below example which ones do you think I can...
Hello,
I have a Bourne shell script that uses a small text file (example below). How can I re-order each of the lines in reverse order and write out to another file?
Original File Contents
A xxxx xxx xxx
B xxx xxx
C xxxxxx x
D xxxxxxxx
Desired File Contents
D xxxxxxxx
C xxxxxx x
B xxx...
Santa, Engineer2100,
Thanks for the response. I agree with Engineer2100. If this was a basic question you are right on.
You know the answers you get here or anywhere are only as good as the question. I am embarrassed to say I left out a vital piece of info. My table is an External table...
Hello,
I need to retreive the last 25 rows of a log table that does not have an index and do it using one SQL command.
I can get the first 25 using this:SELECT text FROM scott.alert_log WHERE rownum < 25
I tried getting the last 25 using this SELECT text FROM scott.alert_log WHERE rownum >...
Hello,
In a Bourne shell script I have some variables ($SYSTEM, $STATUS, $CONNECTIONS,$STARTUP_TIME etc.) that I want to print to the console output in a symetrical way. I want the values to line up with the column headers.
System Status Connections Startup...
engineer2100,
>> Why do you want this comment in the first place?
We want to include some brief comments on the role of the database in all our 10g databases in a standardized way.
We want to try to use the resources commonly available in all our 10g databases to do this, i.e. we want to...
>> In Oracle ( as in most databases) that is normally a Table,
Yes - I agree. :-)
The core of what I am asking is, how can I do this with the most minimal introduction of custom changes?
Is there a (practical) place in the control file? Is there a table in SYSAUX that I can use etc.?
If I...
Turkbear,
>> If you want a comment ABOUT the database ( actually the
Instance, I assume),
Cool suggestion. Thanks.
What I still dont know is: Is there a place in a database instance where I can embed some brief comments WITHOUT creating a custom table of my own to do so?
Thanks,
TJ
Hello,
This could be tricky to explain so I'll present it this way:
Here is what I am NOT looking for:
* Putting comments in any kind of code (SQL, Java etc.).
* Putting Hints in SQL commands.
* Using the schema COMMENT property to add notes about it.
Here is what I am looking for:
* I want...
Hello,
In 10g what SQL can I use to list all my tablespace:
1. Names
2. Sizes (in bytes or megabytes)
3. Used (in bytes or megabytes)
Percent used or free would be fine too.
Thanks,
JT
Dagon, Ken,
Yep, I am firing SQL (and SQLPlus) from a shell script.
In most language you can place multiple commands on one line. As a rule of thumb, of course, this is something you do not want to abuse.
Can it be done?
If not I guess I can put my FORMAT commands in a .login or .glogin...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.