RE: [Zope] sorting SQL results with dtml-in - not working
Tried this change but I still do not get correct sorting. Like I said, every time you click to sort, the results are always different. -----Original Message----- From: Oleg Broytmann [mailto:phd@phd.pp.ru] Sent: Friday, June 28, 2002 12:26 PM To: Kelley, Sean Cc: 'zope@zope.org' Subject: Re: [Zope] sorting SQL results with dtml-in - not working On Fri, Jun 28, 2002 at 11:07:05AM -0700, Kelley, Sean wrote:
<dtml-in list_all_records sort="<dtml-var order> reverse" size=10 start=query_start>
For whatever reason, I am getting weird results. I am still pretty weak at dtml so I am not seeing why.
Because you should not nes DTML inside DTML. What is inside "" must be Python. <dtml-in list_all_records sort="order" reverse size=10 start=query_start> Oleg. -- Oleg Broytmann http://www.zope.org/Members/phd/ phd@email.ru Programmers don't die, they just GOSUB without RETURN.
On Fri, Jun 28, 2002 at 01:32:28PM -0700, Kelley, Sean wrote:
Tried this change but I still do not get correct sorting. Like I said, every time you click to sort, the results are always different.
<dtml-in list_all_records sort="order" reverse size=10 start=query_start>
Hmm... try <dtml-in list_all_records sort_expr=order reverse size=10 start=query_start> This *evalute* "order" before sorting. Oleg. -- Oleg Broytmann http://www.zope.org/Members/phd/ phd@email.ru Programmers don't die, they just GOSUB without RETURN.
Kelley, Sean writes:
Tried this change but I still do not get correct sorting. Like I said, every time you click to sort, the results are always different. Always different results indicate that you do something really strange.
I would understand "always equal" because in fact, you want "sort_expr" rather than "sort".
.... <dtml-in list_all_records sort="order" reverse size=10 start=query_start>
Dieter
participants (3)
-
Dieter Maurer -
Kelley, Sean -
Oleg Broytmann