History:
again <pattern>
alias: ! rerun
latest matching entry
history <pattern>
alias: hi show
history items matchin pattern (or all)
rerun <nr>
alias: !! run
history item nr
DataDictionary:
recompile <type/name>
alias: rec recompile
objects -a Do all objects, even with a dollar
-i Do invalid objects only
refs <table>
print referential integrity
find <pattern>
find
a line in user_source -i search case
insensitive
deps <name>
object dependencies -U
Print uses insted of dependencies -r List
dependecies recursively
pull <type/name>
pull
code of procedures etc. -a Pull all objects,
even with a dollar -A NOT IMPLEMENTED -f file
Save result in file -F Save each object in individual
file -e edit code in _editor -q Don't
print to the screen
ls <type/name>
list all objects matching pattern
-a List all objects, even with a dollar -l
List validity of objects too -C List constraints etc
too -I List indexes etc too -i List
invalid objects only
set ddView <''|user|all>
switch between user and all views in DataDictionary
Bind:
print <name>
alias: p print a bind variables -a
list all variables
variable <name type>
alias: var declare a bind variable
-s value set value right away
Tuning:
show parameter <pattern>
alias: sp show init.ora parameter
ps <>
print session information
-l print long format -s s1,s2.. only show given sids
-p pattern only "matching" sessions
waits <>
show what sessions are waiting for
-s s1,s2.. restrict to SIDs
validate <index>
alias: vi validate structure an index
analyzeObject <pattern>
alias: ana analyze a table or an index
-c compute instead of
estimate -t days only if not analyzed days ago -n
only show objects, don't analyze -d delete
statistics
rollSegs <>
print rollback info -u
print currently used segments with SIDs
kill <sid>
kill a session
space <>
show space -t
show tablespace stats -d show datafile stats -D
show resizable datafiles -b blksz assume blocksize
for -D -e n show top n extent consumers -s n
show top n space consumers
hwm <table>
get high watermark info on analyzed tables (experimental)
xplain <>
explain plan for statement
-f file take statement from file -v echo
statement -c only create plan table
jobs <>
print job information -l
Print long format -p pattern Print only jobs with
matching "what" -r Print only hanging,
running or broken jobs
profile <> (cool !)
estimate current execution times
-s sids restrict to sids -c create required table
senora_profile -i iterationsset sample size (100) -t
msecs set sampling time (50)
resize <>
resize datafiles -m
Mbytes limit to at least Mbytes space reclaimes (50) -f
force: dont ask
kept <>
show kept (pinned) code
-p pattern restrict by pattern -n show non pinned
xqueries <>
alias: xq show most expensive quieries
-n rows show top n rows -i check increase agains
copy of v$sqlarea -s create a snapshot of v$sqlarea
for -i -p pattern print only statements matching pattern
-R order by reads -X order by reads/xl
-N order by execs + loads
cstatement <>
alias: cs show the current statements of sessions -u
user limit to a given user -s s1,s2.. limit to a given
SIDs -p show previous statement
stat <>
print session statistics
-s sid The sid to stat -p pattern pattern to match the
statname -a also show values=0 -l limit only
show values > limit
locks <>
show sessions and the objects the are waiting for
PluginMgr:
set pluginCode <OFF|ON>
always show SQL code of plugin before executing
unregister <plugin>
unregister a plugin
help <pattern>
alias: he provide help for a command
-v print more help
register <plugin>
register a plugin (will always reload file)
SessionMgr:
disconnect <sessionNr>
alias: dis disconnect session nr
connect <connectString>
alias: senora|conn|c create a new session
-a create additional session, don't disconnect -l
list connections -s sessNo switch to sessNo (as
reported by -l)
quit <>
alias: exit|q exit Senora.
Sqlplus:
show user <>
alias: id show the current username
describe <object>
alias: desc|d describe a table or command
prompt <args>
echo arguments
purge <table where ...>
delete from (large) table in chunks
-n 1000 chunk size -i 1000 max iterations -q
be quiet
exec <psql>
run a single line PL/SQL
cd <cmd> (yeah)
change directory
count <pattern>
count rows of tables
pwd <>
alias: cwd|dirs show current directory
define <name=value>
define a value for later reference
-l list defines
spool <file>
alias: spo write to file
column <name format ann>
set column format -l
list formats
grep <pattern table [extra clause]>
show rows that match pattern
-v show rows that don't match pattern -i
ignore case
head <table>
show first rows of table
-n rows set number or rows to show
set serveroutput <on|off>
alias: so get dbms_output messages -b
bufsz set the buffer size
cat <table [extra clause]>
synonym for select * from
-a don't stop after 3000 rows
list <>
alias: l list last sql/plsql statement
show errors <>
show compilation errors
host <cmd>
execute os cmd
dir <pattern>
list directory
MainLoop:
startRel <args>
alias: @@ run an sql script relative to a running script
set verify <OFF|ON>
print ampersand replacing
start <args>
alias: @ run an sql script
|