How to get rooms that I am a member of?
We would like to create a customized IQ that to quickly get all the rooms that I am a member of. I wonder what would be the best way to write a query to fetch these room JIDs, give a user JID?
The tigase DB tables is a bit hard to understand, I finally managed to write a query like this:
select node as roomname from tig_nodes where nid in (select parent_nid from tig_nodes where nid in (select nid from tig_pairs where email@example.com' and pval <> 'outcast') )
This query looks horrible to me and must be very inefficient.... Would really appreciate if you could advise that what's the best way to query "my-rooms"