Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion Groups
Database Servers
DB2InformixIngresMS SQLOraclePervasive.SQLPostgreSQLProgressSybase
Desktop Databases
FileMakerFoxProMS AccessParadox
General
General DB TopicsDatabase Theory
Related Topics
Java Development.NET DevelopmentVB DevelopmentMore Topics ...

Database Forum / DB2 Topics / June 2006

Tip: Looking for answers? Try searching our database.

About Discoonection

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Suresh - 21 Jun 2006 13:12 GMT
Hi All

I am design one web database.
In this database i want to execute one routine At the time of execution
of this routine,User (application server or other database user) should
not access database. means database should be offline to application
server or other user who can access but I should be able to access
database to execute that routine. That routine may be executed by using
some appplication which is running on same databse server or by DBA.So
what is approch to handle such situation in DB2. I am new to DB2.

Thanks

Suresh
Ian - 21 Jun 2006 16:38 GMT
> Hi All
>
[quoted text clipped - 6 lines]
> some appplication which is running on same databse server or by DBA.So
> what is approch to handle such situation in DB2. I am new to DB2.

Use stored procedures;  grant execute privileges on the stored
procedures to the appropriate users, but don't grant
select/insert/update/delete privileges on the base tables.
Pierre Saint-Jacques - 21 Jun 2006 21:14 GMT
You do not say but I will presume you are using DB2 UDB for
Linux/Windows/Unix and at V8.
In this case, build the routine using an id that has QUIESCE_CONNECT
privilege.  Usually that is SYSADMIN and/or DBADM authority.
In the routine, start by issuing the db2 quiesce db command and then connect
and run the routine.

This will force off all applications.  Those in the middle of a unitof work
will get rolled back and disconnected.  Everybody else gets disconnected.
No request for connections may be accepted by the db except those that have
the privilege mentioned above.

HTH,  Pierre.

Signature

Pierre Saint-Jacques
SES Consultants Inc.
514-737-4515

> Hi All
>
[quoted text clipped - 10 lines]
>
> Suresh
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2009 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.