Cut Utility Example - Sybase 12.5.1 User Manual

Historical server
Table of Contents

Advertisement

Cut utility example

User's Guide
device_name
device_reads_val
device_writes_val
device_io_val
)
go
4
After the recording session is complete, you can use
from the view's data file into the database table. Use the following
commands:
bcp pubs2..device_io in d1_1_device_io -c
-e d1_1_device_io.err -Uusername
-Ppassword -Sserver -t
If you are on a UNIX machine, you can put subsets of the fields from data files
into separate Adaptive Server tables if you first invoke the
and save the desired columns from the file. Use the following command:
cut -flist -d, view_data_file > output_file_name
where:
list is a comma-separated list of the field numbers that you want to cut and
save from the original view data file. The first field has field number 1.
view_data_file is the name of the file where all of the recording data is
stored.
output_file_name is the name of the file where the stripped data is to be
stored.
After using
, you can use the
cut
output_file_name into an Adaptive Server table. Historical Server might return
lines to the view_data_file that are similar to:
1995/3/25 10:32:39,master,0,0,0
1995/3/25 10:32:39,sysprocsdev,0,0,0
1995/3/25 10:32:39,ANewDBDevice,0,0,0
1995/3/25 10:32:39,ATestDevice,0,0,0
1995/3/25 10:32:40,master,0,0,0
1995/3/25 10:32:40,sysprocsdev,0,0,0
1995/3/25 10:32:40,ANewDBDevic,0,0,0
1995/3/25 10:32:40,ATestDevice,0,0,0
CHAPTER 5
varchar (255)
int
int
int
utility to import the data in the
bcp
Data Files
null,
null,
null,
null,
to import data
bcp
utility to strip
cut
101

Advertisement

Table of Contents
loading

Table of Contents