[Cod-bugs] COD to sqlite3 error

Nicola Döbelin support at profex-xrd.org
Fri Jan 24 15:21:09 EET 2025


Hello,

I am the programmer of the Rietveld refinement software Profex. In the 
past few years, I used to convert the COD to sqlite3 to bundle it with 
Profex. For the conversion I used the attached bash script, which I 
created based on the information given on the COD wiki:

https://wiki.crystallography.net/creatingSQLdatabase/

However, this year the script no longer works and generates the 
following error message:

#-- begin output --

updating svn
Updating '.':
At revision 297460.
converting mysql to sqlite

       ERROR (line 13): Invalid statement: Was expecting comment, or use, or
                        set, or drop, or create, or alter, or insert, or
                        delimiter, or empty statement
Error: translate: Error with parser 'SQL::Translator::Parser::MySQL':  
no results at /usr/bin/sqlt line 353.
replacing escape sequences
importing data
CREATE TABLE data(...) failed: duplicate column name: 90
creating cod-250124.db
compressing
   adding: cod-250124.db3 (stored 0%)

#-- end output --

The resulting *.db3 file is empty. I always update the sqlite3 COD 
version in January, so the break must have occurred some time between 
Jan 2024 and Jan 2025. I also tried to run the script on an older Ubuntu 
20.04 system on which it used to work in the past, but to no avail. 
Since I am not familiar with MySQL and have very limited experience with 
sqlite, I would like to ask for help to create an updated sqlite version 
of the COD that I can bundle with Profex.

Any help will be appreciated.
Kind regards,
Nicola

-- 
Nicola Döbelin
Web: https://www.profex-xrd.org
E-Mail: support at profex-xrd.org

-- 
This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.

-------------- next part --------------
A non-text attachment was scrubbed...
Name: update-and-convert-cod.sh
Type: application/x-shellscript
Size: 507 bytes
Desc: not available
URL: <http://lists.crystallography.net/pipermail/cod-bugs/attachments/20250124/2b7001d4/attachment.bin>


More information about the Cod-bugs mailing list