Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Join us in Bucharest on Sept 18th for Qlik's AI Reality Tour! Register Now
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

Manage MSSQL Identity field with tCreateTable

Hi
I'm trying to make a INT identity field with autoincrement but I get this error :

Exception in component tCreateTable_1 (File_rotate)
java.lang.RuntimeException: Creating table failed
	at swiss_project.file_rotate_0_1.File_rotate.tCreateTable_1Process(File_rotate.java:1215)
	at swiss_project.file_rotate_0_1.File_rotate.tFileInputXML_1Process(File_rotate.java:14346)
	at swiss_project.file_rotate_0_1.File_rotate.tFileList_1Process(File_rotate.java:15702)
	at swiss_project.file_rotate_0_1.File_rotate.runJobInTOS(File_rotate.java:19262)
	at swiss_project.file_rotate_0_1.File_rotate.main(File_rotate.java:18988)
Caused by: java.sql.SQLException: Identity column 'AST00' contains invalid INCREMENT.
	at net.sourceforge.jtds.jdbc.SQLDiagnostic.addDiagnostic(SQLDiagnostic.java:372)
	at net.sourceforge.jtds.jdbc.TdsCore.tdsErrorToken(TdsCore.java:2988)
	at net.sourceforge.jtds.jdbc.TdsCore.nextToken(TdsCore.java:2421)
	at net.sourceforge.jtds.jdbc.TdsCore.getMoreResults(TdsCore.java:671)
	at net.sourceforge.jtds.jdbc.JtdsStatement.processResults(JtdsStatement.java:613)
	at net.sourceforge.jtds.jdbc.JtdsStatement.executeSQL(JtdsStatement.java:572)
	at net.sourceforge.jtds.jdbc.JtdsStatement.executeImpl(JtdsStatement.java:809)
	at net.sourceforge.jtds.jdbc.JtdsStatement.execute(JtdsStatement.java:1282)
	at swiss_project.file_rotate_0_1.File_rotate.tCreateTable_1Process(File_rotate.java:1203)
	... 4 more





0683p000009Lytk.pngThanks in advance

 

 

Labels (5)
1 Solution

Accepted Solutions
iamabhishek
Creator III
Creator III

You would have to specify the precision too for INT IDENTITY. Just mention Length = 1 & Precision = 1 which would be Seed & Increment respectively.
Also, you have mentioned db type variables as NCHAR but Talend type as Integer. You need to change them too.

View solution in original post

2 Replies
iamabhishek
Creator III
Creator III

You would have to specify the precision too for INT IDENTITY. Just mention Length = 1 & Precision = 1 which would be Seed & Increment respectively.
Also, you have mentioned db type variables as NCHAR but Talend type as Integer. You need to change them too.
Anonymous
Not applicable
Author

Not logic at all but it work. Thanks !