Script to permanentently change hostname, IP address and DNS client configuration.
http://www.sun.com/bigadmin/scripts/submittedScripts/chhostname.ksh.txt
Wednesday, April 16, 2008
Sunday, April 13, 2008
Broken snapshots - repair
exec dbms_job.broken(218, FALSE, NEXT_DAY(SYSDATE, 'SUNDAY'));
commit; --- DONOT FORGET TO COMMIT
This will make the broken job again active, setting the next schedule date.
If you want to execute the job immediately to refresh the shapshot, use dbms_job.run(218)
commit; --- DONOT FORGET TO COMMIT
This will make the broken job again active, setting the next schedule date.
If you want to execute the job immediately to refresh the shapshot, use dbms_job.run(218)
Export GRANTS on tables a particular user has made
#!/bin/ksh
sqlplus -silent /nolog<<eof
connect / as sysdba
set serveroutput on
SET HEAD OFF
SET PAGESIZE 0
SET FEEDBACK OFF
SPOOL /tmp/privs_exp.sql
SELECT 'GRANT ' || PRIVILEGE || ' ON ' ||OWNER||'.'||TABLE_NAME|| ' TO '||GRANTEE|| DECODE(GRANTABLE, 'YES' , ' WITH GRANT OPTION', ' ' )||';' FROM DBA_TAB_PRIVS WHERE GRANTOR IN ('NP_TRIAL', 'NAVEEN', 'TOAD');
exit;
eof
Subscribe to:
Posts (Atom)