Saving with new mysql 5.7 triggers in db

Derek Atkins warlord at MIT.EDU
Mon May 15 11:49:33 EDT 2017


Geert Janssens <geert.gnucash at kobaltwit.be> writes:

>> Is it possible that GnuCash just isn't being happy with the "modified"
>> tables?
>> 
> Possibly and that's what John also suggests. I don't know the exact details of 
> how the sql backend interacts with the tables. I just know there are ways in 
> general that you can have extra columns in an sql table than there are columns 
> used in an insert/update query. When columns are omitted they are normally set 
> to their default value on insert or ignored on an update. I used that idea to 
> suggest my alternative trigger.
>
> On the other hand if the sql backend for some reason sets restrictions on the 
> available columns this may be an issue. Only a real test can tell but I'm not 
> interested enough right now to spend the effort. On the other hand if someone 
> else is, I would appreciate to hear the result.
>
> And John's other remark was even more to the point. Why not use the year(), 
> month() and day() function directly in the queries instead of duplicating the 
> info in the table ?

I haven't looked at the code but inserts can be done implicitly or
explicitly.  If they are done implicitly then any change to the table
could cause problems on future inserts.  I don't know if GnuCash uses
implicit or explicit insertions.

> Geert

-derek

-- 
       Derek Atkins, SB '93 MIT EE, SM '95 MIT Media Laboratory
       Member, MIT Student Information Processing Board  (SIPB)
       URL: http://web.mit.edu/warlord/    PP-ASEL-IA     N1NWH
       warlord at MIT.EDU                        PGP key available


More information about the gnucash-devel mailing list