Why does a field not create a SQL statement value of single quotes if I assign spaces to it in C# using VS2010?
I am developing a C# application using VS2010.
I have the attached input file that I am using to read records from. There is only 1 record in this input file.
My application builds up a SQL Statement based on the input fields that are read by my application but I don't understand why the 8th field (field titled recordnum) does not generate single quotes in the SQL Statement that is built since there is a null value in the input field. The first field (bankNum) does not have a value in the input file yet it generated single quotes in the SQL Statement as I suspected it would.
To recap, the 1st and 8th field both have no value yet the 1st field is converted to single quotes in the build SQL Statement while the 8th field does not generate single quotes. The output is blank (not single quotes) for the 8th field and thus creates an erroneous SQL Statement.
Error 1 'string' does not contain a definition for 'HasValue' and no extension method 'HasValue' accepting a first argument of type 'string' could be found (are you missing a using directive or an assembly reference?) \\msad\root\na\ny\users\zimmermj\visual studio 2010\Projects\SMRWebForm\SMRWebForm\SMRWebForm1.aspx.cs 119 43 SMRWebForm
.NET Programming
The .NET Framework is not specific to any one programming language; rather, it includes a library of functions that allows developers to rapidly build applications. Several supported languages include C#, VB.NET, C++ or ASP.NET.