The matching always checked the default database when it should only check it if there are no tables in the statement.