Forum OpenACS Development: Re: script that moves sql from tcl to xql files

Posted by Gustaf Neumann on
concerning "code did not work when query was in tcl but worked in xql": if it is so, this would be a clear bug. if you are able to reproduce it, please enter an entry to the bug-tracker.

A nasty problem might be the following: when the query specified both in the .tcl and .xql file, then the query in xql has higher precedence. Therefore it could be completely misleading to read and maybe modify the query in the tcl code (changes have no effect), but modifying the query in xql "works".

The actual reuse of sql queries in different procs is very little, at least in the most common 80 packages. i observed the rather opposite that the same sql query is repeated in multiple .xql files: i remember this since i had to fix the same problems multiple times.