- Here is a link to SQL Server Data Type Mappings documentation that I found helpful in understanding how SQL data types map to .NET data types and what SQL DataReader typed accessor (e.g., GetString and GeBoolean) is needed to read a particular SQL data type from within .NET.
- A good link on how the retrieve the Microsoft SQL rowversion/timestamp value from the standard IDataReader interface. Below is how I implemented.
byte[] rowVersionBuffer = new byte[8];
dataReader.GetBytes(rowVersionField_OrdinalValue, 0, rowVersionBuffer, 8); // rowversion storage size is 8 bytes. timestamp is a synonym for rowversion.
businessObject.RowVersion = rowVersionBuffer;
// business object rowversion/timestamp property
private byte[] _RowVersion
public byte[] RowVersion
{
get { return _RowVersion;}
set { _RowVersion = value; }
}
- jsfiddle A tool to test HTML, CSS, and JavaScript.
5e19a19c-bd2e-4ae7-a576-f18a89e52ff4|0|.0
I was working on a Visual Studio 2010 VB.Net Windows Service application. I added a reference to an in-house IO library and then used the Imports keyword to import the namespace from the referenced assembly. IntelliSense recognized the namespace and I had access to the methods in the IO library.
I then tried to compile the application. It failed. My Imports statement for the IO library and the methods I used with that library generated error messages. Along with the errors, I noticed a warning message. The warning message provided the clue to the solution. It mentioned that the referenced IO assembly could not be resolved because it had a dependency on System.Data.OracleClient.
Here is the link where I found the solution (thanks Xiaoyu!). It turns out that when I added the new Windows Service project, the targeted framework was for the .NET Framework 4 Client Profile. That framework does not include the System.Data.OracleClient.dll.
The fix: Change the target framework to .NET Framework 4 (Project Properties -> Compile tab -> Advanced Compile Options… -> Target framework drop down).
f21289cc-c1f1-4b1d-8edf-fea745ac3717|0|.0