issue updating database schema
kolt-mcb opened this issue · comments
Hi Nick,
I had an issue updating my database schema today..
when running ns_image_server update_sql I recieved the error:
=============ns_image_server==============
== ==
== Image Capture and Processing Server ==
== 2.5.0 ==
== ==
== Nicholas Stroustrup ==
== Center for Genomic Regulation ==
== Barcelona, 2020 ==
Updating model registry
Server Root Exception: ns_sql_connection::Error in query: ALTER TABLE analysis_model_registry
ADD COLUMN details
TEXT NOT NULL DEFAULT '''' AFTER filename
(BLOB/TEXT column 'details' can't have a default value)
I manually ran the following " ALTER TABLE analysis_model_registry
ADD COLUMN details
TEXT NOT NULL DEFAULT '' AFTER filename
; " and was able to continue.. crossing my fingers this was the intended..
I am really not sure if you intended some thing else specifically regarding ( '''' ) :
*sql << "ALTER TABLE " << t_suf << "analysis_model_registry
"
"ADD COLUMN details
TEXT NOT NULL DEFAULT '''' AFTER filename
";
in ns_image_server.cpp
Hope you are well!
bug fixed in 883a786
Thanks Kolt!
N