views:

151

answers:

0

Hi there,

Here is something I'm trying to achieve using Apache Torque (3.3): Table 1: id f_id start_position end_position

Table 2: id f_id start end

I need to do: select * from table1 inner join table2 on table1.f_id = table2.f_id and ( (table1.start_position <= table2.start and table1.end_position >= table2.end) or (table1.start_position >= table2.start and table1.end_position <= table2.end) )

Is there a way to write this query up using Torque Criteria?

Thanks in advance!

David