У меня есть пакетный скрипт, который запускает команду SQL * Plus, и я наматываю вывод в файл CSV. Все выходы имеют только один столбец «count». Есть ли способ добавить текст к результатам?sqlplus и spool options
"The_current_valueOf Query1" "Count1"
"The_current_valueOf Query2" "Count2"
Любая помощь/совет будет принимаем во внимание.
set colsep ,
set pagesize 0
set trimspool on
set headsep off
set Newpage none
spool D:\TRHMIBS\TRH\TRHStats.csv
select count(*) from host.ufm where insert_time between trunc(sysdate) and sysdate
/
spool D:\TRHMIBS\TRH\TRHStats.csv APPEND
select count(*) from host.amendment where insert_time between trunc(sysdate) and sysdate and msg_source = 'AUDIT'
/
spool D:\TRHMIBS\TRH\TRHStats.csv APPEND
select count(*) from host.ufm_amendment where insert_time between trunc(sysdate) and sysdate and msg_source = 'DAS' and ext_token is null
/
spool off;
exit;