Forum

Please or Register to create posts and topics.

Trying to set blank given names to ____

I'm trying to set blank given names to ____.

However, I'm having an issue. I have downloaded dll extension so that the RMNOCASE works.

I can get the

select * from nametable
where given =''

to run now.

But when I try

UPDATE nametable
SET given = REPLACE(given , '', '_____')
where given =''

I get an error SQLLite3 Error 11 - database disk image is malformed.

Can anyone help? It's only 461 items, but still, it would be useful to change en-mass.

 

This may be an indexing error due to the not-quite-perfect match of the fake collation sequence so try the SQLite REINDEX statement before executing your UPDATE.

Remember to use RM's Rebuild Indexes database tool on returning to RM because any UPDATE or INSERT or REINDEX in SQLite involving tables with RMNOCASE indexes will fail RM's Integrity Check.

Thanks Tom. I wasn't sure how to do that, but looked online and found the answer:

SQLLIte

1. Run REINDEX nametable

2 Run UPDATE nametable
SET given = '_____'
where nameid in ('30912', etc)

And the given names changed.

RM

3. Reindex

However, the TreeShare for Ancestry didn't show changed people (I assume it is due to fact that the changes were done outside RM). So I had to get creative...

4. Creat a group with name containing '_____' (couldn't do it just on given name)

5. Link into Ancestry and searched for changes only

6. Update in Ancestry

7. Accept each change I came across.

Not ideal as I had to do this manually, and the group didn't have just given names, but it was certainly quicker than manually finding each one!

 

 

Glad to hear you got past the SQLite Error 10. I usually just issue REINDEX; as it is fast and takes care of all the tables.

I'm not sure but maybe updating the UTCModDate for those records you changed would have caused TreeShare to detect that the Name is out-of-sync with the Ancestry database. Also, I don't know if updates to Alternate Names would even trigger the Changed status; might be only for the Primary Name record.

Regardless, you would still have to manually sync each person even though the set would be smaller.

A minor comment regarding your use of the REINDEX command.

I 'd suggest that the command:
REIINDEX RMNOCASE
may better suit most people's needs.

Your command was fine for your purpose, but if one is generally modifying data in tables, it's a lot easier to just take care of all the reindexing in one command and not worry about missing anything.

It is also a bit more "correct" in that it brings the whole database into a logically consistent state.

Check out the SQLite doc regarding reindex. No surprises, but useful review:
https://www.sqlite.org/lang_reindex.html

 

Quote from Richard Otter on 2025-03-24, 12:23 pm

A minor comment regarding your use of the REINDEX command.

Check out the SQLite doc regarding reindex. No surprises, but useful review:
https://www.sqlite.org/lang_reindex.html

 

Thank you Richard. I have learnt some SQL over the last 3 years at my jobs, but nothing too major (i.e. I wasn't allowed to amend any db through SQL). So Any help is great.

I had read that link already, but wasn't sure how to use it. Turns out, it was very simple!!

Here's a little more on RMNOCASE, in case you're interested-

https://github.com/RichardOtter/Genealogy-scripts/blob/main/RM/doc/Notes%20on%20collation%20RMNOCASE.md

Quote from Richard Otter on 2025-03-24, 3:47 pm

https://github.com/RichardOtter/Genealogy-scripts/blob/main/RM/doc/Notes%20on%20collation%20RMNOCASE.md

Well now.... this looks like a lot of fun and reading I'll have to do! I've only recently got RM, hence my interest in it, but wanted to get into the backend to fix things en mass.

This site you've linked will be fun to work through - on a test db naturally 🙂