Use vba to write data into the SQL server 2008 r2, want to have the type of data columns, from varchar (MAX) type converted to a decimal number, but export to several are changed, a lot of times larger, solving
CodePudding user response:
Deposit in CStr function converts the original digital type to string type deposit varchar fieldRead again when using Int function converts a string type numeric type
Such as:
The written
.
Rs! F_str=CStr (123)
.
Read the
Dm rs_int as integer
.
Rs_int=int (rs! F_str & amp; "")
.
CodePudding user response: