User roster from DB

I’‘m integrating jabber (on Wildfire server) with my website. It’‘s a social site thats helps to make new friends for old single people. Every sie user could make a list of friends amd I’'d like to this friend list (managed by site profile) woold be also jabber roster. Is there any way to change roster from SQL query, and if yes how can I do it ?