You can either run a script or use the automated load process to load the TAQ sample data located in the %Sybase%\Data\ASE\RAP_Input directory on Windows. Before choosing either method described in this section, be sure you have unzipped and transferred the sample data .csv files as described in “Preparing the TAQ sample data”.
To load the TAQ sample data only into the RAP cache, run the load_unix_ASE_TAQ_tables.sh script from a command window on the machine that hosts the ASE database or on a client machine. This script uses the bulk copy utility bcp to load the sample data into the rapt and rapq databases. Errors are written to the files STOCK_TRADE.err and STOCK_QUOTE.err.
To check the status of the data loads, review the log file for Adaptive Server Enterprise. The default location of the ASE log file is $SYBASE/$SYBASE_ASE/install/<servername>.log on UNIX platforms.
Use the automated load process to load the TAQ sample data into both the RAP cache and the RAP repository.
Remove any TAQ sample data already loaded in the RAP cache
or you will receive “Duplicate row”
errors.
See the section “Clearing the cache” for information on how to remove
the data from the RAP cache.
If the TAQ sample data is not in the RAP cache, follow these instructions before you start the automated load process.
Divide the STOCK_QUOTE.csv file into smaller batch files using the split command:
split -l 500000 STOCK_QUOTE.csv STOCK_QUOTE.csv.
This command creates several files called STOCK_QUOTE.csv.nn (where nn is an automatically generated two character suffix beginning with aa, ab, ac, and so on) which contain 500,000 rows each. This step is optional, but is recommended.
The number of rows specified in the split command
may need to be adjusted to an appropriate value for the physical
resources on your system to improve load performance.
Divide the STOCK_TRADE.csv file into smaller batch files using the split command:
split -l 250000 STOCK_TRADE.csv STOCK_TRADE.csv.
This command creates several files called STOCK_TRADE.csv.nn (where nn is an automatically generated two character suffix beginning with aa, ab, ac, and so on) which contain 250,000 rows each. This step is optional, but is recommended.
Copy all of the STOCK_QUOTE.csv.nn and STOCK_TRADE.csv.nn files into the $RAP_IN input directory of the automated load process.
Run $RAP_HOME/rap_start_pl.sh to start the automated load process, if the load process is not already running.
Copyright © 2005. Sybase Inc. All rights reserved. |
![]() |