I am working on creating a bunch of classes to deal with a SQL Database..my question is what is the best way to design these in terms of using Variables and Properties? For Example..
I am wondering, am I on the road to bad practices?
Thanks
Code:
Private conString As String = "Database=Contracts; data source=DATA\MASTER;Integrated Security=SSPI"
Private SQLcn As New SqlClient.SqlConnection(conString)
Private SQLda As SqlClient.SqlDataAdapter
Private SQLdt As DataTable
Private SQLds As DataSet
Private SQLdr As SqlClient.SqlDataReader
Private SQLdrw As DataRow
Private myDataSet As DataSet
Property SQLCmdText() As String
Get
Return mySQLCmd
End Get
Set(ByVal Value As String)
mySQLCmd = Value
End Set
End Property
Property MySQLdt() As DataTable
Get
Return SQLdt
End Get
Set(ByVal Value As DataTable)
End Set
End Property
methods etc...
I am wondering, am I on the road to bad practices?
Thanks