On Fri, Apr 24, 2015 at 9:06 AM, Greg Spiegelberg <gspiegelberg@xxxxxxxxx> wrote:
LINE 3: SELECT COALESCE(ts1.user_id, ts2,user_id, ts3.user_id) AS us...
You want ts2.user_id not ts2,user_id