From 8e439b21b9f93751a68a5e9ead429db6c98ed4c7 Mon Sep 17 00:00:00 2001 From: Pedro Madrigal <8195212+pmb59@users.noreply.github.com> Date: Mon, 11 Dec 2023 16:41:09 +0000 Subject: [PATCH] feature start --- bin/load_db_scxa_dimred.sh | 3 +++ 1 file changed, 3 insertions(+) diff --git a/bin/load_db_scxa_dimred.sh b/bin/load_db_scxa_dimred.sh index 2878f07..d59d4e7 100755 --- a/bin/load_db_scxa_dimred.sh +++ b/bin/load_db_scxa_dimred.sh @@ -37,6 +37,9 @@ rm -f $SCRATCH_DIR/dimredDataToLoad.csv # Insert a new row into the dimension reductions table echo "INSERT INTO scxa_dimension_reduction (experiment_accession, method, parameterisation) VALUES ('$EXP_ID', '$DIMRED_TYPE', '$DIMRED_PARAM_JSON');" | psql -v ON_ERROR_STOP=1 $dbConnection drid=$(echo "SELECT id FROM scxa_dimension_reduction WHERE experiment_accession = '$EXP_ID' AND method = '$DIMRED_TYPE' AND parameterisation = '$DIMRED_PARAM_JSON';" | psql -qtAX -v ON_ERROR_STOP=1 $dbConnection) +# we should fill 'priority' here too + +# bonus if we check there is only one non-zero value in the table # Transform the TSV coords into the DB table structure tail -n +2 $DIMRED_FILE_PATH | awk -F'\t' -v drid="$drid" 'BEGIN { OFS = ","; }