Arjan Scherpenisse wrote:
Hi everybody,
This is my first posting to this list. I have a website which will make use of a calender, with events on it stored in a MySQL database. Now, i wondered how to efficiently show this data from the database in the calender. I mean, not in a way that a sql query is made for each day on the calender (which would make up to 31 queries in the Calender Tag 'month' view...)
So i wondered, is there some way to 'cache' the result of the SQL method, so that i can use just one query to fill up an entire month, for instance?
welcome to zopeland. SQL methods automatically cache themselves (check the advanced screen under /manage of the SQL method in question). unless you're passing in different arguements for each day, in which case you're probably better off retrieving all the calendar events at once you should have to worry about it. if you have any questions how, send me a copy of the schema for the tables. there is a tradeoff for ram but unless you have a large calendar it shouldn't make a difference. cheers Kapil
regards, -- Arjan Scherpenisse acscherp@wins.uva.nl
may the source be with you === http://www.gnu.org ===
_______________________________________________ Zope maillist - Zope@zope.org http://lists.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope-dev )