Documentation>Application Documentation>XMIM Documentation>XMIM Examples>AS_LONG_AS Example

AS_LONG_AS Example
 

The "AS_LONG_AS" statement lets you distill down the results of an execution to eliminate the unwanted answers from your query results and reduces the noise and clutter that make it hard to see what is really happening. Here is a simple LET statement that makes use of the "AS_LONG_AS" constraint to show all the actively trading contracts for a particular futures market:

Example 1:

LET
theMarket = CONTRACTS US

AS_LONG_AS
  number_of_occurrences is more than 0
  

Summary:  The "AS_LONG_AS" constraint may be used by selecting the Options button within a LET window. After you have defined your Variable within a LET Statement select the Options button before exiting the LET window. "AS_LONG_AS" requires selection of a Condition criteria.

Example 2: Which pipelines as quoted by Platts have a differential to Henry Hub greater than .35 cents?    
 

LET
 Platts = TopRelation:Energy:NaturalGas

AS_LONG_AS
  number_of_occurences is more than 0

SHOW
  HubDifferential: Index of Platts - Index of IGBBL21

WHEN
  Date is within 0 days

AND
  Index of Platts - Index of IGBBL21 >.35

 

Summary: AS_LONG_AS is an XMIM report filter that in this case eliminates non-Platts data.