Ben,
Your idea seems to require application scope variables instead of request
scope.  Request scope is not persistent between page hits and are unique to
each user.  If you use application scope, then you can be sure to have only
one persistent structure for all users.  Also, I believe the only way to
insert a record for each user in a structure is to do a loop.  Maybe some DB
mastermind out there will know of a different way, but I am fairly sure.

Jason

-----Original Message-----
From: Ben Lowndes [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, November 21, 2000 9:13 AM
To: Fusebox
Subject: Fusebox internal logging.


Hello everybody.

I remember a couple of months ago a discussion on this list concerning
performing logging within Fusebox... I'm about to embark on a similar thing
and was wondering if anyone made any progress with this???

I'm not actually doing full logging of every user as I don't believe that
would be efficent, but just on a section of my site. Here's what I was
thinking:

When a user hits the page I load all the data on them into a request scoped
structure. I then copy this into an app level struct holding many users
details... When this app level struct contains a certain number of users
details, e.g 100, I do a bulk insert into the Db of all these details.

A few questions about this technique...

What's the best way to do a Db insert from a large struct??? Do I just loop
over the struct inside a SQL query?
When the 100th user (or what ever I set the limit to on the struct to be)
hits the page, the loading of their page will be considerably slowed by the
SQL insert, is there anyway to "spawn" another process, so it wont affect
any users??

Thanks

Ben.

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Structure your ColdFusion code with Fusebox. Get the official book at
http://www.fusionauthority.com/bkinfo.cfm

Archives: http://www.mail-archive.com/[email protected]/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Structure your ColdFusion code with Fusebox. Get the official book at 
http://www.fusionauthority.com/bkinfo.cfm

Archives: http://www.mail-archive.com/[email protected]/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists

Reply via email to