RE: using WDDX for next 'n' style browsing

2001-05-15 Thread Kola Oyedeji

Dick

Thanks for your advice, its funny but my boss just said the same thing
(about using flash)
My main goal was to not make another trip to the server (hence the use of
javascript and wddx)

Only the neccesary fields would be sent to the browser. I suggested using an
applet but my boss
pointed out without a java enabled browser with the correct version this
functionality would be useless,I would have thought the same went for using
flash as well.

The two goals i was aiming for were not to perform another query and not to
make another trip
to the server. Is this possible with a cached query and Flash?

Thanks

KOla

-Original Message-
From: Dick Applebaum [mailto:[EMAIL PROTECTED]]
Sent: 11 May 2001 16:43
To: CF-Talk
Subject: Re: using WDDX for next 'n' style browsing


I waited a while before weighing in on this, but here goes...

rant

I hate to see this type of design, where large amounts of data (most
of it, probably, unneeded) are schlepped back and forth along the
highway we call the internet.  It clogs the net with [largely]
unnecessary traffic.

Further, the verbosity of WDDX packets only exacerbates the problem
by increasing the amount of the data sent (over and over and over...)

Look at a WDDX Packet and you will see it's size is many times larger
than the actual data content.

Don't get me wrong, I use WDDX every day, and used properly it is a
valuable tool...


But, WDDX is not meant to be an extension of the client/server system bus.


/rant

Use CF to cache your queries at the server

in your CF program select only the required rows, and send them to the
client

If you want to improve this more, write a Flash front end for the
client so that only the field names and data need to be sent to the
client (eliminates retransmitting the entire HTML document)

I think you will experience an overall performance improvement and
better use of the server, internet connection, and the client...

. kind of an *environmentally-friendly* program design!


And, the user experience will be much improved too.


Dick


At 11:52 AM +0100 5/8/01, Kola Oyedeji wrote:
I am passing a query object which consists of 1000 records in a hidden form
field between pages as a
WDDX packet, are there any reasons why this is a bad idea, such as limits
to
the amount of data which can be held in a form field or passed in a form?

The reason for this is to save a trip to the server for each page of
result.
Are there any better solutions, would cacheing the query and executing it
again for every page be more efficient than trying to offload the
processing
onto the client's machine?

Thanks

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

Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists



Re: using WDDX for next 'n' style browsing

2001-05-14 Thread Dick Applebaum

I waited a while before weighing in on this, but here goes...

rant

I hate to see this type of design, where large amounts of data (most 
of it, probably, unneeded) are schlepped back and forth along the 
highway we call the internet.  It clogs the net with [largely] 
unnecessary traffic.

Further, the verbosity of WDDX packets only exacerbates the problem 
by increasing the amount of the data sent (over and over and over...)

Look at a WDDX Packet and you will see it's size is many times larger 
than the actual data content.

Don't get me wrong, I use WDDX every day, and used properly it is a 
valuable tool...


But, WDDX is not meant to be an extension of the client/server system bus.


/rant

Use CF to cache your queries at the server

in your CF program select only the required rows, and send them to the client

If you want to improve this more, write a Flash front end for the 
client so that only the field names and data need to be sent to the 
client (eliminates retransmitting the entire HTML document)

I think you will experience an overall performance improvement and 
better use of the server, internet connection, and the client...

 kind of an *environmentally-friendly* program design!


And, the user experience will be much improved too.


Dick


At 11:52 AM +0100 5/8/01, Kola Oyedeji wrote:
I am passing a query object which consists of 1000 records in a hidden form
field between pages as a
WDDX packet, are there any reasons why this is a bad idea, such as limits to
the amount of data which can be held in a form field or passed in a form?

The reason for this is to save a trip to the server for each page of result.
Are there any better solutions, would cacheing the query and executing it
again for every page be more efficient than trying to offload the processing
onto the client's machine?

Thanks

Kola

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

Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists



RE: using WDDX for next 'n' style browsing

2001-05-11 Thread Kola Oyedeji

Craig

I'm just wondering what happens when 1000 users are executing searches at
the same time, thats a thousand session variables with a 1000 records each.
But it seems that setting the timeout
may help.

Thanks for the suggestion.

KOla

-Original Message-
From: Craig Bowes [mailto:[EMAIL PROTECTED]]
Sent: 10 May 2001 21:58
To: CF-Talk
Subject: RE: using WDDX for next 'n' style browsing


