batch method to delete data from multiple databases

John at mcngroup.net John at mcngroup.net
Sat Jan 9 07:51:02 PST 2016


>From outside of filepro,
If you use a compression utility like pkzip, compress the key,data,index and
blob files from each data base when empty, then when you need to erase the
databases, decompress and restore those files to the respective folders.
Will only take a few seconds to complete.
Make sure you update the zipped storage files again should you restructure
any databases.

John McNaughton
Broker/LCAM/Pres

MCN Group, Inc.
2500 1st Ave N
St Petersburg FL 33713
727-321-6783 Office
727-656-6507 Cell

This email and any files transmitted with it are confidential and intended
solely for the use of the individual or entity to whom they are addressed.
If you have received this email in error please notify the system manager.
This message contains confidential information and is intended only for the
individual named. If you are not the named addressee you should not
disseminate, distribute or copy this e-mail. Please notify the sender
immediately by e-mail if you have received this e-mail by mistake and delete
this e-mail from your system. If you are not the intended recipient you are
notified that disclosing, copying, distributing or taking any action in
reliance on the contents of this information is strictly prohibited.

-----Original Message-----
From: Filepro-list
[mailto:filepro-list-bounces+john=mcngroup.net at lists.celestial.com] On
Behalf Of filepro-list-request at lists.celestial.com
Sent: Saturday, January 9, 2016 4:31 AM
To: filepro-list at lists.celestial.com
Subject: Filepro-list Digest, Vol 144, Issue 5

Send Filepro-list mailing list submissions to
	filepro-list at lists.celestial.com

To subscribe or unsubscribe via the World Wide Web, visit
	http://mailman.celestial.com/mailman/listinfo/filepro-list
or, via email, send a message with subject or body 'help' to
	filepro-list-request at lists.celestial.com

You can reach the person managing the list at
	filepro-list-owner at lists.celestial.com

When replying, please edit your Subject line so it is more specific than
"Re: Contents of Filepro-list digest..."


Today's Topics:

   1. batch method to delete data from multiple databases
      (Richard Veith)
   2. Re: batch method to delete data from multiple databases
      (Jose Lerebours)
   3. RE: batch method to delete data from multiple databases
      (Mike Schwartz)
   4. RE: batch method to delete data from multiple databases
      (Richard Veith)


----------------------------------------------------------------------

Message: 1
Date: Fri, 8 Jan 2016 12:15:54 -0500
From: "Richard Veith" <Richard.Veith at SMRresearch.com>
To: <Filepro-list at lists.celestial.com>
Subject: batch method to delete data from multiple databases
Message-ID: <000001d14a38$3d10cbf0$b73263d0$@SMRresearch.com>
Content-Type: text/plain; charset="us-ascii"

Hi,

   Once a month, we delete all "key and data" from seven or eight FilePro
databases, so that we can then run processes to populate them with the new
month's data.  We are currently doing this one by one, using menu screens
(e.g., menu choices "?", "D", "L" and "Yes").   Is there a way to create a
batch script that  would run through all the relevant databases and delete
all "key and data" from each one?

Thanks,

Rich

 

-------------- next part --------------
An HTML attachment was scrubbed...
URL:
<http://mailman.celestial.com/pipermail/filepro-list/attachments/20160108/25
9c10bf/attachment.html>


------------------------------

Message: 2
Date: Fri, 8 Jan 2016 12:29:13 -0500
From: Jose Lerebours <fpgroups at gmail.com>
To: filepro-list at lists.celestial.com
Subject: Re: batch method to delete data from multiple databases
Message-ID: <568FF1E9.7040503 at gmail.com>
Content-Type: text/plain; charset=windows-1252; format=flowed

Look at syntax for ddir, following its syntax, write a menu option with a
script behind it and in that script, write a ddir [filename] -k -m
"[qualname] -h "removing key for [filename]"

-k pops for some reason as if I've used this before ... lol

So yes, it is possible - look at 'ddir' for details




On 01/08/2016 12:15 PM, Richard Veith via Filepro-list wrote:
> Hi,
>
>     Once a month, we delete all "key and data" from seven or eight 
> FilePro databases, so that we can then run processes to populate them 
> with the new month's data.  We are currently doing this one by one, using
menu screens
> (e.g., menu choices "?", "D", "L" and "Yes").   Is there a way to create a
> batch script that  would run through all the relevant databases and 
> delete all "key and data" from each one?
>
> Thanks,
>
> Rich
>
>   
>
> -------------- next part -------------- An HTML attachment was 
> scrubbed...
> URL: 
> <http://mailman.celestial.com/pipermail/filepro-list/attachments/20160
> 108/259c10bf/attachment.html> 
> _______________________________________________
> Filepro-list mailing list
> Filepro-list at lists.celestial.com
> Subscribe/Unsubscribe/Subscription Changes 
> http://mailman.celestial.com/mailman/listinfo/filepro-list



