Click here to Login





                                                   Automatically create field names for columns in ASCII import

  0

0
Bryan Pettitt
2011-02-05 15:56:42


When doing an ASCII import using a csv file, is there a way to have it automatically create and fill in the field names?
I am importing 34 fields and it is very intensive to create the field names and then manually assign them to the columns.



QuantShare
2011-02-07 05:01:49



Yes it is possible.
In the parser settings form, click on "Pre-Script".

You can update field names (Parser columns) using the function "Content.SetDatabaseAndField".
If the database/field do not exist then it will be created.

Example:
The first line of the CSV data is:
Symbol;Date;PER;PEG;PS;PC

In the Pre-Script you can type:

PreScriptRow row = Content.Rows[0];
row.IsIgnoreLine = true;
int columnStarts = 2;
for(int i=columnStarts;iClose) for example.



No more messages
0




Reply:

No html code. URLs turn into links automatically.

Type in the trading objects you want to include: - Add Objects
To add a trading object in your message, type in the object name, select it and then click on "Add Objects"










QuantShare

Trading Items
Industry and Sector Information for the US Stock Market
Historical EOD data for Saudi stocks
Extensive Fundamental Data for U.S. Stocks
Put/Call Ratio for Individual Stocks
EOD Data - End of day data for U.S. Stock Market

How-to Lessons
How to import trading data from CSV files
How to automatically draw Fibonacci Retracement for each new stoc...
How to quickly select stocks based on the last value of a databas...
How to automatically arrange charts?
How to create a watchlist

Related Forum Threads
ASCII IMPORT -HOW CANCWE DELETE DATA FOR A WRONG DATE
Need downloaded or ascii import of nse equities that trade in fut...
Create and Export each database for each market
ASCII Import Limitation
Monthly/weekly summation for a custom database field

Blog Posts
How to Automatically Import Local Data Into QuantShare
How to Create Custom Metrics for Your Trading Positions
Automatically create historical quotes charts
Different Ticker Symbols for Each Data Source
Create custom metrics for the statistical data analysis tool









QuantShare
Product
QuantShare
Features
Create an account
Affiliate Program
Support
Contact Us
Trading Forum
How-to Lessons
Manual
Company
About Us
Privacy
Terms of Use

Copyright © 2024 QuantShare.com
Social Media
Follow us on Facebook
Twitter Follow us on Twitter
Google+
Follow us on Google+
RSS Trading Items



Trading financial instruments, including foreign exchange on margin, carries a high level of risk and is not suitable for all investors. The high degree of leverage can work against you as well as for you. Before deciding to invest in financial instruments or foreign exchange you should carefully consider your investment objectives, level of experience, and risk appetite. The possibility exists that you could sustain a loss of some or all of your initial investment and therefore you should not invest money that you cannot afford to lose. You should be aware of all the risks associated with trading and seek advice from an independent financial advisor if you have any doubts.