Yes, and that is something to consider.  But say a recordset has about 1000
records.  A 1000 records of text isn't that much memory.  And you could set
the timeout so the session variable dies after a short while thus freeing
memory that way.

-Original Message-
From: Kola Oyedeji [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, May 08, 2001 11:44 AM
To: CF-Talk
Subject: RE: using WDDX for next 'n' style browsing

But wont that mean each query would be held in the server RAM?

KOla



-Original Message-
From: Craig Bowes [mailto:[EMAIL PROTECTED]]
Sent: 08 May 2001 17:15
To: CF-Talk
Subject: RE: using WDDX for next 'n' style browsing


Another idea for saving query times for N next records is to store the
query as a session variable and you don't even have to run that query file
at all.

cfset session.savedquery = queryname

then you can do your cfoutput query=session.savedquery maxrows=#nrows#

be sure to put cflock around your cfset when setting session vars.

-Craig


-Original Message-
From: Kola Oyedeji [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, May 08, 2001 5:53 AM
To: CF-Talk
Subject: using WDDX for next 'n' style browsing


I am passing a query object which consists of 1000 records in a hidden form
field between pages as a
WDDX packet, are there any reasons why this is a bad idea, such as limits to
the amount of data which can be held in a form field or passed in a form?

The reason for this is to save a trip to the server for each page of result.
Are there any better solutions, would cacheing the query and executing it
again for every page be more efficient than trying to offload the processing
onto the client's machine?

Thanks

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

Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists



RE: using WDDX for next 'n' style browsing

2001-05-11 Thread Craig Bowes

Yes, Normally I don't deal with sites that get that much traffic.  In that
particular case you could use a cached query as some have suggested.

-Original Message-
From: Kola Oyedeji [mailto:[EMAIL PROTECTED]]
Sent: Friday, May 11, 2001 3:53 AM
To: CF-Talk
Subject: RE: using WDDX for next 'n' style browsing

Craig

I'm just wondering what happens when 1000 users are executing searches at
the same time, thats a thousand session variables with a 1000 records each.
But it seems that setting the timeout
may help.

Thanks for the suggestion.

KOla

-Original Message-
From: Craig Bowes [mailto:[EMAIL PROTECTED]]
Sent: 10 May 2001 21:58
To: CF-Talk
Subject: RE: using WDDX for next 'n' style browsing


Yes, and that is something to consider.  But say a recordset has about 1000
records.  A 1000 records of text isn't that much memory.  And you could set
the timeout so the session variable dies after a short while thus freeing
memory that way.

-Original Message-
From: Kola Oyedeji [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, May 08, 2001 11:44 AM
To: CF-Talk
Subject: RE: using WDDX for next 'n' style browsing

But wont that mean each query would be held in the server RAM?

KOla



-Original Message-
From: Craig Bowes [mailto:[EMAIL PROTECTED]]
Sent: 08 May 2001 17:15
To: CF-Talk
Subject: RE: using WDDX for next 'n' style browsing


Another idea for saving query times for N next records is to store the
query as a session variable and you don't even have to run that query file
at all.

cfset session.savedquery = queryname

then you can do your cfoutput query=session.savedquery maxrows=#nrows#

be sure to put cflock around your cfset when setting session vars.

-Craig


-Original Message-
From: Kola Oyedeji [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, May 08, 2001 5:53 AM
To: CF-Talk
Subject: using WDDX for next 'n' style browsing


I am passing a query object which consists of 1000 records in a hidden form
field between pages as a
WDDX packet, are there any reasons why this is a bad idea, such as limits to
the amount of data which can be held in a form field or passed in a form?

The reason for this is to save a trip to the server for each page of result.
Are there any better solutions, would cacheing the query and executing it
again for every page be more efficient than trying to offload the processing
onto the client's machine?

Thanks

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

Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists



RE: using WDDX for next 'n' style browsing

2001-05-10 Thread Craig Bowes

Yes, and that is something to consider.  But say a recordset has about 1000
records.  A 1000 records of text isn't that much memory.  And you could set
the timeout so the session variable dies after a short while thus freeing
memory that way.

-Original Message-
From: Kola Oyedeji [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, May 08, 2001 11:44 AM
To: CF-Talk
Subject: RE: using WDDX for next 'n' style browsing

But wont that mean each query would be held in the server RAM?

KOla



-Original Message-
From: Craig Bowes [mailto:[EMAIL PROTECTED]]
Sent: 08 May 2001 17:15
To: CF-Talk
Subject: RE: using WDDX for next 'n' style browsing


Another idea for saving query times for N next records is to store the
query as a session variable and you don't even have to run that query file
at all.

cfset session.savedquery = queryname

then you can do your cfoutput query=session.savedquery maxrows=#nrows#

be sure to put cflock around your cfset when setting session vars.

-Craig


-Original Message-
From: Kola Oyedeji [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, May 08, 2001 5:53 AM
To: CF-Talk
Subject: using WDDX for next 'n' style browsing


I am passing a query object which consists of 1000 records in a hidden form
field between pages as a
WDDX packet, are there any reasons why this is a bad idea, such as limits to
the amount of data which can be held in a form field or passed in a form?

The reason for this is to save a trip to the server for each page of result.
Are there any better solutions, would cacheing the query and executing it
again for every page be more efficient than trying to offload the processing
onto the client's machine?

Thanks

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

Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists



using WDDX for next 'n' style browsing

2001-05-08 Thread Kola Oyedeji



I am passing a query object which consists of 1000 records in a hidden form
field between pages as a
WDDX packet, are there any reasons why this is a bad idea, such as limits to
the amount of data which can be held in a form field or passed in a form?

The reason for this is to save a trip to the server for each page of result.
Are there any better solutions, would cacheing the query and executing it
again for every page be more efficient than trying to offload the processing
onto the client's machine?

Thanks

Kola


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

Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists



RE: using WDDX for next 'n' style browsing

2001-05-08 Thread DeVoil, Nick

I guess you mean the database server. You're still making a trip
to the *web* server for every page - and sending a lot of data.
Without knowing exactly what you're trying to achieve, I'd guess
cacheing the query would be better, yes.

Nick

-Original Message-
From: Kola Oyedeji [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, May 08, 2001 11:53 AM
To: CF-Talk
Subject: using WDDX for next 'n' style browsing




I am passing a query object which consists of 1000 records in a hidden form
field between pages as a
WDDX packet, are there any reasons why this is a bad idea, such as limits to
the amount of data which can be held in a form field or passed in a form?

The reason for this is to save a trip to the server for each page of result.
Are there any better solutions, would cacheing the query and executing it
again for every page be more efficient than trying to offload the processing
onto the client's machine?

Thanks

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

Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists



RE: using WDDX for next 'n' style browsing

2001-05-08 Thread Kola Oyedeji

Nick yes, you're right the page still has to download with all the extra
data, in addition to this turning the wddx packet into a javascript object
(to be displayed)is adding extra processing to the page
the page takes an average of 200 milliseconds.

What i'm trying to acheive is an alternative to re-executing a query on
every page request as
a user browses through results returned from a search

KOla

-Original Message-
From: DeVoil, Nick [mailto:[EMAIL PROTECTED]]
Sent: 08 May 2001 12:05
To: CF-Talk
Subject: RE: using WDDX for next 'n' style browsing


I guess you mean the database server. You're still making a trip
to the *web* server for every page - and sending a lot of data.
Without knowing exactly what you're trying to achieve, I'd guess
cacheing the query would be better, yes.

Nick

-Original Message-
From: Kola Oyedeji [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, May 08, 2001 11:53 AM
To: CF-Talk
Subject: using WDDX for next 'n' style browsing




I am passing a query object which consists of 1000 records in a hidden form
field between pages as a
WDDX packet, are there any reasons why this is a bad idea, such as limits to
the amount of data which can be held in a form field or passed in a form?

The reason for this is to save a trip to the server for each page of result.
Are there any better solutions, would cacheing the query and executing it
again for every page be more efficient than trying to offload the processing
onto the client's machine?

Thanks

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

Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists



RE: using WDDX for next 'n' style browsing

2001-05-08 Thread DeVoil, Nick

Right, that's exactly what cacheing the query will do for you.

Nick

-Original Message-
From: Kola Oyedeji [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, May 08, 2001 12:15 PM
To: CF-Talk
Subject: RE: using WDDX for next 'n' style browsing


Nick yes, you're right the page still has to download with all the extra
data, in addition to this turning the wddx packet into a javascript object
(to be displayed)is adding extra processing to the page
the page takes an average of 200 milliseconds.

What i'm trying to acheive is an alternative to re-executing a query on
every page request as
a user browses through results returned from a search

KOla

-Original Message-
From: DeVoil, Nick [mailto:[EMAIL PROTECTED]]
Sent: 08 May 2001 12:05
To: CF-Talk
Subject: RE: using WDDX for next 'n' style browsing


I guess you mean the database server. You're still making a trip
to the *web* server for every page - and sending a lot of data.
Without knowing exactly what you're trying to achieve, I'd guess
cacheing the query would be better, yes.

Nick

-Original Message-
From: Kola Oyedeji [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, May 08, 2001 11:53 AM
To: CF-Talk
Subject: using WDDX for next 'n' style browsing




I am passing a query object which consists of 1000 records in a hidden form
field between pages as a
WDDX packet, are there any reasons why this is a bad idea, such as limits to
the amount of data which can be held in a form field or passed in a form?

The reason for this is to save a trip to the server for each page of result.
Are there any better solutions, would cacheing the query and executing it
again for every page be more efficient than trying to offload the processing
onto the client's machine?

Thanks

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

Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists



Re: using WDDX for next 'n' style browsing

2001-05-08 Thread Michael Lugassy

I do search diffrently,
I first get ALL the results (as COUNT(*)) into a variable, which I transfer
from page to page.
Then I QUERY search with maxrows=20 (or as many as you want displayed on a
single page).
then every time a user click next, he's transfering some info on the urls:

1- recordcount of all results (i.e rc)
2- unique ID of the last item found (i.e lastid)
3- the search to search for, ofcourse (i.e searchstring)

then you can specify on the BIG count(*) query:

cfif NOT isDefined(url.rc)
QUERY
SELECT COUNT(*) from whatever whereever
/QUERY
cfset url.rc=allresults.recordcount
/cfif

[meaning: if you don't know how much records are in total, run big query]

then specify the search ONLY for this search

QUERY
SELECT field1,field2,field2 from whatever where field1='#searchstring#'
cfif isDefined(url.lastid) and fieldid  url.lastid /cfif
/QUERY

[meaning: search for results, if lastid exists, search FROM THIS id on]

By the way, you can also use verity's capability to specify: Startrow and
Maxrow
if the searchstring stays the same and you just want to move from page to
page,
move along a url.counter variable and specify :

cfsearch collection=searchwithin name=results type=SIMPLE
criteria=*#searchstring#*
startrow=#evaluate((url.counter-1)*maxdisplay+1)# maxrows=20

the big search for just getting the result amount is:

cfif NOT isDefined(url.rc)
cfsearch collection=groups001 name=results type=SIMPLE
criteria=*#searchstring#*
cfset url.rc=results.recordcount
/cfif

Contact me if you need a hand!


Thanks,

Michael Lugassy
IT/WEB Specialist
Interactive Music Ltd.
~~
Structure your ColdFusion code with Fusebox. Get the official book at 
http://www.fusionauthority.com/bkinfo.cfm

Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists



RE: using WDDX for next 'n' style browsing

2001-05-08 Thread Kola Oyedeji

Thanks i'll give it a try

KOla

-Original Message-
From: Michael Lugassy [mailto:[EMAIL PROTECTED]]
Sent: 08 May 2001 13:36
To: CF-Talk
Subject: Re: using WDDX for next 'n' style browsing


I do search diffrently,
I first get ALL the results (as COUNT(*)) into a variable, which I transfer
from page to page.
Then I QUERY search with maxrows=20 (or as many as you want displayed on a
single page).
then every time a user click next, he's transfering some info on the urls:

1- recordcount of all results (i.e rc)
2- unique ID of the last item found (i.e lastid)
3- the search to search for, ofcourse (i.e searchstring)

then you can specify on the BIG count(*) query:

cfif NOT isDefined(url.rc)
QUERY
SELECT COUNT(*) from whatever whereever
/QUERY
cfset url.rc=allresults.recordcount
/cfif

[meaning: if you don't know how much records are in total, run big query]

then specify the search ONLY for this search

QUERY
SELECT field1,field2,field2 from whatever where field1='#searchstring#'
cfif isDefined(url.lastid) and fieldid  url.lastid /cfif
/QUERY

[meaning: search for results, if lastid exists, search FROM THIS id on]

By the way, you can also use verity's capability to specify: Startrow and
Maxrow
if the searchstring stays the same and you just want to move from page to
page,
move along a url.counter variable and specify :

cfsearch collection=searchwithin name=results type=SIMPLE
criteria=*#searchstring#*
startrow=#evaluate((url.counter-1)*maxdisplay+1)# maxrows=20

the big search for just getting the result amount is:

cfif NOT isDefined(url.rc)
cfsearch collection=groups001 name=results type=SIMPLE
criteria=*#searchstring#*
cfset url.rc=results.recordcount
/cfif

Contact me if you need a hand!


Thanks,

Michael Lugassy
IT/WEB Specialist
Interactive Music Ltd.
~~
Structure your ColdFusion code with Fusebox. Get the official book at 
http://www.fusionauthority.com/bkinfo.cfm

Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists



Re: using WDDX for next 'n' style browsing

2001-05-08 Thread Sean Daniels

On 5/8/01 6:52 AM Kola Oyedeji wrote:

 I am passing a query object which consists of 1000 records in a hidden form
 field between pages as a
 WDDX packet, are there any reasons why this is a bad idea, such as limits to
 the amount of data which can be held in a form field or passed in a form?

I did a similar thing but rather than pass the WDDX pack in a form field I
wrote it to a local file using CFFILE. Each search (query) was givan a
search_id that I used to name the local file. I pass the search_id in the
hidden field, then on the next page I read it in, deserialized, and output.

It was way faster than rerunning the query, and although caching the query
would be faster, it was not possible because the query itself was generated
dynamically (based on an advanced search form), so with many concurrent
users it would have used up the max 100 cached queries on my server, which I
wanted to reserve for other more consistent queries.

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

Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists



RE: using WDDX for next 'n' style browsing

2001-05-08 Thread Kola Oyedeji

Sean

Thats a really good idea, just one question how do you manage all the query
files such as old
queries etc?

KOLa

-Original Message-
From: Sean Daniels [mailto:[EMAIL PROTECTED]]
Sent: 08 May 2001 14:33
To: CF-Talk
Subject: Re: using WDDX for next 'n' style browsing


On 5/8/01 6:52 AM Kola Oyedeji wrote:

 I am passing a query object which consists of 1000 records in a hidden
form
 field between pages as a
 WDDX packet, are there any reasons why this is a bad idea, such as limits
to
 the amount of data which can be held in a form field or passed in a form?

I did a similar thing but rather than pass the WDDX pack in a form field I
wrote it to a local file using CFFILE. Each search (query) was givan a
search_id that I used to name the local file. I pass the search_id in the
hidden field, then on the next page I read it in, deserialized, and output.

It was way faster than rerunning the query, and although caching the query
would be faster, it was not possible because the query itself was generated
dynamically (based on an advanced search form), so with many concurrent
users it would have used up the max 100 cached queries on my server, which I
wanted to reserve for other more consistent queries.

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

Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists



RE: using WDDX for next 'n' style browsing

2001-05-08 Thread Paul Smith

The is no maximum number of cached queries.  Turns out it's a CF Urban Legend.

I cache a bunch and for cases like this I set the expire to 5 or 10 minutes.

best,  paul

At 02:56 PM 5/8/01 +0100, you wrote:
It was way faster than rerunning the query, and although caching the query
would be faster, it was not possible because the query itself was generated
dynamically (based on an advanced search form), so with many concurrent
users it would have used up the max 100 cached queries on my server, which I
wanted to reserve for other more consistent queries.


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

Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists



RE: using WDDX for next 'n' style browsing

2001-05-08 Thread Ben Forta

Not really an urban legend, more like a restriction that was lifted post CF4
(but the CF Admin was not updated to reflect that g).

--- Ben


-Original Message-
From: Paul Smith [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, May 08, 2001 10:13 AM
To: CF-Talk
Subject: RE: using WDDX for next 'n' style browsing


The is no maximum number of cached queries.  Turns out it's a CF Urban
Legend.

I cache a bunch and for cases like this I set the expire to 5 or 10 minutes.

best,  paul

At 02:56 PM 5/8/01 +0100, you wrote:
It was way faster than rerunning the query, and although caching the query
would be faster, it was not possible because the query itself was generated
dynamically (based on an advanced search form), so with many concurrent
users it would have used up the max 100 cached queries on my server, which
I
wanted to reserve for other more consistent queries.
~~
Structure your ColdFusion code with Fusebox. Get the official book at 
http://www.fusionauthority.com/bkinfo.cfm

Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists



RE: using WDDX for next 'n' style browsing

2001-05-08 Thread Kola Oyedeji

Someone on another list proposed creating a unique id for each search query
executed and then
using this as a file name and writing the query as a WDDX packet to this
file. Then on every page this id can be used
to retreive the correct query object - and display it.

Any one see any problemes with this?

KOla

-Original Message-
From: Paul Smith [mailto:[EMAIL PROTECTED]]
Sent: 08 May 2001 15:13
To: CF-Talk
Subject: RE: using WDDX for next 'n' style browsing


The is no maximum number of cached queries.  Turns out it's a CF Urban
Legend.

I cache a bunch and for cases like this I set the expire to 5 or 10 minutes.

best,  paul

At 02:56 PM 5/8/01 +0100, you wrote:
It was way faster than rerunning the query, and although caching the query
would be faster, it was not possible because the query itself was generated
dynamically (based on an advanced search form), so with many concurrent
users it would have used up the max 100 cached queries on my server, which
I
wanted to reserve for other more consistent queries.
~~
Structure your ColdFusion code with Fusebox. Get the official book at 
http://www.fusionauthority.com/bkinfo.cfm

Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists



RE: using WDDX for next 'n' style browsing

2001-05-08 Thread Paul Smith

My recollection it was post CF3.
I believe CF4 allowed a user to specify more than 100.

best,  paul

At 11:03 AM 5/8/01 -0400, you wrote:
Not really an urban legend, more like a restriction that was lifted post CF4
(but the CF Admin was not updated to reflect that g).

--- Ben


-Original Message-
From: Paul Smith [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, May 08, 2001 10:13 AM
To: CF-Talk
Subject: RE: using WDDX for next 'n' style browsing


The is no maximum number of cached queries.  Turns out it's a CF Urban
Legend.

I cache a bunch and for cases like this I set the expire to 5 or 10 minutes.

best,  paul

At 02:56 PM 5/8/01 +0100, you wrote:
 It was way faster than rerunning the query, and although caching the query
 would be faster, it was not possible because the query itself was generated
 dynamically (based on an advanced search form), so with many concurrent
 users it would have used up the max 100 cached queries on my server, which
I
 wanted to reserve for other more consistent queries.

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

Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists



RE: using WDDX for next 'n' style browsing

2001-05-08 Thread Dave Watts

 Not really an urban legend, more like a restriction that was 
 lifted post CF4 (but the CF Admin was not updated to reflect 
 that g).

Not exactly. The CF Admin doesn't say you can't have more than 100 cached
queries, nor has it for some time. Other Allaire documentation and training
materials, however, didn't reflect this, as you mentioned.

Dave Watts, CTO, Fig Leaf Software
http://www.figleaf.com/
voice: (202) 797-5496
fax: (202) 797-5444

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

Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists



RE: using WDDX for next 'n' style browsing

2001-05-08 Thread Craig Bowes

Another idea for saving query times for N next records is to store the
query as a session variable and you don't even have to run that query file
at all.

cfset session.savedquery = queryname

then you can do your cfoutput query=session.savedquery maxrows=#nrows#

be sure to put cflock around your cfset when setting session vars.

-Craig


-Original Message-
From: Kola Oyedeji [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, May 08, 2001 5:53 AM
To: CF-Talk
Subject: using WDDX for next 'n' style browsing


I am passing a query object which consists of 1000 records in a hidden form
field between pages as a
WDDX packet, are there any reasons why this is a bad idea, such as limits to
the amount of data which can be held in a form field or passed in a form?

The reason for this is to save a trip to the server for each page of result.
Are there any better solutions, would cacheing the query and executing it
again for every page be more efficient than trying to offload the processing
onto the client's machine?

Thanks

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

Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists



RE: using WDDX for next 'n' style browsing

2001-05-08 Thread Kola Oyedeji

But wont that mean each query would be held in the server RAM?

KOla



-Original Message-
From: Craig Bowes [mailto:[EMAIL PROTECTED]]
Sent: 08 May 2001 17:15
To: CF-Talk
Subject: RE: using WDDX for next 'n' style browsing


Another idea for saving query times for N next records is to store the
query as a session variable and you don't even have to run that query file
at all.

cfset session.savedquery = queryname

then you can do your cfoutput query=session.savedquery maxrows=#nrows#

be sure to put cflock around your cfset when setting session vars.

-Craig


-Original Message-
From: Kola Oyedeji [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, May 08, 2001 5:53 AM
To: CF-Talk
Subject: using WDDX for next 'n' style browsing


I am passing a query object which consists of 1000 records in a hidden form
field between pages as a
WDDX packet, are there any reasons why this is a bad idea, such as limits to
the amount of data which can be held in a form field or passed in a form?

The reason for this is to save a trip to the server for each page of result.
Are there any better solutions, would cacheing the query and executing it
again for every page be more efficient than trying to offload the processing
onto the client's machine?

Thanks

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

Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists



Re: using WDDX for next 'n' style browsing

2001-05-08 Thread Jason Lotz

Actually, if you want to do this, you can skip the cfset step.  Just call
the query as below:

cfquery name=Session.MyQuery.


- Original Message -
From: Kola Oyedeji [EMAIL PROTECTED]
To: CF-Talk [EMAIL PROTECTED]
Sent: Tuesday, May 08, 2001 9:43 AM
Subject: RE: using WDDX for next 'n' style browsing


 But wont that mean each query would be held in the server RAM?

 KOla



 -Original Message-
 From: Craig Bowes [mailto:[EMAIL PROTECTED]]
 Sent: 08 May 2001 17:15
 To: CF-Talk
 Subject: RE: using WDDX for next 'n' style browsing


 Another idea for saving query times for N next records is to store the
 query as a session variable and you don't even have to run that query file
 at all.

 cfset session.savedquery = queryname

 then you can do your cfoutput query=session.savedquery
maxrows=#nrows#

 be sure to put cflock around your cfset when setting session vars.

 -Craig


 -Original Message-
 From: Kola Oyedeji [mailto:[EMAIL PROTECTED]]
 Sent: Tuesday, May 08, 2001 5:53 AM
 To: CF-Talk
 Subject: using WDDX for next 'n' style browsing


 I am passing a query object which consists of 1000 records in a hidden
form
 field between pages as a
 WDDX packet, are there any reasons why this is a bad idea, such as limits
to
 the amount of data which can be held in a form field or passed in a form?

 The reason for this is to save a trip to the server for each page of
result.
 Are there any better solutions, would cacheing the query and executing it
 again for every page be more efficient than trying to offload the
processing
 onto the client's machine?

 Thanks

 Kola

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

Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists



Re: using WDDX for next 'n' style browsing

2001-05-08 Thread Jamie Jackson

The problem with that is you would have to lock a query, and you
probably don't want to use a lock for that long.  I would think it's
best to set the variable aftewards, only locking the cfset.

Jamie

On Tue, 08 May 2001 10:18:06 -0700, Jason Lotz
[EMAIL PROTECTED] wrote:

Actually, if you want to do this, you can skip the cfset step.  Just call
the query as below:

cfquery name=Session.MyQuery.


- Original Message -
From: Kola Oyedeji [EMAIL PROTECTED]
To: CF-Talk [EMAIL PROTECTED]
Sent: Tuesday, May 08, 2001 9:43 AM
Subject: RE: using WDDX for next 'n' style browsing


 But wont that mean each query would be held in the server RAM?

 KOla



 -Original Message-
 From: Craig Bowes [mailto:[EMAIL PROTECTED]]
 Sent: 08 May 2001 17:15
 To: CF-Talk
 Subject: RE: using WDDX for next 'n' style browsing


 Another idea for saving query times for N next records is to store the
 query as a session variable and you don't even have to run that query file
 at all.

 cfset session.savedquery = queryname

 then you can do your cfoutput query=session.savedquery
maxrows=#nrows#

 be sure to put cflock around your cfset when setting session vars.

 -Craig


 -Original Message-
 From: Kola Oyedeji [mailto:[EMAIL PROTECTED]]
 Sent: Tuesday, May 08, 2001 5:53 AM
 To: CF-Talk
 Subject: using WDDX for next 'n' style browsing


 I am passing a query object which consists of 1000 records in a hidden
form
 field between pages as a
 WDDX packet, are there any reasons why this is a bad idea, such as limits
to
 the amount of data which can be held in a form field or passed in a form?

 The reason for this is to save a trip to the server for each page of
result.
 Are there any better solutions, would cacheing the query and executing it
 again for every page be more efficient than trying to offload the
processing
 onto the client's machine?

 Thanks

 Kola


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

Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists