Re: SQL*Plus break header
Date: Mon, 10 Nov 2003 22:14:25 +0100
Message-ID: <booukh$ll8$1_at_news4.tilbu1.nb.home.nl>
Phil Bewig wrote:
> I am using SQL*Plus and ordinary SQL (no PL/SQL) to create a
> report. I would like to write a header line each time a field
> breaks:
>
> Acct Description TranDate Budget Actual
> ---- ------------------- -------- --------- ---------
> 1234 Inventory
> Beginning balance 100,000 140,000
> Purchases 11/07/03 25,000 50,000
> Cost of sales 11/19/03 -25,000 -40,000
> Ending balance 100,000 150,000
>
> Here, 1234 is an account number and Inventory is an account
> name. The basic report is simple enough to write, using the
> acct and acct_title fields. But there isn't room to write
> those fields on the same line as the rest of the data, and
> there is no need to duplicate the fields, so I want to write
> them on a header line each time there is a break in the acct
> field. I thought of
>
> COLUMN acct FORMAT A4
> COLUMN acct_title FORMAT A35 FOLD_AFTER
> COLUMN space FORMAT A4 ''
> ...
> BREAK ON acct NODUPLICATES
>
> but that doesn't work. COMPUTE lets me put a footer on each
> break field, but I want a header on each break field.
>
> Can anyone suggest a solution?
>
> Many thanks,
>
> Phil
Something like 'new value' pops to mind
-- Regards, Frank van BortelReceived on Mon Nov 10 2003 - 22:14:25 CET
