I have written three hive queries in shell script for calculating debit-credit and target amounts which output below values:
debit_amount : BOI 4760545.650000 AXIS 284.49000000 SBI 87.220000000 ICICI 14199.66000
credit_amount : BOI 3424.65 AXIS 43.4546 SBI 4.54546 ICICI 3423.3465
target_amount : BOI 4757121.000000 AXIS 241.0354 SBI 82.67454 ICICI 10776.3135
now I want to calculate debit-credit amount for each bank and compare with target_amount value
How to write it in shell script?
I tried with awk command but didn't get required output.
grep -Eo
. Check both flags inman grep
.