Paste the complete error including the 'near ...' fragment — it pinpoints the failure location. Include the query; most SQL syntax errors are visible in context.