Virtual

The Virtual table type is computed at runtime by the system. A Virtual table contains data and is accessed like other tables, but we cannot modify either the definition or the contents of a Virtual table. We can think of the Virtual tables as system data presented in the form of a table so it is readily available to C/AL code. Some of these tables (such as the Database File, File, and Drive tables) provide access to information about the computing environment. Other Virtual tables (such as Table Information, Field and Session tables) provide information about the internal structure and operating activities of our database. A good way to learn more about any of these tables is to create a list or card page bound to the table of interest. Include all the fields in the page layout, Save the page and Run it. We can then view the field definition and data contents of the target virtual table.

Some virtual tables (such as Date and Integer) provide tools that can be used in our application routines. The Date table provides a list of calendar periods (such as days, weeks, months, quarters, and years) to make it much easier to manage various types of accounting and managerial data handling. The Integer table provides a list of integers from -1.000.000.000 to 1.000.000.000. As we explore standard NAV reports, we will frequently see the Integer table being used to supply a sequential count in order to facilitate a reporting sequence (often in a limited numeric range such as 1 or 1 to 10).

We cannot see these tables presented in the list of table objects, but can only access them as targets for pages, reports, or variables in C/AL code. Knowledge of the existence, contents, and usage of these Virtual tables are not useful to an end user. However, as developers, we will regularly use some of the Virtual tables. There is educational value in studying the structure and contents of these tables, as well as having the ability to create valuable tools with knowledge of and by accessing of one or more Virtual tables.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
18.219.208.117