Thanks!  I just got a similar version of what you're
talking about running -- though I was hoping to find a
way to do it without locking anything.  I can live
with the lock though:

<!--- get Query of Samples to populate new Access file
with --->

<cflock name="databaseTransfer" timeout="60"
type="exclusive">
     <!--- DELETE all samples from
empty-of-data-but-has-your-tables database --->

     <!--- loop over Query of Samples and INSERT into
empty-of-data-but-has-your-tables database --->

     <!--- copy empty-of-data-but-has-your-tables
database Access file to new client-specific Access
file --->

     <!--- DELETE all samples from
empty-of-data-but-has-your-tables database Access --->

    <!--- cflocation to the Client-Specific Access
file --->
</cflock>

Sounds similar to what you suggested.  At least I know
I'm not missing some really simple way to do this.  It
seems a tad convoluted to me -- but it works!

Thanks for the response!

Jonathon


--- Pete Ruckelshaus <[EMAIL PROTECTED]> wrote:

> I had a similar (well, sort of) problem that I
> needed to overcome.
> 
> Create an Access DSN, something like sampleDbDSN. 
> You'll need to have
> a "copy" of the database in that location.  This
> file will reside in a
> fixed location, i.e.
> c:\inetpub\wwwroot\myapp\data\sampledb.mdb  This
> will be the "target" database.
> 
> Have a "source" Access DSN that contains your
> empty-of-data-but-has-your-tables database in
> another path, i.e.
> c:\inetpub\wwwroot\myapp\data\source\sampledb.mdb
> 
> Your CF script will run a "bad" query against
> sampleDbDSN, which will
> "break" the Access lock and allow another file to be
> copied over it.
> Then run a cffile operation to copy your
> \myapp\data\source\sampledb.mdb file over to your
> \myapp\data\sampledb.mdb file.  Then, run your data
> import script to
> populate the \data\sampledb.mdb file
> 
> You'll want to figure out some way to "lock" the MDB
> file when it's
> being imported into.
> 
> Pete
> 
>


~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Upgrade to Adobe ColdFusion MX7 
Experience Flex 2 & MX7 integration & create powerful cross-platform RIAs 
http:http://ad.doubleclick.net/clk;56760587;14748456;a?http://www.adobe.com/products/coldfusion/flex2/?sdid=LVNU

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:268584
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4

Reply via email to