Developing a VBScript Class for an Extremely Lightweight Recordset Alternative - Concluding Thoughts (Page 5 of 5 )
Some Anticipatory Objections
Is this solution revolutionary? Not really. It serves the purpose it was meant for: to let me drop read-only ADO Recordsets as soon as I could to free up resources, without sacrificing speed or functionality. And as I worked on it, I found I actually gained functionality. My entire purpose in this article was to put before you the techniques I used, the discoveries I made, and the results of that work. But if I may, I'd like to address some arguments I foresee in this articleís "Comments" tab over the coming week or two:
Why not compile it?
Overhead. The thing is so light, and its performance is quite satisfactory, why incur all the effort of non-VBScript object instantiation?
It doesnít handle shaped Recordsets (i.e. Recordsets within Recordsets).
Thatís right. In my ASP work I use these so rarely compared to plain old "flat" Recordsets it wasnít worth the effort. It could be done, but it's not something I suspect I'll spend the time to do.
This is only good for read-only Recordsets, though!
True. As I explained, I was inspired to build this because the vast majority of the Recordsets I use are read-only, and used just for HTML output. If I needed to edit data, I would certainly not use an ArraySet.
Your persisting mechanism uses the Session variable? Don't you know Session variables are evil?
The chief downside of the Session variable is that it's ineffective on multi-server sites, because we can't expect each user's requests to always hit the same machine. Quite true, and for that reason, you would not want to use it here. However, for single-server sites Ė and though we'd like to impress our peers, folks, admit it: most of our ASP sites are single-server Ė it works just fine.
Your solution doesnít use XML. If something doesnít use XML itís stupid. My cat uses XML. I can write XSLTs that convert meatloaf into wicker furniture. XML is de riguer, XML is mandatory, XML etc.
ASP.NET provides the HumperDingleFloogleHorn class that provides exactly this functionality. You should just upgrade your entire application to .NET instead, and be cool like me.
Iíll get right on it.
You say you donít use those other ### field properties, but I use two of them that you donít. Therefore I'm smarter than you and deem your techniques valueless, misguided and laughable.
The design is pretty simple to extend, so go for it. I'll look forward to your article on the matter.
In any caseÖ
Please feel free to use the downloadable version of this file as you will. It contains essentially the same code discussed here, plus a bit more error-checking. If you make enhancements to it, I'd be glad to hear about them! I can be reached at Kelleher@tkelleher.com.
DISCLAIMER: The content provided in this article is not warranted or guaranteed by Developer Shed, Inc. The content provided is intended for entertainment and/or educational purposes in order to introduce to the reader key ideas, concepts, and/or product reviews. As such it is incumbent upon the reader to employ real-world tactics for security and implementation of best practices. We are not liable for any negative consequences that may result from implementing any information covered in our articles or tutorials. If this is a hardware review, it is not recommended to open and/or modify your hardware.