Página 1 de 1

Error : Multiple-step operation generated errors. Check each status value.

Publicado: Lun Jul 22, 2013 10:09 am
por Milan Mehta
I am using latest version of Xailer with Harbour with MySql as backend.
When I keep date empty on the form and then try to Save it, I get the error
:
Multiple-step operation generated errors. Check each status value.
I was not getting this error while using it with xHarbour.
If I do not keep the field on the form and assign Nil value to the field and
Save this error do not generate.
Kindly help
TIA
Milan.

Error : Multiple-step operation generated errors. Check each status value.

Publicado: Mar Jul 23, 2013 10:26 am
por ignacio
Milan Mehta escribió el lun, 22 julio 2013 10:09I am using latest version of Xailer with Harbour with MySql as backend.
When I keep date empty on the form and then try to Save it, I get the error
:
Multiple-step operation generated errors. Check each status value.
I was not getting this error while using it with xHarbour.
If I do not keep the field on the form and assign Nil value to the field and
Save this error do not generate.
Kindly help
TIA
Milan.
Is there a error.log? TIA
Regards,

Error : Multiple-step operation generated errors. Check each status value.

Publicado: Mar Jul 23, 2013 11:30 am
por ignacio
Milan Mehta escribió el lun, 22 julio 2013 10:09I am using latest version of Xailer with Harbour with MySql as backend.
When I keep date empty on the form and then try to Save it, I get the error
:
Multiple-step operation generated errors. Check each status value.
I was not getting this error while using it with xHarbour.
If I do not keep the field on the form and assign Nil value to the field and
Save this error do not generate.
Kindly help
TIA
Milan.
Attached with this message is a sample project that connects with our MySQL server. Please try it.
Regards,


Attached files test.zip (4 KB)Â

Error : Multiple-step operation generated errors. Check each status value.

Publicado: Mar Jul 23, 2013 4:35 pm
por Milan Mehta
I am using enterprise edition of Xailer, which does not have Native support
of MySql.
Hence I have recreated the same project you have sent me.
So you will be able to see the problem.
Just click on the Add button to see the problem.
TIA
Milan.
"Ignacio Ortiz de Zúñiga" <nonametoavoidspam@xailer.com> wrote in
message news:51ee4d3d$[email=1@svctag-j7w3v3j....]1@svctag-j7w3v3j....[/email]
> Milan Mehta escribió el lun, 22 julio 2013 10:09
>> I am using latest version of Xailer with Harbour with
>> MySql as backend.
>>
>> When I keep date empty on the form and then try to Save
>> it, I get the error :
>> Multiple-step operation generated errors. Check each
>> status value.
>>
>> I was not getting this error while using it with
>> xHarbour.
>> If I do not keep the field on the form and assign Nil
>> value to the field and Save this error do not generate.
>>
>> Kindly help
>> TIA
>> Milan.
>
>
> Attached with this message is a sample project that connects
> with our MySQL server. Please try it.
>
> Regards,
>
------------------------------------------------------------ --------------------
>
> --
> Ignacio Ortiz de Zúñiga
> [Equipo de Xailer/Xailer team]
> http://www.xailer.com
> http://www.xailer.info

Error : Multiple-step operation generated errors. Check each status value.

Publicado: Mar Jul 23, 2013 4:37 pm
por Milan Mehta
Sorry, I use Professional version which does not have Native MySql support.
Milan.
"Milan Mehta" <lotusint@sancharnet.in> wrote in message
news:[email=51ee94bf@svctag-j7w3v3j....]51ee94bf@svctag-j7w3v3j....[/email]
>I am using enterprise edition of Xailer, which does not have Native support
>of MySql.
>
> Hence I have recreated the same project you have sent me.
> So you will be able to see the problem.
> Just click on the Add button to see the problem.
>
> TIA
> Milan.
>
> "Ignacio Ortiz de Zúñiga" <nonametoavoidspam@xailer.com> wrote in
> message news:51ee4d3d$[email=1@svctag-j7w3v3j....]1@svctag-j7w3v3j....[/email]
>> Milan Mehta escribió el lun, 22 julio 2013 10:09
>>> I am using latest version of Xailer with Harbour with
>>> MySql as backend.
>>>
>>> When I keep date empty on the form and then try to Save
>>> it, I get the error :
>>> Multiple-step operation generated errors. Check each
>>> status value.
>>>
>>> I was not getting this error while using it with
>>> xHarbour.
>>> If I do not keep the field on the form and assign Nil
>>> value to the field and Save this error do not generate.
>>>
>>> Kindly help
>>> TIA
>>> Milan.
>>
>>
>> Attached with this message is a sample project that connects
>> with our MySQL server. Please try it.
>>
>> Regards,
>>
>
>
> ------------------------------------------------------------ --------------------
>
>
>>
>> --
>> Ignacio Ortiz de Zúñiga
>> [Equipo de Xailer/Xailer team]
>> http://www.xailer.com
>> http://www.xailer.info
>
>

Error : Multiple-step operation generated errors. Check each status value.

