Page 1 of 1

StoredProcedure with out parameter is not working

Posted: Sat 03 Oct 2009 16:11
by Zero-G.
Hey
I use your latest components of dotConnect for mySQL
In my VB.Class (generated by your entity developer) I get the following code, based on my SP

Code: Select all

  _
		Public Function Rechnungvergeben( ByVal Uebergabeid As String, _
				 ByVal Isbezahlt As System.Nullable(Of Short), _
				 ByVal Zahlungsart As String, _
				 ByVal Kundenname As String, _
				 ByVal Kundenadresse As String, _
				 ByVal Auftragsbetrag As System.Nullable(Of Decimal), _
				 ByVal Bezahlterbetrag As System.Nullable(Of Decimal), _
				 ByVal Mitarbeitername As String, _
				 ByVal Fid As System.Nullable(Of Long), _
				 ByVal Rnr As System.Nullable(Of Integer), _
				 ByVal Auftragsjahr As System.Nullable(Of System.DateTime), _
				 ByRef Nrenummer As System.Nullable(Of Integer)) As System.Int32
			Dim result As IExecuteResult = Me.ExecuteMethodCall(Me, CType(MethodInfo.GetCurrentMethod,MethodInfo), Uebergabeid, Isbezahlt, Zahlungsart, Kundenname, Kundenadresse, Auftragsbetrag, Bezahlterbetrag, Mitarbeitername, Fid, Rnr, Auftragsjahr, Nrenummer)
			Nrenummer = CType(result.GetParameterValue(11), System.Nullable(Of Integer))
            Return CType(result.ReturnValue, System.Int32)
		End Function
The problem is, that I don't get back a value (it's always 0)

But, when I change the Return statement to:

Code: Select all

Return Nrenummer
Then it works fine.

THX

Posted: Mon 05 Oct 2009 13:16
by AndreyR
Thank you for the report.
We are working on a new template engine, this engine should fix the problem.
I will let you know as soon as it is available.

Posted: Mon 05 Oct 2009 14:14
by Zero-G.
Thank you