ministry_directory_listing_categories.ministry_directory_category_reference = 10 AND
ministry_directory_listing_categories.ministry_directory_category_reference = 11
Can a record really have a reference for two different id's like this? ie can it be both '10' and '11' at the same time?
What's actually in the table for ministry_directory_listing_categories for this record?
For long table names, I'd also suggest using a table alias to make it easier to read/write:
select * from table1 as a inner join table2 as b using(id)
where a.field_name='1' and b.fieldname='5';
saves you having to write out 'ministry_directory_listing_categories' and 'ministry_directory'.
--
Postgresql & php tutorials
http://www.designmagick.com/