Real Estate Sales



SELECT node.nid as nid, node.title as ptitle , min(content_type_property.field_sale_min_amount) as NR , min(content_type_property.field_sale_max_amount) as NR_max, content_type_property.field_property_ispor_value as POR FROM node inner join term_node tn on (tn.nid=node.nid) inner join term_data td on (tn.tid=td.tid) LEFT JOIN content_field_r_property RP ON node.nid = RP.field_r_property_nid LEFT JOIN content_type_property ON node.vid = content_type_property.vid WHERE node.status <> 0 AND node.type = 'property' and (td.vid=1) and (td.tid = 3) GROUP BY node.nid ORDER BY POR ASC, NR ASC, NR_max ASC
Slide 2