Click here to Skip to main content
15,917,610 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
incorrect syntax near DEFAULT expception fires when executing following SQL query in c#

mycmd.CommandText = "ALTER TABLE ems_db1.dbo.table_D" + cntDevice + " ADD " + parameters[j] + " DOUBLE DEFAULT NULL";
Posted
Updated 17-Nov-15 23:38pm
v3

1 solution

Try
SQL
FLOAT DEFAULT NULL

instead.

For your information, here's the page where you can get informations about SQL datatypes:
Data Types (Transact-SQL)[^]
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900