Update changeidentification.sh

This commit is contained in:
Alexandre
2024-05-13 16:58:17 +02:00
committed by GitHub
parent dd71151545
commit e7efbf63c1

View File

@@ -49,7 +49,7 @@ fi
##################
# Get the line where the column "File_Name" matches exactly $OLDNAME
IFS='|' read -r OLDNAME_sciname OLDNAME_comname OLDNAME_date < <(sqlite3 "$DB_FILE" "SELECT Sci_Name, Com_Name, Date FROM $DETECTIONS_TABLE WHERE File_Name = '$OLDNAME';")
IFS='|' read -r OLDNAME_sciname OLDNAME_comname OLDNAME_date < <(sqlite3 "$DB_FILE" "SELECT Sci_Name, Com_Name, Date FROM $DETECTIONS_TABLE WHERE File_Name = '$OLDNAME' LIMIT 1;")
if [[ -z "$OLDNAME_sciname" ]]; then
echo "Error: No line matching $OLDNAME in $DB_FILE"