Col command:
The display form of the primary formatted column.
The command has many options, as follows:
Col[umn] [{column|expr} [option ...]]
Option options can be the following clauses:
Ali[as] Alias
Cle[ar]
Fold_a[fter]
Fold_b[efore]
For[mat] Format
Hea[ding] Text
Jus[tify] {l[eft]| c[enter]| c[entre]| R[ight]}
Like {Expr|alias}
Newl[ine]
New_v[alue] Variable
nopri[nt]| PRI[NT]
Nul[l] Text
Old_v[alue] Variable
on| Off
wra[pped]| wor[d_wrapped]| Tru[ncated]
1). Change the default column headings
COLUMN column_name HEADING column_heading--Change the caption command the experiment didn't work out, I don't know what the problem is.
For example:
Sql>select * FROM Dept;
DEPTNO dname LOC
---------- ---------------------------- ---------
Ten ACCOUNTING NEW YORK
Sql>col LOC Heading Location
Sql>select * FROM Dept;
DEPTNO dname Location
--------- ---------------------------- -----------
Ten ACCOUNTING NEW YORK