Why not just script the kill session as a step right before the drop user statement?
select 'alter system kill session ''' || sid || ',' || serial# ''''
from v$session where username='JOE';
drop user joe cascade;
?
Todd
>
> --=__PartB899705F.0__=
> Content-Type: text/plain; charset=US-ASCII
> Content-Transfer-Encoding: 7bit
>
> I am looking for a command that will drop a user even if they have an
> open connection at the time.
>
> We are using Oracle 8.1.7.4 on AIX. Part of the process is to refresh
> the training environment from production, but we are hitting a problem
> with DROP USER JOE CASCADE; in the script that runs early in the morning
> if 'Joe' has a connection.
>
> DROP TYPE FORCE command is about what I am looking for, but I don't see
> that it can be applied to a user, only to user-objects.
>
> One alternative is to script a SHUTDOWN IMMEDIATE; STARTUP; as we really
> don't have anything else running on the test instance that needs to
> remain up, but I am REALLY leary of scripting database shutdowns.
>
> Thanks for any help...
>
> Walt
>
> --=__PartB899705F.0__=--
>
Oracle LazyDBA home page