• Thanks for fixing this bug.

    I didn't put this into a stored procedure, because it's already isolating the current database (DB_ID() part)

    The incorrect syntax issue is indeed caused by the web.

    Wilfred
    The best things in life are the simple things