Click or drag to resize

How to bulk import instruments from a txt file

ArthaChitra has a import feature which facilates user to append instrumnet from a txt file. This is helpful in case user is appneding a large number of instruments.

How to import a txt/zip file

Please follow the below steps to import a Instrument.txt file into ArthaChitra

  • Download the txt or zip file. If the instrument file is in zip format then extract the txt file.
  • In ArthaChitra Main View menu bar, goto Settings > Instruments > Import
  • In the 'Import Instrumen Definition View' select the 'Default Instrument Definition Import Type' from the dropdown menu and click on the Import button
  • In the file selector dialog select the Instrument txt file you want to import
  • Restart ArthaChitra when prompted
Instrument bulk import format

The instrument txt file is a text file separated by ';' (semi-colon - without the ')

The header format for the txt file will be:

@Name;@Description;@InstrumentType;@Exchange;@Currency;@TickSize;@SessionTemplate;@Rollover;@PointValue;@DefaultQuantity;@QuantityDivisor};@Adapter Symbols;@Dividends;@Splits

The below table further clarifies the fields.

Field

Type

Description

Name

String

Max length 255

Description

String

Max length 255

Instrument Type

Int32

InstrumentType

Exchange

Int32

Exchange

Currency

Int32

Currency

Tick size

Double

Tick size of the instrument

Session Template

String

Session Template

Rollover

String

String value (applicable for Futures scripts only)

Point value

Double

Point value of the instrument

Default quantity

Int32

Default quantity

Quantity divisor

Int32

Quantity divisor - this is reserved from fractional shares

Connection symbols

String

Connection symbol separated by ',' (comma - without the ')

Dividends

DateTime-Double

Date-Amount (separated by ',' (comma - without the ')

Splits

DateTime-Double

Date-Factor (separated by ',' (comma without the ')

Note: Entries begining with '#' (without the ') are treated as comments and will be ignored

Instrument List format

An Instrument List is a text file separated by ';' (semi-colon without the ') having 3 (three) fields namely

  • @InstrumentList: Each line must start with '@InstrumentList' indicating its an instrument list.
  • Name of the list: Custom name of the instrument list.
  • Instrument name: Name of instrument(s) separated by ',' (comma without the ').

An example will be:

@InstrumentList;Cash;^NIFTY NSE,BERGEPAINT NSE,ONGC NSE,RELIANCE NSE,TVSMOTOR NSE,BANKNIFTY 05 2022 NSE

Note: The Instrument names must conform the naming convensions as mentioned here