- goppi
- Posts : 13
Join date : 2019-01-24
Converting Data
Sat Oct 30, 2021 2:44 pm
Hi.
I just converted my data from v.9 to v.10 which worked quite well.
As the default style name has changed between versions and cannot be modified via GUI I tried to change that via SQLite Studio.
There I found that any attempt to update data in the "options" table produces the following error message:
Taking a look at the SQLite docs and the trigger in question I think this could be expected as updating a column from a trigger in the trigger-table itself fires the trigger again leading to a recursion.
So the question is: Why does this not happen from within the application?
THX for your help.
I just converted my data from v.9 to v.10 which worked quite well.
As the default style name has changed between versions and cannot be modified via GUI I tried to change that via SQLite Studio.
There I found that any attempt to update data in the "options" table produces the following error message:
- Code:
[15:37:42] An error occurred while committing the data: too many levels of trigger recursion
Taking a look at the SQLite docs and the trigger in question I think this could be expected as updating a column from a trigger in the trigger-table itself fires the trigger again leading to a recursion.
So the question is: Why does this not happen from within the application?
THX for your help.
- LaurentG
- Posts : 124
Join date : 2020-01-16
Re: Converting Data
Sat Oct 30, 2021 3:45 pm
Which data do you want to update in options table that is not available in GUI ?
According to me, the default style is the option desktop.skin.filename, that is available in GUI, in Settings / appearance
But maybe you are talking about something else ?
Did you exit Stickies before opening the .db ?
No problem on my side to update the Stickies database using "DB Browser for SQLite" (see https://sqlitebrowser.org/ )
According to me, the default style is the option desktop.skin.filename, that is available in GUI, in Settings / appearance
But maybe you are talking about something else ?
Did you exit Stickies before opening the .db ?
No problem on my side to update the Stickies database using "DB Browser for SQLite" (see https://sqlitebrowser.org/ )
goppi likes this post
- goppi
- Posts : 13
Join date : 2019-01-24
Re: Converting Data
Sat Oct 30, 2021 4:01 pm
Hi.
THX for you response.
I'm talking about styles and not skin. You could define different styles which you can assign to the stickies. The name of the default style cannot be modified via GUI (greyed out) but here it is different between "v.10 data" and "v.9 -> v.10 converted data".
I will check "DB Browser for SQLite" if it behaves different. Maybe it is a question of what SQLite release or implementation a software uses.
However from what I found the error is what you should expect as a field in the "options" table ("sysmod") is updated from a "AFTER UPDATE" trigger which is assigned to the options table itself leading to recursion. To avoid this one would use "AFTER UPDATE OF" and exclude the column you update.
Cheers.
THX for you response.
I'm talking about styles and not skin. You could define different styles which you can assign to the stickies. The name of the default style cannot be modified via GUI (greyed out) but here it is different between "v.10 data" and "v.9 -> v.10 converted data".
I will check "DB Browser for SQLite" if it behaves different. Maybe it is a question of what SQLite release or implementation a software uses.
However from what I found the error is what you should expect as a field in the "options" table ("sysmod") is updated from a "AFTER UPDATE" trigger which is assigned to the options table itself leading to recursion. To avoid this one would use "AFTER UPDATE OF" and exclude the column you update.
Cheers.
- goppi
- Posts : 13
Join date : 2019-01-24
Re: Converting Data
Sat Oct 30, 2021 4:17 pm
Ok I checked with your suggestions "DB Browser for SQLite" which indeed is not showing the recursion problem. I think I found the reason which is the pragma "recursive_triggers" you can specify when compiling your SQLite3 library. Seems that the solutions use different settings for it.
SQLite Forum
SQLite Forum
- LaurentG
- Posts : 124
Join date : 2020-01-16
Re: Converting Data
Sat Oct 30, 2021 9:15 pm
I still not have understood what option you want to update in the database ???
The word "Default" that is greyed out is NOT defined in the database, but is a string resource in the exe (or in the language101.dll for localized versions)
Moreover, I just checked, and the name was already Default (or Défaut in frenche localized version) in v9....
The word "Default" that is greyed out is NOT defined in the database, but is a string resource in the exe (or in the language101.dll for localized versions)
Moreover, I just checked, and the name was already Default (or Défaut in frenche localized version) in v9....
- goppi
- Posts : 13
Join date : 2019-01-24
Re: Converting Data
Sun Oct 31, 2021 10:57 am
The word "Default" that is greyed out is NOT defined in the database, but is a string resource in the exe (or in the language101.dll for localized versions)
That was my first assumption but digging more into detail taught me different. Maybe the string resource is only used to initialize the value in the database when it is first created.
However your hint using a different SQLite software helped me to solve the problem.
- LaurentG
- Posts : 124
Join date : 2020-01-16
Re: Converting Data
Sun Oct 31, 2021 12:25 pm
Well seen, you're right !
Congratulations
Congratulations
Permissions in this forum:
You can reply to topics in this forum