Another option, Jan, is to put some code in a copy of your startup .dat file
that presents a message to the user to the effect that database maintenance
is being performed, and then exits.  You keep a copy of this changed file
and the original in some subfolder, and when you start your maintenance
routine copy the appropriate one into place, then at the end of your
maintenance routine copy the original back.

 

Emmitt Dove

Manager, DairyPak Business Systems

Evergreen Packaging, Inc.

[EMAIL PROTECTED]

[EMAIL PROTECTED]

(203) 643-8022

 

From: [email protected] [mailto:[EMAIL PROTECTED] On Behalf Of jan johansen
Sent: Thursday, August 28, 2008 1:51 PM
To: RBASE-L Mailing List
Subject: [RBASE-L] - Re: Second connection

 

Dawn,

 

Funny you should mention that! I was just thinking the same thing.

I actually think my brother Ben used that scenario a long time ago

in the 4.5 days. Should still work.

 

Jan 
 

 

-----Original Message-----
From: "Dawn Hast" <[EMAIL PROTECTED]>
To: [email protected] (RBASE-L Mailing List)
Date: Thu, 28 Aug 2008 17:40:07 +0000
Subject: [RBASE-L] - Re: Second connection

Ah I see.  At one of the conferences, I think I remember someone's
maintenance routine where they placed a dummy file in the database directory
when they didn't want anyone to connect to the db, and deleted it when they
were done.  So you could do something like that:  At the beginning of your
process, write some file to the database directory.  In the rbase.dat file
for the users (or other startup file), before attempting to connect, check
for the file.  If it's there, give the user a message that the db is
currently unavailable due to maintenance.  Then at the end of your process,
when you're done with both dbs, remove the files.

 

Dawn

-------------- Original message from "jan johansen"
<[EMAIL PROTECTED]>: -------------- 

Dawn,

 

Good thought. However I have battled with this database because the settings
will

not allow sconnect and sattach. The owner of the database is adamant that we


not touch those settings so I am stuck with them.

 

Jan
 

 

-----Original Message-----
From: "Dawn Hast" <[EMAIL PROTECTED]>
To: [email protected] (RBASE-L Mailing List)
Date: Thu, 28 Aug 2008 16:57:47 +0000
Subject: [RBASE-L] - Re: Second connection

Can you sconnect to the second db and sattach the necessary tables to
update? 

-------------- Original message from "jan johansen"
<[EMAIL PROTECTED]>: -------------- 

Group,

 

I have a process that archives from one database to the another.

I have a step that checks for the number of connections before I start the
process.

However the process can take 10-15 minutes and it never fails, someone

will connect to either of the databases in the middle of the processes.

 

Although I use SET MULTI OFF, when I disconnect from database 1 and connect

to database 2, database 1 becomes available for connections because I am now


in database 2.

 

Anyone have any slick tricks to open a second connection with code so that
with

SET MULTI OFF I have the only connections allowed to the database and then

shut down both connections after I am done?

 

Jan

Reply via email to