------------------------------

Message: 3
Date: Fri, 8 Jan 2016 11:44:01 -0600
From: "Mike Schwartz" <mschw at athenet.net>
To: <filepro-list at lists.celestial.com>
Subject: RE: batch method to delete data from multiple databases
Message-ID: <06e901d14a3c$290ebd20$7b2c3760$@athenet.net>
Content-Type: text/plain;	charset="us-ascii"

> (e.g., menu choices "?", "D", "L" and "Yes").   Is there a way to create a
> batch script that  would run through all the relevant databases and 
> delete
all
> "key and data" from each one?
> 
> Thanks,
> 
> Rich

     Yes, the filePro DDIR command has options to delete the key and data
from an individual filepro database.  You can even delete the data in a
qualifier, leaving the main key and data intact.

     In a filePro menu, you could write a batch script that deletes the key
and data segments from several filePro databases at the same time, something
like this Unix script:

FP="/u/appl"
$FP/fp/ddir LMpost -KA -H "DELETING LMpost Last month's posted DATA"
$FP/fp/ddir SmanSpiff -KA -H "DELETING Last Month's spiff DATA"
$FP/fp/ddir AGT_PAY -KA -H "DELETING Last Month's AGENTS PAYABLE DATA"
  
NOTES:

     1)  Read up on the DDIR command options *CAREFULLY* in the filepro help
files and in STNs filepro bible *before* you try using DDIR.

     2) Test your scripts *ONLY* after you have done a full filePro database
backup and when nobody else is accessing the databases.

     3)  Put some protection, like a password or other block, on the menu
that runs this script, so that nobody accidentally runs it in the middle of
the month!

     4) Ask questions in this group *BEFORE* you try to run your script.

Mike Schwartz





------------------------------

Message: 4
Date: Fri, 8 Jan 2016 14:14:00 -0500
From: "Richard Veith" <Richard.Veith at SMRresearch.com>
To: <filepro-list at lists.celestial.com>
Subject: RE: batch method to delete data from multiple databases
Message-ID: <000c01d14a48$bb96fbb0$32c4f310$@SMRresearch.com>
Content-Type: text/plain;	charset="us-ascii"

Thanks very much to both Mike and Jose for pointing me in the right
direction.   After some testing, I think "dprodir testname -KA" is what I
want, since I am not trying to create a menu option, but rather a separate
DOS batch file with a dprodir line for each database that needs to be
cleaned out.

Thanks again,
Rich  

-----Original Message-----
From: Filepro-list
[mailto:filepro-list-bounces+richard.veith=smrresearch.com at lists.celestial.c
om] On Behalf Of Mike Schwartz via Filepro-list
Sent: Friday, January 08, 2016 12:44 PM
To: filepro-list at lists.celestial.com
Subject: RE: batch method to delete data from multiple databases

> (e.g., menu choices "?", "D", "L" and "Yes").   Is there a way to create a
> batch script that  would run through all the relevant databases and 
> delete
all
> "key and data" from each one?
> 
> Thanks,
> 
> Rich

     Yes, the filePro DDIR command has options to delete the key and data
from an individual filepro database.  You can even delete the data in a
qualifier, leaving the main key and data intact.

     In a filePro menu, you could write a batch script that deletes the key
and data segments from several filePro databases at the same time, something
like this Unix script:

FP="/u/appl"
$FP/fp/ddir LMpost -KA -H "DELETING LMpost Last month's posted DATA"
$FP/fp/ddir SmanSpiff -KA -H "DELETING Last Month's spiff DATA"
$FP/fp/ddir AGT_PAY -KA -H "DELETING Last Month's AGENTS PAYABLE DATA"
  
NOTES:

     1)  Read up on the DDIR command options *CAREFULLY* in the filepro help
files and in STNs filepro bible *before* you try using DDIR.

     2) Test your scripts *ONLY* after you have done a full filePro database
backup and when nobody else is accessing the databases.

     3)  Put some protection, like a password or other block, on the menu
that runs this script, so that nobody accidentally runs it in the middle of
the month!

     4) Ask questions in this group *BEFORE* you try to run your script.

Mike Schwartz



_______________________________________________
Filepro-list mailing list
Filepro-list at lists.celestial.com
Subscribe/Unsubscribe/Subscription Changes
http://mailman.celestial.com/mailman/listinfo/filepro-list



------------------------------

Subject: Digest Footer

_______________________________________________
Filepro-list mailing list
Filepro-list at lists.celestial.com
http://mailman.celestial.com/mailman/listinfo/filepro-list


------------------------------

End of Filepro-list Digest, Vol 144, Issue 5
********************************************




More information about the Filepro-list mailing list