Commit 90a2054a authored by Jean-Paul Smets's avatar Jean-Paul Smets

improved by jps : 10 x faster


git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@85 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent d1c603e1
......@@ -12,28 +12,17 @@ sort_on</params>
SELECT
cell.uid, cell.Id, cell.path, cell.Description, movement.variation_text
FROM
catalog AS cell, catalog AS line, movement
catalog as cell, movement
WHERE
((
cell.parent_uid = line.uid
AND
line.parent_uid = <dtml-sqlvar uid type="int">
movement.delivery_uid = <dtml-sqlvar uid type="int">
AND
movement.uid = cell.uid
AND
movement.is_accountable = 1
)
OR
(
line.parent_uid = <dtml-sqlvar uid type="int">
AND
line.uid = cell.uid
AND
movement.uid = cell.uid
cell.portal_type <> "Simulation Movement"
AND
movement.is_accountable = 1
))
AND cell.portal_type <> "Container"
cell.portal_type <> "Container"
<dtml-if sort_on>ORDER BY
<dtml-var sort_on>
</dtml-if>
\ No newline at end of file
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment