|
Home >> FAQs/Tutorials >> Oracle DBA FAQ
Oracle DBA FAQ - Introduction to Command-Line SQL*Plus Client Tool
By: FYIcenter.com
Part:
1
2
3
4
5
6
7
8
9
(Continued from previous part...)
What Are SQL*Plus Environment Variables?
Behaviors of SQL*Plus are also controlled a some environment variables predefined on the
local operating system. Here are some commonly used SQL*Plus environment variables:
- ORACLE_HOME - The home directory where your Oracle client application is installed.
- PATH - A list of directories where SQL*Plus will search for executable or DLL files.
PATH should include $ORACLE_HOME\bin.
- SQLPLUS - The directory where localization messages are stored.
SQLPLUS should be set to $ORACLE_HOME\sqlplus\mesg
- TNS_ADMIN - The directory where the connect identifier file, tnsnames.ora is located.
TNS_ADMIN should be set to $ORACLE_HOME/network/admin.
How To Generate Query Output in HTML Format?
If you want your query output to be generated in HTML format, you can use the "SET MARKUP HTML ON"
to turn on the HTML feature. The following tutorial exercise gives you a good example:
SQL> connect HR/retneciyf
SQL> SET MARKUP HTML ON
SQL> SELECT FIRST_NAME, LAST_NAME, HIRE_DATE
<br>
2 FROM EMPLOYEES WHERE FIRST_NAME LIKE 'Joh%';
<br>
<p>
<table border='1' width='90%' align='center' summary='Script output'>
<tr>
<th scope="col">
FIRST_NAME
</th>
<th scope="col">
LAST_NAME
</th>
<th scope="col">
HIRE_DATE
</th>
</tr>
<tr>
<td>
John
</td>
<td>
Seo
</td>
<td>
12-FEB-98
</td>
</tr>
<tr>
<td>
John
</td>
<td>
Russell
</td>
<td>
01-OCT-96
</td>
</tr>
</table>
<p>
(Continued on next part...)
Part:
1
2
3
4
5
6
7
8
9
|