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...
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...
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...
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
Hello,
Though I have read the the docs over and over, I cannot determine how to place more than one COL\FORMAT command on one line in a standard .sql script to be run from SQLPlus.
[COLOR=blue]
COL emp FORMAT a20
COL location FORMAT a10[/color blue]
Using a semi-colon between entries does...
Hello,
First off, thanks to everyone here for being so helpful in me getting up-to-speed in the strange new UNIX world! :-)
In a Bourne shell script I have a variable that contains a number (ex: 1049312). This number is in bytes and I'd like to make it more readable for my output. Ex...
Hello all,
In a Bourne shell script I need your advice please on how to get some Sun UNIX system information. My goal is to set each item into a Bourne shell script variable.
Items Checking For:
* CPU Load (current_idle_time)
* Total RAM
* Available RAM
What can you recommend?
Thanks,
JT
Hello,
I know an alert log is a physical text file. I was hoping, as in many things in 10g, there are SQL routes to get to the information.
Is is possible to use SQL (v$ or dba views etc.) to obtain the information in a alert log?
If not, is there a way I can use pure SQL to tell me if...
Hello,
In a Bourne shell script I have a variable length string that is enclosed in parenthesis.
Examples
echo "$CONN1" (2msec)
echo "$CONN2" (10msec)
echo "$CONN3" (100msec)
How can I get ride of the parenthesis?
Thanks,
JT
Hello,
I just purchased a Sun Ultra 25 (it arrived today yeah). I only have a VGA monitor (ViewSonic A70 17") but the Ultra came with a DBI display card (XVR-300) and cables.
What do I need to get this card to work with my monitor?
Thanks,
JT
Hello,
In a table if I am outputting long text entries it will bleed out the side of the control rather than wrapping. I have tried multiple tags unsucessfully (<p>, <div> <table>...<td> etc.). I'll use whatever works.
How can I get a long paragraph of text to wrap in CSS 2.x in both IE and...
Hello,
In an Oracle 10g R2 database in a VARCHAR2(2000) comments field I need to replace all single quotes with their ASCII values before INSERT\UPDATE and also replace it back again when displaying.
Can someone please provide a PL/SQL code snippet to achieve this?
This one has me stumped...
Hello,
In an Oralce 10.2 R2 (10.2.03) database on a Solaris 10 system we are randomly getting ORA-12805 errors (ORA-12805: parallel query server died unexpectedly). We are not using RAC. Also, on both the tablespaces and effected tables the Parallel option is not enabled.
Corresponding /udump...
Howdy!
I would like to create a black box function that retreives a cursor by passing it basic SQL and then be able to use it in a FOR LOOP. Performance is not a concern (very small tables). Standard Oracle rules seem to dictate that you have to at least know\declare a table name if you want...
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.