Interday queries

Interday queries reflect price quotes and trade prices during multiple trading days. These queries examine the tick data of the current day plus historical data and can provide an alert for changes to statistical models during the course of the trading day.

The Interday queries are optimized to run with the Risk Analytics Platform sample data in VLDBServer.

NoteThe Interday queries for VLDBServer all begin with a commit statement. This commit statement causes the data to refresh, so the query accesses the most recent data. When you write your own queries for VLDBServer, be sure to precede the query with a commit statement.

Script name

Description

interday_tick_qry1.sql

Determine the volume-weighted price of a security considering only the ticks in a specified three-day interval.

interday_tick_qry2.sql

Determine the top 10 percentage losers for the specified date on the specified exchanges, sorted by percentage loss. The loss is calculated as a percentage of the last trade price of the previous day.

interday_tick_qry3.sql

Find the most active stocks in the “COMPUTER” industry for last three days.