[ticket/11445] optimize number of queries in get_global_subscriptions

http://tracker.phpbb.com/browse/PHPBB3-11445
PHPBB3-11445