But due to a problem with console window prior to Windows 10, note2 you should set linesize to 1 less than window size, e.g., 187.
Since we widened our sqlplus console window in the last step to, say, 188, we should make full use of it. I prefer 100 (except in case of very wide tables such as some Oracle Applications AOL tables, where select * repeats headers too often even with pagesize 100).
The reason you want the Sqlplus screen as wide as you feel comfortable is so that you'll have less cluster in the query output.ĭefault pagesize 14 is absolutely inadequate. Set Height for Screen Buffer to 2000, or at least 1000. On my 19-inch monitor using 10-point Lucida Console font, I can get 188 in screen width. Under Layout, set Width for both Screen buffer and Window sizes to the same number, I would say at least 100, up to the full width of your screen, but make sure the vertical scroll bar is still visible near the right edge and no horizontal scroll bar is shown at the bottom. I like Lucida Console, and not Bold version of it. Under Font, choose a small font but not too small to your vision. (If you see somebody send an image of Sqlplus text, you know he/she is very computer un-savvy!) Check QuickEdit mode and Insert mode checkboxes. You can adjust Red, Green and Blue to fairly high numbers to get your favorite light color, such as 200-255-200 for light green, 255-255-200 for beige, etc. You'll find that the text in the second window looks much clearer and you can read faster. Make sure text font is exactly the same in size and face. Trust me on this advice! Do an experiment with two console windows, one with white text in black background and the other with black text in white or light color background (see below). I strongly suggest you choose black for Screen Text and very light color or white for Screen Background. In Properties window for this shortcut, go to Colors tab. Screen colors are probably the most important in terms of ergonomics. If you want to launch it even faster, set a shortcut key for it. Once this shortcut is there, you can quickly launch Sqlplus by going to Start -> Sqlplus. I normally set "Start in" folder to somewhere other than the default %oracle_home%\bin, such as d:\temp, so a spooled file goes there by default.
If you think too many environment variables should be set, put them in a batch file and call the file on this command instead. not wanting to set it in Control Panel, the command will be: cmd /k set oracle_home=d:\oracle\product\11.2.0\db_2& set oracle_sid=orcl& d:\oracle\product\11.2.0\db_2\bin\sqlplus (adjust paths as needed). If for any reason you need to set oracle_home and oracle_sid just for running this sqlplus, i.e. (On Windows 10, pin the shortcut to Start menu.) So you can still see the result on screen. Also note Windows XP uses a different path, C:\Documents and Settings\ user\Start Menu.) So the shortcut target may look like this:Ĭmd /k d:\oracle\product\11.2.0\Db_2\bin\sqlplus.exeīecause of cmd /k, if you exit sqlplus, sometimes accidentally by ^C, the console window remains open instead of closing itself. (I use %oracle_home% notation to refer to your oracle home folder. In Windows Explorer, at C:\Users\ user\AppData\Roaming\Microsoft\Windows\Start Menu\Programs (where user is you or "All Users" you need to manually type AppData in the path since it's hidden), create a shortcut named for instance "Sqlplus" pointing to %oracle_home%\bin\sqlplus.exe, and prepend cmd.exe /k.
I assume your desktop OS runs Windows 7 unless otherwise noted. This article summarizes some tips you may find useful in using the console version. With Oracle11 g, the Windows version is no longer available, making the console version more than just appealing, but essential. note1 The feature that brings the greatest convenience is probably being able to press UP key to recall previous commands. Sqlplus command line or console version is actually more powerful and efficient than its Windows or GUI version.
How to Setup Sqlplus for Most Efficient Use on Windows