MarketData Folder

MarketData Folder

The MarketData folder contains a ready-to-use solution for

  • Loading key statistics, quotes, industries, historical prices, dividends, and options
  • Importing data into a Microsoft SQL Server database

The solution is configured for US exchanges.

You can adapt it to load data from exchanges in other countries like UK, Canada, Europe, or Australia.

Quick Start

  1. Unzip MarketData.zip of the downloaded package to the C:\MarketData folder.
  2. Open Start Menu, All Programs, MARKET.CSV, Register Product to activate the 15-day trial.
  3. Place your tickers to C:\MarketData\symbols.txt.
  4. Run the C:\MarketData\0-run-all.cmd batch file.
  5. Open CSV files in the C:\MarketData\csv folder, for example, in Microsoft Excel.

You can edit symbols in symbols.txt and run the batch file again.
The application will load data for new symbols and reload data for others if the market is open.

Next Quick Steps

You can test the following steps if you have Microsoft SQL Server installed.

  1. Create database tables using SQL codes from the files:
    C:\MarketData\bin\mssql-create-database-google.sql
    C:\MarketData\bin\mssql-create-database-msn.sql
    C:\MarketData\bin\mssql-create-database-yahoo.sql
  2. Edit the connection credentials and uncomment commands in the C:\MarketData\3-import-data.cmd file.
  3. Run the C:\MarketData\0-run-all.cmd batch file.
  4. Select data from database tables like yahoo.QuoteSummary or yahoo.AssetProfiles.

That's all. You can put your tickers to symbol files and add batch files to Windows Scheduler to load data automatically.

Do not hesitate to contact us if you need a solution for your database platform.

Subfolders

FolderDescription
csvThe folder contains output CSV files to load into a database.
The files are deleted after a successful import.
cacheThe folder contains outputs of the YahooFinanceHistoricalPrices provider (not actual since version 2.2).
downloadsThe folder contains archives of downloaded data.
Archives contain data for a single provider and trade date.
Keep these files to have the possibility to reparse the loaded data.
zipThe folder contains archives of output CSV data.
You can use these files to import data into a database once again.
If you successfully import data and make a backup of your database, you can delete these files.
logsThe folder contains log files.
You can delete these files at any time.
binThe folder contains SQL codes and format files used to import CSV files into SQL Server.
Also, the folder contains SQL codes to create and remove MarketData Database.

Project Files

FileDescription
symbols.txtThe file contains symbols for download.
You can place your tickers into the file using any text editor or export symbols from your database.
You can create multiple files for different modes.
For example, you can load quotes for 2000 weekly monitored stocks
and daily options data for 200 most actively traded stocks.
0-run-all.cmdThe batch file executes download and import operations.
Use this file in Windows Schedule for automatic data download.
1-export-symbols.cmdThis file is a dummy. You can add commands to export tickers from your database to symbol files.
2-download-data.cmdThe batch file executes download operations.
The file contains commands for loading key statistics, quotes, industries, historical prices, dividends, and options.
3-import-data.cmdThis file executes import operations.
It contains calls of the sqlcmd utility to execute SQL scripts from the bin folder.
Edit the sqlcmd command if you have another SQL Server instance or other database credentials.
bin\clean-data.cmdThis file cleans the loaded data and related files.
Use it if you want to reset the loaded data completely.
bin\YahooQuotes.fmt
bin\YahooOptions.fmt, etc.
SQL Server uses the format files to import CSV files.
You can edit these files if you need to change column names.
Reflect such changes to SQL scripts in the bin folder.
bin\mssql-import-YahooQuotes.sql
bin\mssql-import-YahooOptions.sql, etc.
SQL scripts are used to import CSV files into SQL Server.
The files contain direct paths to CSV and format files like
C:\MarketData\csv\YahooQuotes.csv
C:\MarketData\bin\YahooQuotes.fmt
Edit such paths if you place the MarketData folder in another location.
bin\mssql-create-database-google.sql
bin\mssql-create-database-msn.sql
bin\mssql-create-database-yahoo.sql
bin\mssql-remove-database.sql
SQL scripts to create and remove MarketData Database.