for l in $(cat u.csv); do IFS=',' read -a data <<< "$l"; psql -t -A -F "," -c '\x' -c "SELECT user_id,username,email,total_wins,total_food,average_food FROM users WHERE LOWER(email)=LOWER('${data[2]}') AND LOWER(username)=LOWER('${data[3]}');" $WOS_DB_CONNECT; done


psql -t -A -F "," -c '\x' -c "SELECT user_id,username FROM users;" $WOS_DB_CONNECT > username.csv