Publicado: Mar Jul 23, 2013 4:50 pm
por ignacio
Hi,
Could yo tell us how do you exactly access your MySQL databases? TIA.
Regards,
Note: No project attached on your last messages.

Error : Multiple-step operation generated errors. Check each status value.

Publicado: Mar Jul 23, 2013 5:47 pm
por ignacio
Hello,
Please try with the file attached. OBJ is for Borland, O is for MinGW. TIA.
Regards,

Attached files imaskedit.rar (10 KB)Â

Error : Multiple-step operation generated errors. Check each status value.

Publicado: Mié Jul 24, 2013 6:52 am
por Milan Mehta
Sorry...Please find attached my recreated project.
TIA
Milan.
"Ignacio Ortiz de Zúñiga" <nonametoavoidspam@xailer.com> wrote in
message news:51eea576$[email=1@svctag-j7w3v3j....]1@svctag-j7w3v3j....[/email]
> Hello,
>
> Please try with the file attached. OBJ is for Borland, O is
> for MinGW. TIA.
>
> Regards,
>
------------------------------------------------------------ --------------------
>
> --
> Ignacio Ortiz de Zúñiga
> [Equipo de Xailer/Xailer team]
> http://www.xailer.com
> http://www.xailer.info


Attached files Projects.zip (48.9 KB)Â

Error : Multiple-step operation generated errors. Check each status value.

Publicado: Mié Jul 24, 2013 12:58 pm
por Milan Mehta
Linking this file did not help. Problem remains.
I have attached my project.
Kindly test the same and guide us resolve the problem.
TIA
Milan.
"Ignacio Ortiz de Zúñiga" <nonametoavoidspam@xailer.com> wrote in
message news:51eea576$[email=1@svctag-j7w3v3j....]1@svctag-j7w3v3j....[/email]
> Hello,
> Please try with the file attached. OBJ is for Borland, O is
> for MinGW. TIA.
> Regards,
------------------------------------------------------------ --------------------
>
> --
> Ignacio Ortiz de Zúñiga
> [Equipo de Xailer/Xailer team]
> http://www.xailer.com
> http://www.xailer.info

Error : Multiple-step operation generated errors. Check each status value.

Publicado: Mié Jul 24, 2013 7:01 pm
por ignacio
Hello,
Your problem arises due the way Xailer treats empty fields. When going to Edit mode all the fields get initialized. In case of date or date-time fields, they get initialized to an empty date. Unfortunately ADO does not recognized empty dates as [x]Harbour.
The simple way to fix this is to set the TDataField:DefValue property to NIL:
oRS:Date( dsOBJECT ):DefValue := NIL
BTW, I have made a small modification on AdoRecords.prg to correct this problem. Here is the code (line 296):
IF Empty( v ) .AND. Valtype( v ) $ "DT"
v := NIL
ENDIF
IF v != NIL .AND. oFiedl:lModified ....
This will put a NULL value for empty date fields.
Apart there also another problem and is because you are not setting any value to any field, and I'm afraid ADO does not like it. I have included a new field 'NAME' and then this codes works correctly:
METHOD AddClick( oSender ) CLASS TForm1
WITH OBJECT ::oMilan
:AddNew()
:Name := Time()
:Update()
END WITH
RETURN Nil
Regards,

Error : Multiple-step operation generated errors. Check each status value.

Publicado: Jue Jul 25, 2013 7:52 am
por Milan Mehta
Thanks ignacio. The problem is partly solved.
It has started working fine for adding record to the database.
However the problem still continues for Edit part.
To demonstrate the same, I have made little modification to the same project
and attached it herewith.
Just try to select an Empty Date Record and then click on Edit button.
Can you just check the same and guide us little further ?
TIA
Milan.
"Ignacio Ortiz de Zúñiga" <nonametoavoidspam@xailer.com> wrote in
message news:51f0085c$[email=1@svctag-j7w3v3j....]1@svctag-j7w3v3j....[/email]
> Hello,
>
> Your problem arises due the way Xailer treats empty fields.
> When going to Edit mode all the fields get initialized. In
> case of date or date-time fields, they get initialized to an
> empty date. Unfortunately ADO does not recognized empty
> dates as [x]Harbour.
>
> The simple way to fix this is to set the TDataField:DefValue
> property to NIL:
>
> oRS:Date( dsOBJECT ):DefValue := NIL
>
> BTW, I have made a small modification on AdoRecords.prg to
> correct this problem. Here is the code (line 296):
>
> IF Empty( v ) .AND. Valtype( v ) $ "DT"
> v := NIL
> ENDIF
> IF v != NIL .AND. oFiedl:lModified ....
>
> This will put a NULL value for empty date fields.
>
> Apart there also another problem and is because you are not
> setting any value to any field, and I'm afraid ADO does not
> like it. I have included a new field 'NAME' and then this
> codes works correctly:
>
> METHOD AddClick( oSender ) CLASS TForm1
>
> WITH OBJECT ::oMilan
> :AddNew()
> :Name := Time()
> :Update()
> END WITH
>
> RETURN Nil
>
> Regards,
> --
> Ignacio Ortiz de Zúñiga
> [Equipo de Xailer/Xailer team]
> http://www.xailer.com
> http://www.xailer.info


