@@ -5,7 +5,7 @@ C#/VB.NET database utility to comfortly write pure Microsoft SQL/MySQL queries a
5
5
``` vb
6
6
' create active record class extending DbSharp.Model:
7
7
Public Class Dealer
8
- Inherits Database .Model
8
+ Inherits DbSharp .Model
9
9
Public Id As Int32?
10
10
Public Property Firstname As String
11
11
Public Property Secondname As String
@@ -35,8 +35,8 @@ Dim dct As Dictionary(Of Int32, Dealer) = Command.Prepare(
35
35
```
36
36
37
37
``` cs
38
- ' create active record class extending DbSharp.Model:
39
- public class Dealer : Database .Model {
38
+ // create active record class extending DbSharp.Model:
39
+ public class Dealer : DbSharp .Model {
40
40
public int ? Id ;
41
41
public string Firstname { get ; set ; }
42
42
public string Secondname { get ; set ; }
@@ -49,16 +49,16 @@ Dealer instance = Command.Prepare(
49
49
id = 5
50
50
}).ToInstance <Dealer >()
51
51
52
- ' load all dealers with id higher than 5 into list
52
+ // load all dealers with id higher than 5 into list
53
53
List < Dealer > list = Command .Prepare (
54
54
" SELECT * FROM Dealers WHERE Id > @id"
55
55
).FetchAll (new {
56
56
id = 5
57
57
}).ToList <Dealer >()
58
58
59
- ' load all dealers with id higher than 5 into dictionary
60
- ' and complete dictionary keys by Id column
61
- Dim dct As Dictionary < Int32 , Dealer > = Command .Prepare (
59
+ // load all dealers with id higher than 5 into dictionary
60
+ // and complete dictionary keys by Id column
61
+ Dictionary < Int32 , Dealer > dct = Command .Prepare (
62
62
" SELECT * FROM Dealers WHERE Id > @id"
63
63
).FetchAll (new {
64
64
id = 5
0 commit comments