Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Errors in SQLServer.ttinclude #32

Open
javieruy opened this issue Sep 30, 2009 · 0 comments
Open

Errors in SQLServer.ttinclude #32

javieruy opened this issue Sep 30, 2009 · 0 comments

Comments

@javieruy
Copy link

In the method string GetSysType(string sqlType) some types are missing:

the type text, and the type timestamp are missing.

The method should be:

string GetSysType(string sqlType){
string sysType="string";
switch (sqlType) {
case "bigint":
sysType = "long";
break;
case "smallint":
sysType= "short";
break;
case "int":
sysType= "int";
break;
case "uniqueidentifier":
sysType= "Guid";
break;
case "smalldatetime":
case "datetime":
sysType= "DateTime";
break;
case "float":
sysType="double";
break;
case "real":
case "numeric":
case "smallmoney":
case "decimal":
case "money":
sysType= "decimal";
break;
case "tinyint":
sysType= "int";
break;
case "bit":
sysType= "bool";
break;
case "image":
case "binary":
case "varbinary":
sysType= "byte[]";
break;
case "text":
sysType= "string";
break;
case "timestamp":
sysType= "byte[]";
break;

}
return sysType;

}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant