[Zope] Binding Formulator Dropdown List to SQL Result Set

Satheesh Babu vattekkat.babu at verizon.net
Sun Dec 28 09:21:34 EST 2003


Hi,

You need to put form/getProvinces in the TALES->Items field.

Also, please note that Formulator Items are a list with each item like 
(displayed value, option value). So, if your query is select code, name 
from provinces, the form field generated will be like
<option value="name">code</option>

which may not be what you need; (if you do want to go back to the 
datbase with code; you want the form to be like <option 
value="code>name</option>)

So, you might want to make your query like select name, code from provinces.

- Babu
http://vsbabu.org/

CLIFFORD ILKAY wrote:
> Hi,
> 
> I would like to bind the result of the following SQL query to a 
> Formulator dropdown list.
> 
> select code, name from provinces;
> 
> How would I do that?
> 
> Regards,
> 
> Clifford Ilkay
> Dinamis Corporation
> 3266 Yonge Street, Suite 1419
> Toronto, Ontario
> Canada M4N 3P6
> 
> Tel: 416-410-3326
> 
> _______________________________________________
> Zope maillist  -  Zope at zope.org
> http://mail.zope.org/mailman/listinfo/zope
> **   No cross posts or HTML encoding!  **
> (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce
> http://mail.zope.org/mailman/listinfo/zope-dev )
> 




More information about the Zope mailing list