TMyStroredPRoc assign parameters What is wrong

Discussion of open issues, suggestions and bugs regarding MyDAC (Data Access Components for MySQL) for Delphi, C++Builder, Lazarus (and FPC)
Post Reply
Daniel Fagnan
Posts: 58
Joined: Fri 13 Oct 2006 00:08

TMyStroredPRoc assign parameters What is wrong

Post by Daniel Fagnan » Fri 13 Oct 2006 00:14

Try

Proc1.StoredProcName := 'UpdatePunchFromHoro';
Proc1.Prepare;
begin
Proc1.ParamByName('LookDate').AsDate := now;
Proc1.ParamByName('Empl').asInteger := strTOInt(edit1.text) ;
Proc1.ParamByName('ClockTime').asDateTime:= Now;

Proc1.Execute;
end
finally
PRoc1.UnPrepare;
end;
Nothing with this code
I assign value in params default values and execute from the tMyStoredProc dialog button
all is ok
what'is wrong :?

Antaeus
Posts: 2098
Joined: Tue 14 Feb 2006 10:14

Post by Antaeus » Fri 13 Oct 2006 08:50

Please specify what problem have you encountered.

Daniel Fagnan
Posts: 58
Joined: Fri 13 Oct 2006 00:08

I found a solution DateFormat

Post by Daniel Fagnan » Fri 13 Oct 2006 22:44

If I Put
Proc1.parambyNAme('lookdate').asString = Format('yyyy/mm/dd',Now)
Al is ok

Proc1.ParamByName('LookDate').asDate = Now
My Application break

Why

Antaeus
Posts: 2098
Joined: Tue 14 Feb 2006 10:14

Post by Antaeus » Mon 16 Oct 2006 07:07

We could not reproduce the problem.
Please send us (evgeniyD*crlab*com) a complete small sample to demonstrate it, including script to create and fill table.

Also supply us following information
- Exact version of Delphi or Kylix
- Exact version of MyDAC. You can see it in About sheet of TMyConnection Editor
- Exact version of MySQL server and MySQL client. You can see it in Info sheet of TMyConnection Editor

Post Reply