You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
428 lines
14 KiB
428 lines
14 KiB
' ///////////////////////////////////////////////////////////////////////////
|
|
' // Description: Data Access class for the table 'ZVBelege_data'
|
|
' // Generated by LLBLGen v1.2.1045.38210 Final on: Samstag, 28. August 2004, 09:27:01
|
|
' // Because the Base Class already implements IDispose, this class doesn't.
|
|
' ///////////////////////////////////////////////////////////////////////////
|
|
Imports System
|
|
Imports System.Data
|
|
Imports System.Data.SqlTypes
|
|
Imports System.Data.SqlClient
|
|
|
|
Namespace edokadb
|
|
' /// <summary>
|
|
' /// Purpose: Data Access class for the table 'ZVBelege_data'.
|
|
' /// </summary>
|
|
Public Class clsZVBelege_data
|
|
Inherits clsDBInteractionBase
|
|
|
|
#Region " Class Member Declarations "
|
|
|
|
Private m_daInsertTimestamp, m_daValdat As SqlDateTime
|
|
Private m_fBetrag As SqlDouble
|
|
Private m_sNRPAR00, m_sNEVVG02, m_sCDWAEAI, m_sBTBET00, m_sNRAUF00, m_sDMARC00, m_sNEVVG00, m_sNRPOS00, m_sNRREF00, m_sCDZAH00, m_sCDVARC00, m_sNRDOT00, m_sBEEAD00, m_sNRPCK00, m_sBESAD00, m_sDMVAL00, m_sNRDOC00, m_sNRBCL00, m_sNEVVG01 As SqlString
|
|
|
|
#End Region
|
|
|
|
|
|
' /// <summary>
|
|
' /// Purpose: Class constructor.
|
|
' /// </summary>
|
|
Public Sub New()
|
|
' // Nothing for now.
|
|
End Sub
|
|
|
|
|
|
' /// <summary>
|
|
' /// Purpose: Insert method. This method will insert one new row into the database.
|
|
' /// </summary>
|
|
' /// <returns>True if succeeded, otherwise an Exception is thrown. </returns>
|
|
' /// <remarks>
|
|
' /// Properties needed for this method:
|
|
' /// <UL>
|
|
' /// <LI>sNRDOT00</LI>
|
|
' /// <LI>sBEEAD00. May be SqlString.Null</LI>
|
|
' /// <LI>sCDVARC00. May be SqlString.Null</LI>
|
|
' /// <LI>sNRREF00. May be SqlString.Null</LI>
|
|
' /// <LI>sCDZAH00. May be SqlString.Null</LI>
|
|
' /// <LI>sNRPCK00. May be SqlString.Null</LI>
|
|
' /// <LI>sNRBCL00. May be SqlString.Null</LI>
|
|
' /// <LI>sNEVVG01. May be SqlString.Null</LI>
|
|
' /// <LI>sNRDOC00</LI>
|
|
' /// <LI>sBESAD00. May be SqlString.Null</LI>
|
|
' /// <LI>sDMVAL00. May be SqlString.Null</LI>
|
|
' /// <LI>sCDWAEAI. May be SqlString.Null</LI>
|
|
' /// <LI>sBTBET00. May be SqlString.Null</LI>
|
|
' /// <LI>sNRPAR00. May be SqlString.Null</LI>
|
|
' /// <LI>sNEVVG02. May be SqlString.Null</LI>
|
|
' /// <LI>sNEVVG00. May be SqlString.Null</LI>
|
|
' /// <LI>sNRPOS00. May be SqlString.Null</LI>
|
|
' /// <LI>sNRAUF00</LI>
|
|
' /// <LI>sDMARC00. May be SqlString.Null</LI>
|
|
' /// <LI>daInsertTimestamp. May be SqlDateTime.Null</LI>
|
|
' /// <LI>daValdat. May be SqlDateTime.Null</LI>
|
|
' /// <LI>fBetrag. May be SqlDouble.Null</LI>
|
|
' /// </UL>
|
|
' /// Properties set after a succesful call of this method:
|
|
' /// <UL>
|
|
' /// <LI>iErrorCode</LI>
|
|
' /// </UL>
|
|
' /// </remarks>
|
|
Overrides Public Function Insert() As Boolean
|
|
Dim scmCmdToExecute As SqlCommand = New SqlCommand()
|
|
scmCmdToExecute.CommandText = "dbo.[pr_ZVBelege_data_Insert]"
|
|
scmCmdToExecute.CommandType = CommandType.StoredProcedure
|
|
|
|
' // Use base class' connection object
|
|
scmCmdToExecute.Connection = m_scoMainConnection
|
|
|
|
Try
|
|
scmCmdToExecute.Parameters.Add(New SqlParameter("@sNRDOT00", SqlDbType.VarChar, 50, ParameterDirection.Input, False, 0, 0, "", DataRowVersion.Proposed, m_sNRDOT00))
|
|
scmCmdToExecute.Parameters.Add(New SqlParameter("@sBEEAD00", SqlDbType.VarChar, 50, ParameterDirection.Input, True, 0, 0, "", DataRowVersion.Proposed, m_sBEEAD00))
|
|
scmCmdToExecute.Parameters.Add(New SqlParameter("@sCDVARC00", SqlDbType.VarChar, 50, ParameterDirection.Input, True, 0, 0, "", DataRowVersion.Proposed, m_sCDVARC00))
|
|
scmCmdToExecute.Parameters.Add(New SqlParameter("@sNRREF00", SqlDbType.VarChar, 50, ParameterDirection.Input, True, 0, 0, "", DataRowVersion.Proposed, m_sNRREF00))
|
|
scmCmdToExecute.Parameters.Add(New SqlParameter("@sCDZAH00", SqlDbType.VarChar, 50, ParameterDirection.Input, True, 0, 0, "", DataRowVersion.Proposed, m_sCDZAH00))
|
|
scmCmdToExecute.Parameters.Add(New SqlParameter("@sNRPCK00", SqlDbType.VarChar, 50, ParameterDirection.Input, True, 0, 0, "", DataRowVersion.Proposed, m_sNRPCK00))
|
|
scmCmdToExecute.Parameters.Add(New SqlParameter("@sNRBCL00", SqlDbType.VarChar, 50, ParameterDirection.Input, True, 0, 0, "", DataRowVersion.Proposed, m_sNRBCL00))
|
|
scmCmdToExecute.Parameters.Add(New SqlParameter("@sNEVVG01", SqlDbType.VarChar, 50, ParameterDirection.Input, True, 0, 0, "", DataRowVersion.Proposed, m_sNEVVG01))
|
|
scmCmdToExecute.Parameters.Add(New SqlParameter("@sNRDOC00", SqlDbType.VarChar, 50, ParameterDirection.Input, False, 0, 0, "", DataRowVersion.Proposed, m_sNRDOC00))
|
|
scmCmdToExecute.Parameters.Add(New SqlParameter("@sBESAD00", SqlDbType.VarChar, 50, ParameterDirection.Input, True, 0, 0, "", DataRowVersion.Proposed, m_sBESAD00))
|
|
scmCmdToExecute.Parameters.Add(New SqlParameter("@sDMVAL00", SqlDbType.VarChar, 50, ParameterDirection.Input, True, 0, 0, "", DataRowVersion.Proposed, m_sDMVAL00))
|
|
scmCmdToExecute.Parameters.Add(New SqlParameter("@sCDWAEAI", SqlDbType.VarChar, 50, ParameterDirection.Input, True, 0, 0, "", DataRowVersion.Proposed, m_sCDWAEAI))
|
|
scmCmdToExecute.Parameters.Add(New SqlParameter("@sBTBET00", SqlDbType.VarChar, 50, ParameterDirection.Input, True, 0, 0, "", DataRowVersion.Proposed, m_sBTBET00))
|
|
scmCmdToExecute.Parameters.Add(New SqlParameter("@sNRPAR00", SqlDbType.VarChar, 50, ParameterDirection.Input, True, 0, 0, "", DataRowVersion.Proposed, m_sNRPAR00))
|
|
scmCmdToExecute.Parameters.Add(New SqlParameter("@sNEVVG02", SqlDbType.VarChar, 50, ParameterDirection.Input, True, 0, 0, "", DataRowVersion.Proposed, m_sNEVVG02))
|
|
scmCmdToExecute.Parameters.Add(New SqlParameter("@sNEVVG00", SqlDbType.VarChar, 50, ParameterDirection.Input, True, 0, 0, "", DataRowVersion.Proposed, m_sNEVVG00))
|
|
scmCmdToExecute.Parameters.Add(New SqlParameter("@sNRPOS00", SqlDbType.VarChar, 50, ParameterDirection.Input, True, 0, 0, "", DataRowVersion.Proposed, m_sNRPOS00))
|
|
scmCmdToExecute.Parameters.Add(New SqlParameter("@sNRAUF00", SqlDbType.VarChar, 50, ParameterDirection.Input, False, 0, 0, "", DataRowVersion.Proposed, m_sNRAUF00))
|
|
scmCmdToExecute.Parameters.Add(New SqlParameter("@sDMARC00", SqlDbType.VarChar, 50, ParameterDirection.Input, True, 0, 0, "", DataRowVersion.Proposed, m_sDMARC00))
|
|
scmCmdToExecute.Parameters.Add(New SqlParameter("@daInsertTimestamp", SqlDbType.DateTime, 8, ParameterDirection.Input, True, 23, 3, "", DataRowVersion.Proposed, m_daInsertTimestamp))
|
|
scmCmdToExecute.Parameters.Add(New SqlParameter("@davaldat", SqlDbType.DateTime, 8, ParameterDirection.Input, True, 23, 3, "", DataRowVersion.Proposed, m_daValdat))
|
|
scmCmdToExecute.Parameters.Add(New SqlParameter("@fbetrag", SqlDbType.Float, 8, ParameterDirection.Input, True, 38, 0, "", DataRowVersion.Proposed, m_fBetrag))
|
|
scmCmdToExecute.Parameters.Add(new SqlParameter("@iErrorCode", SqlDbType.Int, 4, ParameterDirection.Output, True, 10, 0, "", DataRowVersion.Proposed, m_iErrorCode))
|
|
|
|
If m_bMainConnectionIsCreatedLocal Then
|
|
' // Open connection.
|
|
m_scoMainConnection.Open()
|
|
Else
|
|
If m_cpMainConnectionProvider.bIsTransactionPending Then
|
|
scmCmdToExecute.Transaction = m_cpMainConnectionProvider.stCurrentTransaction
|
|
End If
|
|
End If
|
|
|
|
' // Execute query.
|
|
scmCmdToExecute.ExecuteNonQuery()
|
|
m_iErrorCode = scmCmdToExecute.Parameters.Item("@iErrorCode").Value
|
|
|
|
If Not m_iErrorCode.Equals(New SqlInt32(LLBLError.AllOk)) Then
|
|
' // Throw error.
|
|
Throw New Exception("Stored Procedure 'pr_ZVBelege_data_Insert' reported the ErrorCode: " & m_iErrorCode.ToString())
|
|
End If
|
|
|
|
Return True
|
|
Catch ex As Exception
|
|
' // some error occured. Bubble it to caller and encapsulate Exception object
|
|
Throw New Exception("clsZVBelege_data::Insert::Error occured.", ex)
|
|
Finally
|
|
If m_bMainConnectionIsCreatedLocal Then
|
|
' // Close connection.
|
|
m_scoMainConnection.Close()
|
|
End If
|
|
scmCmdToExecute.Dispose()
|
|
End Try
|
|
End Function
|
|
|
|
|
|
' /// <summary>
|
|
' /// Purpose: SelectAll method. This method will Select all rows from the table.
|
|
' /// </summary>
|
|
' /// <returns>DataTable object if succeeded, otherwise an Exception is thrown. </returns>
|
|
' /// <remarks>
|
|
' /// Properties set after a succesful call of this method:
|
|
' /// <UL>
|
|
' /// <LI>iErrorCode</LI>
|
|
' /// </UL>
|
|
' /// </remarks>
|
|
Overrides Public Function SelectAll() As DataTable
|
|
Dim scmCmdToExecute As SqlCommand = New SqlCommand()
|
|
scmCmdToExecute.CommandText = "dbo.[pr_ZVBelege_data_SelectAll]"
|
|
scmCmdToExecute.CommandType = CommandType.StoredProcedure
|
|
Dim dtToReturn As DataTable = new DataTable("ZVBelege_data")
|
|
Dim sdaAdapter As SqlDataAdapter = new SqlDataAdapter(scmCmdToExecute)
|
|
|
|
' // Use base class' connection object
|
|
scmCmdToExecute.Connection = m_scoMainConnection
|
|
|
|
Try
|
|
scmCmdToExecute.Parameters.Add(new SqlParameter("@iErrorCode", SqlDbType.Int, 4, ParameterDirection.Output, True, 10, 0, "", DataRowVersion.Proposed, m_iErrorCode))
|
|
|
|
If m_bMainConnectionIsCreatedLocal Then
|
|
' // Open connection.
|
|
m_scoMainConnection.Open()
|
|
Else
|
|
If m_cpMainConnectionProvider.bIsTransactionPending Then
|
|
scmCmdToExecute.Transaction = m_cpMainConnectionProvider.stCurrentTransaction
|
|
End If
|
|
End If
|
|
|
|
' // Execute query.
|
|
sdaAdapter.Fill(dtToReturn)
|
|
m_iErrorCode = scmCmdToExecute.Parameters.Item("@iErrorCode").Value
|
|
|
|
If Not m_iErrorCode.Equals(New SqlInt32(LLBLError.AllOk)) Then
|
|
' // Throw error.
|
|
Throw New Exception("Stored Procedure 'pr_ZVBelege_data_SelectAll' reported the ErrorCode: " & m_iErrorCode.ToString())
|
|
End If
|
|
|
|
Return dtToReturn
|
|
Catch ex As Exception
|
|
' // some error occured. Bubble it to caller and encapsulate Exception object
|
|
Throw New Exception("clsZVBelege_data::SelectAll::Error occured.", ex)
|
|
Finally
|
|
If m_bMainConnectionIsCreatedLocal Then
|
|
' // Close connection.
|
|
m_scoMainConnection.Close()
|
|
End If
|
|
scmCmdToExecute.Dispose()
|
|
sdaAdapter.Dispose()
|
|
End Try
|
|
End Function
|
|
|
|
|
|
#Region " Class Property Declarations "
|
|
|
|
Public Property [sNRDOT00]() As SqlString
|
|
Get
|
|
Return m_sNRDOT00
|
|
End Get
|
|
Set(ByVal Value As SqlString)
|
|
Dim sNRDOT00Tmp As SqlString = Value
|
|
If sNRDOT00Tmp.IsNull Then
|
|
Throw New ArgumentOutOfRangeException("sNRDOT00", "sNRDOT00 can't be NULL")
|
|
End If
|
|
m_sNRDOT00 = Value
|
|
End Set
|
|
End Property
|
|
|
|
|
|
Public Property [sBEEAD00]() As SqlString
|
|
Get
|
|
Return m_sBEEAD00
|
|
End Get
|
|
Set(ByVal Value As SqlString)
|
|
m_sBEEAD00 = Value
|
|
End Set
|
|
End Property
|
|
|
|
|
|
Public Property [sCDVARC00]() As SqlString
|
|
Get
|
|
Return m_sCDVARC00
|
|
End Get
|
|
Set(ByVal Value As SqlString)
|
|
m_sCDVARC00 = Value
|
|
End Set
|
|
End Property
|
|
|
|
|
|
Public Property [sNRREF00]() As SqlString
|
|
Get
|
|
Return m_sNRREF00
|
|
End Get
|
|
Set(ByVal Value As SqlString)
|
|
m_sNRREF00 = Value
|
|
End Set
|
|
End Property
|
|
|
|
|
|
Public Property [sCDZAH00]() As SqlString
|
|
Get
|
|
Return m_sCDZAH00
|
|
End Get
|
|
Set(ByVal Value As SqlString)
|
|
m_sCDZAH00 = Value
|
|
End Set
|
|
End Property
|
|
|
|
|
|
Public Property [sNRPCK00]() As SqlString
|
|
Get
|
|
Return m_sNRPCK00
|
|
End Get
|
|
Set(ByVal Value As SqlString)
|
|
m_sNRPCK00 = Value
|
|
End Set
|
|
End Property
|
|
|
|
|
|
Public Property [sNRBCL00]() As SqlString
|
|
Get
|
|
Return m_sNRBCL00
|
|
End Get
|
|
Set(ByVal Value As SqlString)
|
|
m_sNRBCL00 = Value
|
|
End Set
|
|
End Property
|
|
|
|
|
|
Public Property [sNEVVG01]() As SqlString
|
|
Get
|
|
Return m_sNEVVG01
|
|
End Get
|
|
Set(ByVal Value As SqlString)
|
|
m_sNEVVG01 = Value
|
|
End Set
|
|
End Property
|
|
|
|
|
|
Public Property [sNRDOC00]() As SqlString
|
|
Get
|
|
Return m_sNRDOC00
|
|
End Get
|
|
Set(ByVal Value As SqlString)
|
|
Dim sNRDOC00Tmp As SqlString = Value
|
|
If sNRDOC00Tmp.IsNull Then
|
|
Throw New ArgumentOutOfRangeException("sNRDOC00", "sNRDOC00 can't be NULL")
|
|
End If
|
|
m_sNRDOC00 = Value
|
|
End Set
|
|
End Property
|
|
|
|
|
|
Public Property [sBESAD00]() As SqlString
|
|
Get
|
|
Return m_sBESAD00
|
|
End Get
|
|
Set(ByVal Value As SqlString)
|
|
m_sBESAD00 = Value
|
|
End Set
|
|
End Property
|
|
|
|
|
|
Public Property [sDMVAL00]() As SqlString
|
|
Get
|
|
Return m_sDMVAL00
|
|
End Get
|
|
Set(ByVal Value As SqlString)
|
|
m_sDMVAL00 = Value
|
|
End Set
|
|
End Property
|
|
|
|
|
|
Public Property [sCDWAEAI]() As SqlString
|
|
Get
|
|
Return m_sCDWAEAI
|
|
End Get
|
|
Set(ByVal Value As SqlString)
|
|
m_sCDWAEAI = Value
|
|
End Set
|
|
End Property
|
|
|
|
|
|
Public Property [sBTBET00]() As SqlString
|
|
Get
|
|
Return m_sBTBET00
|
|
End Get
|
|
Set(ByVal Value As SqlString)
|
|
m_sBTBET00 = Value
|
|
End Set
|
|
End Property
|
|
|
|
|
|
Public Property [sNRPAR00]() As SqlString
|
|
Get
|
|
Return m_sNRPAR00
|
|
End Get
|
|
Set(ByVal Value As SqlString)
|
|
m_sNRPAR00 = Value
|
|
End Set
|
|
End Property
|
|
|
|
|
|
Public Property [sNEVVG02]() As SqlString
|
|
Get
|
|
Return m_sNEVVG02
|
|
End Get
|
|
Set(ByVal Value As SqlString)
|
|
m_sNEVVG02 = Value
|
|
End Set
|
|
End Property
|
|
|
|
|
|
Public Property [sNEVVG00]() As SqlString
|
|
Get
|
|
Return m_sNEVVG00
|
|
End Get
|
|
Set(ByVal Value As SqlString)
|
|
m_sNEVVG00 = Value
|
|
End Set
|
|
End Property
|
|
|
|
|
|
Public Property [sNRPOS00]() As SqlString
|
|
Get
|
|
Return m_sNRPOS00
|
|
End Get
|
|
Set(ByVal Value As SqlString)
|
|
m_sNRPOS00 = Value
|
|
End Set
|
|
End Property
|
|
|
|
|
|
Public Property [sNRAUF00]() As SqlString
|
|
Get
|
|
Return m_sNRAUF00
|
|
End Get
|
|
Set(ByVal Value As SqlString)
|
|
Dim sNRAUF00Tmp As SqlString = Value
|
|
If sNRAUF00Tmp.IsNull Then
|
|
Throw New ArgumentOutOfRangeException("sNRAUF00", "sNRAUF00 can't be NULL")
|
|
End If
|
|
m_sNRAUF00 = Value
|
|
End Set
|
|
End Property
|
|
|
|
|
|
Public Property [sDMARC00]() As SqlString
|
|
Get
|
|
Return m_sDMARC00
|
|
End Get
|
|
Set(ByVal Value As SqlString)
|
|
m_sDMARC00 = Value
|
|
End Set
|
|
End Property
|
|
|
|
|
|
Public Property [daInsertTimestamp]() As SqlDateTime
|
|
Get
|
|
Return m_daInsertTimestamp
|
|
End Get
|
|
Set(ByVal Value As SqlDateTime)
|
|
m_daInsertTimestamp = Value
|
|
End Set
|
|
End Property
|
|
|
|
|
|
Public Property [daValdat]() As SqlDateTime
|
|
Get
|
|
Return m_daValdat
|
|
End Get
|
|
Set(ByVal Value As SqlDateTime)
|
|
m_daValdat = Value
|
|
End Set
|
|
End Property
|
|
|
|
|
|
Public Property [fBetrag]() As SqlDouble
|
|
Get
|
|
Return m_fBetrag
|
|
End Get
|
|
Set(ByVal Value As SqlDouble)
|
|
m_fBetrag = Value
|
|
End Set
|
|
End Property
|
|
|
|
#End Region
|
|
|
|
End Class
|
|
End Namespace
|