Does anyone have some SQLite tips or code for merging two dictionaries into one.
For example I have a Spanish Vines in Hebrew and another in Greek and I'd like to merge them.
If possible I'd like to sort the topics list alphabetically at the same time. Since there are also some Spanish topics.
Thanks
Merging two dictionaries
- jonathangkoehn
- Posts: 1253
- Joined: Wed Sep 29, 2010 11:04 pm
- Location: Colorado, United States
- Contact:
Merging two dictionaries
Jonathan Koehn @ https://www.thewordbooks.com
TotheWord make resources for theWord
2 Timothy 2:15 “Make every effort to present yourself before God as a proven worker who does not need to be ashamed, teaching the message of truth accurately.” NET2
TotheWord make resources for theWord
2 Timothy 2:15 “Make every effort to present yourself before God as a proven worker who does not need to be ashamed, teaching the message of truth accurately.” NET2
Re: Merging two dictionaries
You can do some of this within theWord. Have both modules as "user editable", then select all the topics in the one module and "drag n drop" to the topics list in the target module.
Then I would try some sql on the module either of these should do something, though I am just borrowing past code here.
Of course you should only try this on backup copies until you are sure all is well.
create table x (rel_order integer primary key autoincrement, id, subject);
insert into x(id,subject) select id,subject from topics order by subject;
update topics set rel_order = (select rel_order from x where id = topics.id);
drop table x;
vacuum;
---------------------------------
create table x (rel_order integer primary key autoincrement, id, subject);
insert into x(id,subject) select id,subject from topics order by lower(subject);
update topics set rel_order = (select rel_order from x where id = topics.id);
drop table x;
vacuum;
Then I would try some sql on the module either of these should do something, though I am just borrowing past code here.
Of course you should only try this on backup copies until you are sure all is well.
create table x (rel_order integer primary key autoincrement, id, subject);
insert into x(id,subject) select id,subject from topics order by subject;
update topics set rel_order = (select rel_order from x where id = topics.id);
drop table x;
vacuum;
---------------------------------
create table x (rel_order integer primary key autoincrement, id, subject);
insert into x(id,subject) select id,subject from topics order by lower(subject);
update topics set rel_order = (select rel_order from x where id = topics.id);
drop table x;
vacuum;
Jon
theWord 6 Bible Software
OS for testing; Windows 10
Beta Download ------Beta Setup Guide------On-line Manual------Tech doc's and Utilities------Copyright Factsheet
theWord 6 Bible Software
OS for testing; Windows 10
Beta Download ------Beta Setup Guide------On-line Manual------Tech doc's and Utilities------Copyright Factsheet