Introducing Investar Query Language – IQL

Investar Query Language (IQL) is a super new advanced language built by Investar, that allows you to define more advance queries for the Custom screener that were simply not possible before.

Our goal is to give you a good enough understanding of the technology to fully leverage the possible advantages of technical analysis.The Investar Custom Screener allows the use of both IQL (Investar Query Language) and IEL (Investar Easy Language) in a hybrid mode, IQL Only mode and IEL Only mode.

IQL (Investar Query Language) provides a simple and user-friendly medium to enable the users to use the inbuilt indicators, candlesticks, price action, and other many technical analysis tools by minimal coding. IQL is easy to pick up for those who are familiar with the C-language.

Here are some steps you want to take to accelerate the learning process and increase your fluency in the IQL.

First let us try to understand the Basic Structure of IQL:

The structure of the language is divided into two sections:

1. Declarations– a declaration is a statement that describes an identifier, such as the name of a variable or a function.

2. Final variable -Final variable section will have the variables present in declaration section which defines the final Buy/Sell signal.

IQL syntax

IQL and IEL mode

On clicking the “Manage Scans -> Custom Scans -> Create Custom Scan” you will be displayed a GUI for creating custom scans which uses the Investar Easy Language (IEL). See the figure below. The window will also have a toggle switch which can beused to simply move to IQL editor, to see the equivalent representation in IQL. You can also add pure IQL sub-queries by using an “IQL” variable (e.g. IQL0 in the below figure).

The example below defines an Auto-Support/Resistance based volume breakout where the current candle is not a boring candle. This can be easily done in IEL-IQL Hybrid mode in the following steps:

1.      Switch to IEL Mode.

2.      Define the Auto-SR breakout (in Auto-SR category).

3.      Define criteria for above average volume

4.      Add a IQL sub-category. Click on IQL0 link to switch to IQL mode and complete the RHS to get the expression for IQL0. This allows to define a mathematical operation on the OHLC of the current candle, which defines a candle that is not a boring candle.


Illustration 1: IEL Window

IQL Window

Illustration 2: IQL Window

IEL-IQL hybrid mode is generally recommended for beginner to intermediate users of custom screener as it helps them learn the IQL by easily creating sub-queries in IEL mode and then switching to IQL mode to see the equivalent sub-queries in IQL mode. This hybrid approach is what makes it very easy for anyone to start using the Investar Custom Screener, as compared to other screeners out there.

IQL only mode is specially designed for advanced users who want to exploit the arithmetic operations and complex query structures. Users can use the different indicators, price action, Auto SR, inbuilt candlestick patterns and many other operations like breakout, breakdown and crossover to greatly simply creating complex queries which in other languages like AFL and MQL require a lot more lines of code.

One can enable IQL only mode the same way as the other two above modes. Go to “Tools -> Options” and in the Custom Scan Tab, select the IQL option.

IQL supports the following syntax:

  • Inbuilt Identifiers,
  •  Local variables
  • Inbuilt functions
  • Binary Operations
  •  Disable Subquery

For more details you can download the full IQL reference manual and try out the latest Investar Beta here: .

We hope this post has given you some new ideas on creating and testing your own customs scans using IEL-IQL hybrid mode.

Check out for this Video for a more detailed explanation:


Leave a Reply

Your email address will not be published. Required fields are marked *