in reply to Module for substituting complex criteria into hand-written SQL queries
# Just generate the WHERE clause my($stmt, @bind) = $sql->where(\%where, $order); [download]
Just plug that into your own SQL.