RE: A brief question about lists
I was wondering if there are any guidelines, or limits in how many items can be in a list in a CF variable. There's no specific list data type in CF; lists are just strings. So, my guess is that a list can only contain as many characters (including delimiters) as any other string. Of course, that doesn't really help you with how many items can be in a list if you don't know the length of all items beforehand. Dave Watts, CTO, Fig Leaf Software http://www.figleaf.com/ Fig Leaf Software provides the highest caliber vendor-authorized instruction at our training centers in Washington DC, Atlanta, Chicago, Baltimore, Northern Virginia, or on-site at your location. Visit http://training.figleaf.com/ for more information! ~| Logware (www.logware.us): a new and convenient web-based time tracking application. Start tracking and documenting hours spent on a project or with a client with Logware today. Try it for free with a 15 day trial account. http://www.houseoffusion.com/banners/view.cfm?bannerid=67 Message: http://www.houseoffusion.com/lists.cfm/link=i:4:193127 Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4 Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4 Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4 Donations Support: http://www.houseoffusion.com/tiny.cfm/54
RE: A brief question about lists
None other than the fact that a list is a delimited text string that has to be parsed to get out the value. Too long and it takes a lot of processing to deal with it. Personally, I don't use lists longer than 100 items unless there's a really good reason for it. Hello, I was wondering if there are any guidelines, or limits in how many items can be in a list in a CF variable. Anyone? Thanks, -- Yves Arsenault ~| Find out how CFTicket can increase your company's customer support efficiency by 100% http://www.houseoffusion.com/banners/view.cfm?bannerid=49 Message: http://www.houseoffusion.com/lists.cfm/link=i:4:193128 Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4 Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4 Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4 Donations Support: http://www.houseoffusion.com/tiny.cfm/54
RE: A brief question about lists
-Original Message- From: Yves Arsenault [mailto:[EMAIL PROTECTED] Sent: Friday, February 04, 2005 2:43 PM To: CF-Talk Subject: A brief question about lists Hello, I was wondering if there are any guidelines, or limits in how many items can be in a list in a CF variable. I don't believe there is a limit (beyond hardware system limits) for size. I once ran a code challenge to tally the number of words in an arbitrary piece of text (for example the appears 35 times, We appears 3 times, etc) This was in CF 4.5/5.0 at the time (but I don't think it mattered) but one of the entries treated the text as a space-delimited list and looped over it. It worked just fine (and was actually one of the fastest entries) with text strings as large as the full novel Call of the Wild. I've also successfully done log file parsing in CF treating log files (even large ones) as carriage-return-delimited lists. In other words list can be very, very large. ;^) Jim Davis ~| Logware (www.logware.us): a new and convenient web-based time tracking application. Start tracking and documenting hours spent on a project or with a client with Logware today. Try it for free with a 15 day trial account. http://www.houseoffusion.com/banners/view.cfm?bannerid=67 Message: http://www.houseoffusion.com/lists.cfm/link=i:4:193129 Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4 Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4 Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4 Donations Support: http://www.houseoffusion.com/tiny.cfm/54
Re: A brief question about lists
Thank you all who answered! This list would probably be up to 350 items.. so I was thinking that might be a bit much. I suspect if I dig around with the SQL a bit more, I can get the results I desire... Yves On Fri, 4 Feb 2005 14:54:08 -0500, Jim Davis [EMAIL PROTECTED] wrote: -Original Message- From: Yves Arsenault [mailto:[EMAIL PROTECTED] Sent: Friday, February 04, 2005 2:43 PM To: CF-Talk Subject: A brief question about lists Hello, I was wondering if there are any guidelines, or limits in how many items can be in a list in a CF variable. I don't believe there is a limit (beyond hardware system limits) for size. I once ran a code challenge to tally the number of words in an arbitrary piece of text (for example the appears 35 times, We appears 3 times, etc) This was in CF 4.5/5.0 at the time (but I don't think it mattered) but one of the entries treated the text as a space-delimited list and looped over it. It worked just fine (and was actually one of the fastest entries) with text strings as large as the full novel Call of the Wild. I've also successfully done log file parsing in CF treating log files (even large ones) as carriage-return-delimited lists. In other words list can be very, very large. ;^) Jim Davis ~| Discover CFTicket - The leading ColdFusion Help Desk and Trouble Ticket application http://www.houseoffusion.com/banners/view.cfm?bannerid=48 Message: http://www.houseoffusion.com/lists.cfm/link=i:4:193133 Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4 Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4 Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4 Donations Support: http://www.houseoffusion.com/tiny.cfm/54
Re: A brief question about lists
Hi Jim, And the results processed fairly quickly? Even with the log files? Thanks, Yves On Fri, 4 Feb 2005 14:54:08 -0500, Jim Davis [EMAIL PROTECTED] wrote: -Original Message- From: Yves Arsenault [mailto:[EMAIL PROTECTED] Sent: Friday, February 04, 2005 2:43 PM To: CF-Talk Subject: A brief question about lists Hello, I was wondering if there are any guidelines, or limits in how many items can be in a list in a CF variable. I don't believe there is a limit (beyond hardware system limits) for size. I once ran a code challenge to tally the number of words in an arbitrary piece of text (for example the appears 35 times, We appears 3 times, etc) This was in CF 4.5/5.0 at the time (but I don't think it mattered) but one of the entries treated the text as a space-delimited list and looped over it. It worked just fine (and was actually one of the fastest entries) with text strings as large as the full novel Call of the Wild. I've also successfully done log file parsing in CF treating log files (even large ones) as carriage-return-delimited lists. In other words list can be very, very large. ;^) Jim Davis ~| Logware (www.logware.us): a new and convenient web-based time tracking application. Start tracking and documenting hours spent on a project or with a client with Logware today. Try it for free with a 15 day trial account. http://www.houseoffusion.com/banners/view.cfm?bannerid=67 Message: http://www.houseoffusion.com/lists.cfm/link=i:4:193135 Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4 Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4 Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4 Donations Support: http://www.houseoffusion.com/tiny.cfm/54
RE: A brief question about lists
-Original Message- From: Yves Arsenault [mailto:[EMAIL PROTECTED] Sent: Friday, February 04, 2005 3:32 PM To: CF-Talk Subject: Re: A brief question about lists Hi Jim, And the results processed fairly quickly? Even with the log files? Well - the log file stuff I only did in CF 4.5. They were quick enough, but the processing was vastly more complicated than just looping over the list (the logs were made up of many values, some of which where WDDX packets that had to be dealt with and each row could result in several database writes). But still - the performance was acceptable (and by that I mean a big file could take 10 or 20 minutes to process). CFMX is, on average, about 2-4 times faster than CF 4.5 (sometimes less, but mostly more). Also since list management code was some of the oldest in CF (even in CF 5.0 some of that code dated back to CF 2.0) it got a lot of attention in CFMX - it's actually PDQ right now. Depending on your lit contents 350 items really shouldn't be a problem for most apps. You'd probably be able to do things quicker, but sometimes fast enough is good enough. ;^) What matters more, to me, is how often the code is run and how visible it is. A log-file processor that (like mine) ran once a day at 2AM as an automated process doesn't really need to be super-optimized. But a process that runs every request or could cause a user to wait for a while should be looked at seriously. I would try out a sample and time it using getTickCount() - my guess is that you'll be pleasantly surprised. Jim Davis ~| Discover CFTicket - The leading ColdFusion Help Desk and Trouble Ticket application http://www.houseoffusion.com/banners/view.cfm?bannerid=48 Message: http://www.houseoffusion.com/lists.cfm/link=i:4:193148 Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4 Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4 Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4 Donations Support: http://www.houseoffusion.com/tiny.cfm/54