[Zope] passing a zope <dtml-in...> list element to a sql method

Dylan Reinhardt zope at dylanreinhardt.com
Mon Sep 29 11:25:25 EDT 2003


On Mon, 2003-09-29 at 02:05, Roger Mallett wrote:
<snip>
> <dtml-call name="sql_delete_a_category(trash='<dtml-var test_item>')">

I doubt you want to pass a *string* representing a DTML tag... more
likely, you wanted to pass the *value* of the variable, yes?  

> delete from categories where category = '<dtml-var name="trash"
sql_quote>' 

Here, your syntax is wrong. There is no "name" property of a DTML tag.

Try these in their respective spots:

<dtml-call name="sql_delete_a_category(trash=test_item)">

delete from categories where category = '<dtml-var trash sql_quote>' 

HTH,

Dylan





More information about the Zope mailing list