[Zope] Connection to MySQL in zope product

J Cameron Cooper zope-l at jcameroncooper.com
Mon Mar 14 01:11:01 EST 2005


Andreas Jung wrote:
> 
> 
> --On Sonntag, 13. März 2005 19:11 Uhr -0800 bahriesz at yahoo.com wrote:
> 
>> Hi,
>>
>> I plan to develop a product that make use of external
>> database (MySQL). I tried to get some reference on
>> this in internet, but to no avail. How can i do this?.
>>
>> I understand that with python script or dtml we need
>> to create database connection object, and zsql method.
>> But how do we do it from product class?.
> 
> For a CMF or Plone project you can put your ZSQL methods into a skins
> folder (as files *.zsql). They are recognized automatically a ZSQL 
> methods and be
> be re-used through the standard acquistion magic as any other method.
> Creating ZSQL methods as methods of a Zope product is somewhat un-common
> but it can be done afaik by instantiating ZSQL methods (using their API 
> which can
> be found from the sources).

See for some help with this http://www.zope.org/Members/jccooper/extzsql

		--jcc



More information about the Zope mailing list