Difference between revisions of "CSharp:Conversioni da MS SQL"
From Aino Wiki
(No difference)
|
Latest revision as of 06:47, 25 September 2014
Elenco casuale
Da MS SQL | C# | Commento |
---|---|---|
SqlDouble | Double |
Se x è SqlDouble => Double y = (Double)x; GeoPoint gp = new GeoPoint(); gp.Latitude = (double)shipGPSPosition.GeoPosition.STY; gp.Longitude = (double)shipGPSPosition.GeoPosition.STX; oppure GeoPoint gp = new GeoPoint(); gp.Latitude = shipGPSPosition.GeoPosition.STY.Value; gp.Longitude = shipGPSPosition.GeoPosition.STX.Value; |
row 2, cell 1 | row 2, cell 2 | row 2, cell 3 |
Tabella Conversione Dot Net verso MS SQL e viceversa:
// Boolean = 4 byte bit // Byte = 1 byte TinyInt // Char = 2 byte // Date = 8 byte DateTime // Decimal = 12 byte Numeri con la virgola + e - // Double = 8 byte Numeri con la virgola + e - Money // Integer = 4 byte = Int32 Int // Log = 8 byte = Int64 BigInt // Object = 4 byte // Short = 2 byte = Int16 SmalInt // Single = 4 byte Numeri con la virgola + e - SmallMoney // String = 10 byte + (2 *lunghezza stringa) Caratteri UniCode