Attached files Projects.rar (52.7 KB)Â

Error : Multiple-step operation generated errors. Check each status value.

Publicado: Jue Jul 25, 2013 12:01 pm
por ignacio
Hello,
I'm afraid there is problem with MySQL ODBC or the ODBC to ADO convertor since it fails when trying to set NULL values on empty fields.
This code works perfectly on Access through ADO:
WITH OBJECT oRs
:Edit()
:Date := NIL
:Update()
END WITH
But it fails on ADO+MYSQL 5.1. I believe is due the special way MySQL handles NULL date values:

(http://dev.mysql.com/doc/refman/5.0/en/using-date.html)
But is just a hunch.
I had done some research on Internet and there a lot of people with this same problem. In can only give you some workarounds for this problem:
1) If you do not need to change the date field value TO NULL simply set the property TDataField:lAutoSave to .F.
2) In order to set the date field to NULL use this code:
WITH OBJECT ::oAdo
:BeginTrans()
:Execute( "update Milan set date='0000-00-00' where ..." )
:CommitTrans()
END WITH
Sorry for not giving you a better solution.
Regards,

Attached files

Error : Multiple-step operation generated errors. Check each status value.

Publicado: Vie Jul 26, 2013 8:01 am
por Milan Mehta
Thanks a lot. I followed your workaround to solve the problem.
But I still wonder, how xHarbour managed it well.
There must be a better way out.
Give it a thought when time permits.
Milan.
"Ignacio Ortiz de Zúñiga" <nonametoavoidspam@xailer.com> wrote in
message news:51f0f784$[email=1@svctag-j7w3v3j....]1@svctag-j7w3v3j....[/email]
> Hello,
> I'm afraid there is problem with MySQL ODBC or the ODBC to
> ADO convertor since it fails when trying to set NULL values
> on empty fields.
> This code works perfectly on Access through ADO:
>
> WITH OBJECT oRs
> :Edit()
> :Date := NIL
> :Update()
> END WITH
>
> But it fails on ADO+MYSQL 5.1. I believe is due the special
> way MySQL handles NULL date values:
>
>
> (http://dev.mysql.com/doc/refman/5.0/en/using-date.html)
>
> But is just a hunch.
>
> I had done some research on Internet and there a lot of
> people with this same problem. In can only give you some
> workarounds for this problem:
>
> 1) If you do not need to change the date field value TO NULL
> simply set the property TDataField:lAutoSave to .F.
>
> 2) In order to set the date field to NULL use this code:
>
> WITH OBJECT ::oAdo
> :BeginTrans()
> :Execute( "update Milan set date='0000-00-00' where ..." )
> :CommitTrans()
> END WITH
> Sorry for not giving you a better solution.
>
> Regards,
------------------------------------------------------------ --------------------
>
> --
> Ignacio Ortiz de Zúñiga
> [Equipo de Xailer/Xailer team]
> http://www.xailer.com
> http://www.xailer.info

Error : Multiple-step operation generated errors. Check each status value.

Publicado: Vie Jul 26, 2013 12:36 pm
por ignacio
Milan Mehta escribió el vie, 26 julio 2013 08:01Thanks a lot. I followed your workaround to solve the problem.
But I still wonder, how xHarbour managed it well.
There must be a better way out.
Give it a thought when time permits.
Hi,
I did not realize it worked with xHarbour. That clue was great. We did some modifications on olecore.c on xHarbour that we did not implement on Harbour in order to maintain full compatibility with them.
I attach with this message the Harbour olecore.o module modified with our fix for NULL values. Here is working perfectly. Please do your tests and tell us your results. TIA for your feedback.
Regards,

Attached files olecore.rar (13.2 KB)Â

Error : Multiple-step operation generated errors. Check each status value.

Publicado: Sab Jul 27, 2013 7:31 am
por Milan Mehta
Dear Ignacio,
The solution works just PERFECT !!!
I am not able to describe my joy of getting this solution !!!
I am just ecstatic !!!
Thanks a lot...
Milan.
"Ignacio Ortiz de Zúñiga" <nonametoavoidspam@xailer.com> wrote in
message news:51f2512a$[email=1@svctag-j7w3v3j....]1@svctag-j7w3v3j....[/email]
> Milan Mehta escribió el vie, 26 julio 2013 08:01
>> Thanks a lot. I followed your workaround to solve the
>> problem.
>>
>> But I still wonder, how xHarbour managed it well.
>> There must be a better way out.
>> Give it a thought when time permits.
>
>
> Hi,
> I did not realize it worked with xHarbour. That clue was
> great. We did some modifications on olecore.c on xHarbour
> that we did not implement on Harbour in order to maintain
> full compatibility with them.
>
> I attach with this message the Harbour olecore.o module
> modified with our fix for NULL values. Here is working
> perfectly. Please do your tests and tell us your results.
> TIA for your feedback.
>
> Regards,
------------------------------------------------------------ --------------------
>
> --
> Ignacio Ortiz de Zúñiga
> [Equipo de Xailer/Xailer team]
> http://www.xailer.com
> http://www.xailer.info