Categories > TinyButStrong general >

an idea for a future release

The forum is closed. Please use Stack Overflow for submitting new questions. Use tags: tinybutstrong , opentbs
By: powerpop
Date: 2004-07-03
Time: 20:42

an idea for a future release

i have found a few places in my application where i want access to the data that tbs looks up in the database - right now i have to either do the db lookup myself, build and array and send in the data or i have to do a second lookup in the db

here is a question - does tbs build its own array internally when filling out a MergeBlock?

if so it might be nice to have a pre-Merge call that builds the array and sends it back to be used - and then the Merge call can get the array back and fill in the fields

if MergeBlock doesnt build its own array then it would still be useful to have an option for tbs to send back and array with the data at the end of the Merge operation - i often find i need the data for logistical decisions on other parts of my template

anyway - just a suggestion

(the other one being, of course, to allow LIMIT in mySQL quearies - i tend to need them everywhere and it takes away the key advantages of tbs, having the db calls built in - right now i have to make my own array and then can tbs with that array - but that is the same way smarty works, which is lame)
By: Skrol29
Date: 2004-07-04
Time: 23:36

Re: an idea for a future release

TBS doesn't build its own data array internally. It calls record after record and doesn't save them.

But it would be easy for TBS to return the array of records after a MergeBlock. I will study the idea.
But if your need the data after or even before the MergeBlock, don't forget that you can build you own data array, and use it for MergeBlock.

About the LIMIT clause for queries: TBS is not able and won't be able to manage it for you, even in the By-Page mode. But you can add it yourslef using it in your queries.