Re: FlushDatabase Suggestion

This WebDNA talk-list message is from

1998


It keeps the original formatting.
numero = 18062
interpreted = N
texte = >I think you have to quit WebStar & WebCat CGI, replace the db & relaunch.No you do not have to do this, WebCat can do it all itself.You will never have to worry about the old db getting reloaded if you use the following three tags in your update template as shown here. And because it only takes about 7 ticks to do all three tasks, the possibility of someone getting the Error, db not found message during this process is extremely rare:[deletefile path/to/old.db] [closedatabase path/to/old.db] [copyfile path=path/to/new.db&to=path/to/old.db] 1- The first tag deletes the old.db file, thus it *cannot* be reloaded. This does not stop WebCat from processing requests for the old.db data, because there's still a copy in the RAM cache.2- The second tag purges the data from the RAM cache. This stops WebCat from processing any more requests for old.db data until WebCat has reloaded it into RAM again. But you just trashed the old.db file in the previous step, so WebCat cannot even reload the old.db file again ...3- The third tag copies the new.db file to the place where the old.db was stored. Now WebCat can load the new.db file into RAM and start processing requests again, this time with the new data instead of the old data.Sincerely, Ken Grome 808-737-6499 WebDNA Solutions mailto:ken@webdna.net http://www.webdna.net Associated Messages, from the most recent to the oldest:

    
  1. Re: FlushDatabase Suggestion (Pat McCormick 1998)
  2. Re: FlushDatabase Suggestion (Pat McCormick 1998)
  3. Re: FlushDatabase Suggestion (Pat McCormick 1998)
  4. Re: FlushDatabase Suggestion (Kenneth Grome 1998)
  5. Re: FlushDatabase Suggestion (bob 1998)
  6. Re: FlushDatabase Suggestion (bob 1998)
  7. Re: FlushDatabase Suggestion (bob 1998)
  8. Re: FlushDatabase Suggestion (Pat McCormick 1998)
  9. Re: FlushDatabase Suggestion (Pat McCormick 1998)
  10. Re: FlushDatabase Suggestion (Kenneth Grome 1998)
  11. Re: FlushDatabase Suggestion (Bob Minor 1998)
  12. Re: FlushDatabase Suggestion (Pat McCormick 1998)
  13. Re: FlushDatabase Suggestion (Bob Minor 1998)
  14. Re: FlushDatabase Suggestion (Pat McCormick 1998)
  15. Re: FlushDatabase Suggestion (Kenneth Grome 1998)
  16. Re: FlushDatabase Suggestion (Pat McCormick 1998)
  17. Re: FlushDatabase Suggestion (Kenneth Grome 1998)
  18. FlushDatabase Suggestion (Pat McCormick 1998)
>I think you have to quit WebStar & WebCat CGI, replace the db & relaunch.No you do not have to do this, WebCat can do it all itself.You will never have to worry about the old db getting reloaded if you use the following three tags in your update template as shown here. And because it only takes about 7 ticks to do all three tasks, the possibility of someone getting the Error, db not found message during this process is extremely rare:[deletefile path/to/old.db] [closedatabase path/to/old.db] [copyfile path=path/to/new.db&to=path/to/old.db] 1- The first tag deletes the old.db file, thus it *cannot* be reloaded. This does not stop WebCat from processing requests for the old.db data, because there's still a copy in the RAM cache.2- The second tag purges the data from the RAM cache. This stops WebCat from processing any more requests for old.db data until WebCat has reloaded it into RAM again. But you just trashed the old.db file in the previous step, so WebCat cannot even reload the old.db file again ...3- The third tag copies the new.db file to the place where the old.db was stored. Now WebCat can load the new.db file into RAM and start processing requests again, this time with the new data instead of the old data.Sincerely, Ken Grome 808-737-6499 WebDNA Solutions mailto:ken@webdna.net http://www.webdna.net Kenneth Grome

DOWNLOAD WEBDNA NOW!

Top Articles:

Talk List

The WebDNA community talk-list is the best place to get some help: several hundred extremely proficient programmers with an excellent knowledge of WebDNA and an excellent spirit will deliver all the tips and tricks you can imagine...

Related Readings:

[WebDNA] Two stores one db (2011) referrer and no caches (1997) sendmail what is SIMS? (1999) [FEATURE REQUEST] (2004) 2.1 bugs left over from beta cycle (1998) Exclude by date - multiple (1997) all records returned. (1997) lookups (2000) Reversed words (1997) Logging purchases (1997) WebTen? (1997) redirect with frames (1997) [AppendFile] problem (WebCat2b13 Mac .acgi) (1997) GuestBook example (1997) Automatic Forwarding using WebCat (1997) (more) TCPConnect / Current Temperature (2004) number of found records in a