Context Substitution Variables

[About Using IFS Enterprise Explorer Clients]

Explanation

Context Substitution Variables (CSV) and Query Macros are variables that can be used within IFS Applications in place of actual user input. For an example if you need to type in today's date into a date field when querying or ordering a report, instead of typing "3/20/2007", you could type "#TODAY#", and the framework will evaluate the date for you. That query can be then saved and reused without the need to change the entered date.

The use of Context Substitution Variables  and Query Macros allows the ability to reuse configuration in default profiles for multiple users, and over a long period of time. For an example, the end user can save a query for Customer Orders for which the wanted delivery time is due TODAY.

The difference between Query Macros and CSV's is that Query Macros can only be used in search dialog. For an example, you can save a search for Customer Orders for which the wanted delivery time is due THIS_WEEK. This saved query can be used forever.

In most places where the Context Substitution Variables can be used, the list of all valid CSVs will be available in a drop-down. Those can be recognized by the hash (#) marks surrounding them. If you need to enter a CSV by hand, you have to remember to surround it by the hash (#) marks by yourself.

Existing CSV:

CSV Name Description Sample Values
USER_DIRECTORY_ID Directory ID of the logged in user. ALEX
USER_EMAIL Email address of the logged in user. alex@ifsworld.com
USER_ID Logged in user ID. ALEX
USER_LANGUAGE Language currently in use by the logged in user. en
YESTERDAY Date & Time range beginning from the start of yesterday till the end of yesterday. 2006-10-02-00.00.00
START_OF_LAST_WEEK Date & Time value of the start of last week. 2006-09-24-00.00.00
END_OF_LAST_WEEK Date & Time value of the end of last week. 2006-09-30-23.59.59
START_OF_LAST_MONTH Date & Time value of the start of last month. 2006-09-01-00.00.00
END_OF_LAST_MONTH Date & Time value of the end of last month. 2006-09-30-23.59.59
START_OF_LAST_YEAR Date & Time value of the start of last year. 2005-01-01-00.00.00
END_OF_LAST_YEAR Date & Time value of the end of last year. 2005-12-31-23.59.59
TODAY Date & Time range beginning from the start of today till the end of today. 2006-10-03-00.00.00
START_OF_THIS_WEEK Date & Time value of the start of this week. 2006-10-01-00.00.00
END_OF_THIS_WEEK Date & Time value of the end of this week. 2006-10-07-23.59.59
START_OF_THIS_MONTH Date & Time value of the start of this month. 2006-10-01-00.00.00
END_OF_THIS_MONTH Date & Time value of the end of this month. 2006-10-31-23.59.59
START_OF_THIS_YEAR Date & Time value of the start of this year. 2006-01-01-00.00.00
END_OF_THIS_YEAR Date & Time value of the end of this year. 2006-12-31-23.59.59
TOMORROW Date & Time range beginning from the start of tomorrow till the end of tomorrow. 2006-10-04-00.00.00
START_OF_NEXT_WEEK Date & Time value of the start of next week. 2006-10-08-00.00.00
END_OF_NEXT_WEEK Date & Time value of the end of next week. 2006-10-14-23.59.59
START_OF_NEXT_MONTH Date & Time value of the start of next month. 2006-11-01-00.00.00
END_OF_NEXT_MONTH Date & Time value of the end of next month. 2006-11-30-23.59.59
START_OF_NEXT_YEAR Date & Time value of the start of next year. 2007-01-01-00.00.00
END_OF_NEXT_YEAR Date & Time value of the end of next year. 2007-12-31-23.59.59
DEFAULT_COMPANY String value of the standard company  
PERSON_ID String value of the personal identification of a person  
PERSON_NAME String value of the name  
USER_DIRECTORY_ID String value of the directory ID using either the form <Domain>\<Username>  or <Username> EUROPE\GBGKURS or GBGKURS
USER_EMAIL String value of the user email address  
USER_ID String value of the user ID  
USER_LANGUAGE String value of the user language  

Available Query Macros:

LAST_WEEK THIS_WEEK NEXT_WEEK
LAST_MONTH THIS_MONTH NEXT_MONTH
LAST_YEAR THIS_YEAR NEXT_YEAR