search cancel

SQL read records component error: System.Data.SqlClient.SqlException (0x80131904): Incorrect syntax near the keyword 'rollback'.

book

Article ID: 162213

calendar_today

Updated On:

Products

Workflow Solution

Issue/Introduction

When SQL reserved words are used in any of the SQL objects, a component created with Table Generator will fail with a syntax error. System.Data.SqlClient.SqlException (0x80131904): Incorrect syntax near the keyword 'rollback'.

Cause

SQL reserved words require placing brackets or quotes around them.

 

Resolution

'Add brackets to table name' option can be used specifically for table names and 'Use Quoting' option can be used for column names to avoid syntax errors during component execution.
Below is an example screenshot of how this can be configured in Table generator wizard.

The list of SQL reserved words can be found in the link below:
https://msdn.microsoft.com/en-us/library/ms189822.aspx

Attachments