vb.net - Compare value with a DataType to see if it accepted -


issue


i have method used check values see if accepted datatype in database column.

i have list of values added database , list of datatype's table added to, , want make sure when run stored procedure add values values correct.

code


private function checkalldatatypes(formatteddate string, sstring string(), file fileinfo) boolean      using dbconn rgsdb2.dbconnection = dataconnections.dbconnection()         tabledatatypes = dataconnections.executequery_singleresultsetwithparams("selltabledatatypes", dbconn, params)     end using      each item string in sstring         //i want compare values in sstring tabledatatypes.     next  end function 

example


so lets see table columns wanting add int,varchar,varchar , values in sstring 3,"testing",3.

this should fail 3 not string.

use regex in testing loop check numbers strings if don't want consider them string.

integers can strings need check being "alone" were. might 3 should not treated string hard pressed "te5t1ng" shouldn't treated 100% string.


Comments

Popular posts from this blog

Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.12:test (default-test) on project.Error occurred in starting fork -

windows - Debug iNetMgr.exe unhandle exception System.Management.Automation.CmdletInvocationException -

unity3d - Fatal error- Monodevelop-Unity failed to start -