17,141
社区成员




Specifying Filler Fields
A filler field, specified by FILLER, is a datafile mapped field that does not correspond to a database column. Filler fields are assigned values from the data fields to which they are mapped.
Keep the following in mind with regard to filler fields:
The syntax for a filler field is same as that for a column-based field, except that a filler field's name is followed by FILLER.
Filler fields have names but they are not loaded into the table.
Filler fields can be used as arguments to init_specs (for example, NULLIF and DEFAULTIF).
Filler fields can be used as arguments to directives (for example, SID, OID, REF, and BFILE).
To avoid ambiguity, if a Filler field is referenced in a directive, such as BFILE, and that field is declared in the control file inside of a column object, then the field name must be qualified with the name of the column object. This is illustrated in the following example:
LOAD DATA
INFILE *
INTO TABLE BFILE1O_TBL REPLACE
FIELDS TERMINATED BY ','
(
emp_number char,
emp_info_b column object
(
bfile_name FILLER char(12),
emp_b BFILE(constant "SQLOP_DIR", emp_info_b.bfile_name) NULLIF
emp_info_b.bfile_name = 'NULL'
)
)
BEGINDATA
00001,bfile1.dat,
00002,bfile2.dat,
00003,bfile3.dat,
--这个可以在sqlplus里完成
spool d:\a.csv
select a fa,b fb,d fc from tab1
spool off
--这样在d盘就要个a.csv文件