je duce Posted June 24, 2005 Posted June 24, 2005 Is it possible to export only the related records of a found set? The only means I found is to (1) copy the DB. (2) Then delete the omitted records of the found set. (3) Then export all records of each table. It seems in FM 7 the information is there. When a relationships established it allows you to delete all related records via that relationship but I see no means to export the same. Very likely I am missing something. Can this be scripted? Can you help?
-Queue- Posted June 24, 2005 Posted June 24, 2005 Export from the main table, but only include related fields and do not summarize by the key field.
je duce Posted June 25, 2005 Author Posted June 25, 2005 Thanks Queue I guess i failed to clarify my situation. Consider a DB where you have a Customer records with invoice via a portal which in-turn have individual line items. Thus three separate related tables. If you delete the a customer record all related invoices with their individual line items can be deleted. However if you export a customer record the related records such as the invoice and line item tables are not exported. If I have a found set of specific customers can the associated related (invoice etc.) records be isolated for that found set. Once that is done then an exporting script is possible.
-Queue- Posted June 27, 2005 Posted June 27, 2005 When you specify the field order for the export, making sure you are on the Customer layout, change 'Current Table' to your Invoice table, add the desired fields, then change it to your LineItems table and add the desired fields. Also, Unsort the customer records before performing the export. There is a glitch that will cause them to be summarized otherwise.
je duce Posted June 28, 2005 Author Posted June 28, 2005 Thanks for the heads up on the impact of the sort glitch. I guess the concept to archiving record with multiple related child records is not in the vernacular of FM 7. To that end, is there a way to intiate an import script in the seperate arcive file after the exporting script from the main file is completed.
-Queue- Posted June 28, 2005 Posted June 28, 2005 Yes, but I think you would be doing a LOT of parsing on the imported data. Why not just isolate the data in each file you want to archive, then import each appropriate table's data into the archive file?
je duce Posted June 28, 2005 Author Posted June 28, 2005 Indeed, Now I simply need to create the necessary found set then initiate the import script in the archive file. It wasn't initially clear to me to import a found set of the main file to the archive file directly. I was forcing it the other way. Thank again for your support. Now onto some serious scripting.
Recommended Posts
This topic is 7088 days old. Please don't post here. Open a new topic instead.
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now