SQL: replace LF with placeholde in Select, the other way around in Insert

This commit is contained in:
Vincent Riquer 2026-02-15 03:24:09 +01:00
parent 03bbd70947
commit f8bb5377ae
2 changed files with 2 additions and 0 deletions

View File

@ -26,6 +26,7 @@ Insert() {
insert_values+=$value
;;
*)
value=${value//::AtOM:NewLine:SQL:Inline::/$'\n'}
insert_values+='"'"${value//\"/\"\"}"'"'
;;
esac

View File

@ -19,6 +19,7 @@ Select() {
while read key operator value
do
(( ${#where_statement} )) && where_statement+=( "AND" )
value=${value//::AtOM:NewLine:SQL:Inline::/$'\n'}
where_statement+=( "$key $operator "'"'"${value//\"/\"\"}"'"' )
done
echo "SELECT IFNULL(" \