Quantcast

Copying records between tables

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Copying records between tables

James McAlister
In FMP7 (Windows XP Pro), I need to copy a found set of records from one
table to another table for further processing. Is this the proper procedure:
1) export the records from Table 1 to a file and then 2( import the file
into Table 2? And if so, how do I best delete the exported file after the
import is finished?

Or is there an approach that doesn't require an export?

Thanks!

James McAlister
www.BulletinInserts.org
www.james-mc.com



--

Convert your FileMaker CDML to Lasso Professional 8 FREE:
http://www.omnipilot.com/article.lasso?id=8630

Lasso is the secure corporate alternative to open-source and  
Microsoft for publishing databases online.

------------------------------
This list is a free service of OmniPilot Software, Inc.
http://www.omnipilot.com/
Search the list archives:
http://www.listsearch.com/filemakerprotalk.lasso
Manage your subscription:
http://www.listsearch.com/filemakerprotalk.lasso?manage
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Copying records between tables

Gary Bogue
1) In a script, set Table 1 to display the found set you want to
transfer. Or do it manually before triggering the script.
2) Call a script in the second file to continue. If both tables are in
one file, just move to a layout based on Table 2.
3) Do a scripted import in Table 2 to fetch records from Table 1.

That's it. You will need to set up the import to get the fields you
want included. No intermediate file needed, assuming that fields in
both tables match. They don't even require the same field names,
although data types should match. If both tables are in one file, it
can all be handled in a single script. If in two files, the first
script calls the second. If you want to conclude in the second file,
add a Halt Script step to the end to prevent returning to the first
script (and thus the first file).

Gary

---------------------------------------------------------------
Gary Bogue, Database Design Consultant
91 Hampden Road
Rochester, NY  14610
585-482-8602   [hidden email]
---------------------------------------------------------------


On Jun 12, 2005, at 7:14 PM, James McAlister wrote:

> In FMP7 (Windows XP Pro), I need to copy a found set of records from
> one
> table to another table for further processing. Is this the proper
> procedure:
> 1) export the records from Table 1 to a file and then 2( import the
> file
> into Table 2? And if so, how do I best delete the exported file after
> the
> import is finished?
>
> Or is there an approach that doesn't require an export?
>
> Thanks!
>
> James McAlister
> www.BulletinInserts.org
> www.james-mc.com


--

Convert your FileMaker CDML to Lasso Professional 8 FREE:
http://www.omnipilot.com/article.lasso?id=8630

Lasso is the secure corporate alternative to open-source and  
Microsoft for publishing databases online.

------------------------------
This list is a free service of OmniPilot Software, Inc.
http://www.omnipilot.com/
Search the list archives:
http://www.listsearch.com/filemakerprotalk.lasso
Manage your subscription:
http://www.listsearch.com/filemakerprotalk.lasso?manage
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Copying records between tables

James McAlister
In reply to this post by James McAlister
Thanks, Gary! This appears to work well after I specify the file (the same
file that I'm in) and then the field mapping. I'm actually going to do
several imports with different criteria and will need to send the results to
different fields in the target Table 2 depending on the type of import.

I appreciate the help!

James McAlister
www.BulletinInserts.org
www.james-mc.com


-----Original Message-----
From: [hidden email] [mailto:[hidden email]] On Behalf
Of Gary Bogue
Sent: Sunday, June 12, 2005 6:33 PM
To: [hidden email]
Subject: Re: Copying records between tables

1) In a script, set Table 1 to display the found set you want to
transfer. Or do it manually before triggering the script.
2) Call a script in the second file to continue. If both tables are in
one file, just move to a layout based on Table 2.
3) Do a scripted import in Table 2 to fetch records from Table 1.

That's it. You will need to set up the import to get the fields you
want included. No intermediate file needed, assuming that fields in
both tables match. They don't even require the same field names,
although data types should match. If both tables are in one file, it
can all be handled in a single script. If in two files, the first
script calls the second. If you want to conclude in the second file,
add a Halt Script step to the end to prevent returning to the first
script (and thus the first file).

Gary



--

Convert your FileMaker CDML to Lasso Professional 8 FREE:
http://www.omnipilot.com/article.lasso?id=8630

Lasso is the secure corporate alternative to open-source and  
Microsoft for publishing databases online.

------------------------------
This list is a free service of OmniPilot Software, Inc.
http://www.omnipilot.com/
Search the list archives:
http://www.listsearch.com/filemakerprotalk.lasso
Manage your subscription:
http://www.listsearch.com/filemakerprotalk.lasso?manage
Loading...