diff options
author | Pjotr Prins | 2020-07-08 04:52:07 -0500 |
---|---|---|
committer | Pjotr Prins | 2020-07-08 04:52:07 -0500 |
commit | c249ba2ef7d691227da8864838dfc97db68d4084 (patch) | |
tree | 52e28fe60dc2bbe25fcfa0cd18a04a660e9573fe /scripts/add_missing_columns.sh | |
parent | 421848837d3b489762bb9e58e5e7047d02cdb20b (diff) | |
parent | b026c18a1263f84cbed86018e3ba2d20e97b61d4 (diff) | |
download | genenetwork2-c249ba2ef7d691227da8864838dfc97db68d4084.tar.gz |
Merge branch 'testing' of github.com:genenetwork/genenetwork2 into testing
Diffstat (limited to 'scripts/add_missing_columns.sh')
-rw-r--r-- | scripts/add_missing_columns.sh | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/scripts/add_missing_columns.sh b/scripts/add_missing_columns.sh new file mode 100644 index 00000000..70d5fdeb --- /dev/null +++ b/scripts/add_missing_columns.sh @@ -0,0 +1,24 @@ + #! /bin/bash + # + # Add missing columns to test db downloaded from: + # https://s3.amazonaws.com/genenetwork2/db_webqtl_s.zip + + QUERY=" + ALTER TABLE InbredSet + ADD Family varchar(20) AFTER FullName, + ADD FamilyOrder varchar(20) AFTER Family, + ADD MenuOrderId smallint(6) AFTER FamilyOrder, + ADD InbredSetCode varchar(5) AFTER MenuOrderId; + + ALTER TABLE PublishXRef + ADD mean double AFTER DataId; + + -- This takes some time + ALTER TABLE ProbeSet + ADD UniProtID varchar(20) AFTER ProteinName; + " + + USER=gn2 + DBNAME=db_webqtl_s + PASS=mysql_password + mysql -u"$USER" -p"$PASS" -h localhost -D "$DBNAME" -e "$QUERY" |