Subject: Better way to process records in bash?

From: Ron Johnson <[email-masked]>
Date: Thu, 12 Sep 2024 11:08:16 -0400

(This might be a bash question instead of a PG question, or it might be an
A/B question.)

I need to process table records in a bash script.  Currently, I read them
using a while loop and redirection.  The table isn't that big (30ish
thousand rows), and performance is adequate, but am always looking for
"better".

Here's the current code:
declare f1 f3 f8
while IFS='|' read f1 f3 f8; do
    something f8 f3 f1
done < <(psql -XAt -c "select f1, f3, f8 from some.table_name;")

-- 
Death to America, and butter sauce.
Iraq lobster!

---

From: Thiemo Kellner <[email-masked]>
Date: Thu, 12 Sep 2024 17:42:44 +0200 (GMT+02:00)

Hi

What is this "something" that it cannot be calculated within the dB?