1.02-01 Use "Current" in Version settings

Utilising the Current (and Actual) check box within the Version Settings allows the use of CURRENTVERSION() and ACTUALVERSION() in calculations, in SELECT statements and  ISCURRENTVERSION and ISACTUALVERSION() for Boolean checks.  Current version also acts like a top level for Versions; if you have a source module with versions (and Current ticked), in a target module without versions, the value from the current version will automatically be returned without needing additional functions or SELECT statements

 

Related Rule:
2.02-14 Avoid using SELECT

Comments

  • Rule 1.02-01 Use Current Version setting Utilizing the Current Version (and Actual Version) within the Version Settings allows the use of CURRENTVERSION() and ACTUALVERSION() for use in calculations and SELECT statements and  ISCURRENTVERSION and ISACTUALVERSION() for Boolean checks

    Use Case: To populate the current version numbers (Forecast) in your target module

    Here is how it was done in Pre Planual Era.

    Source Module having data in multiple versions

    Misbah_3-1599470341201.png

    Misbah_2-1599470320591.png

    What is wrong with this method? We don’t need to write SELECT statement in such cases. We can avoid system doing that extra work to pull the numbers

    Here is how it should be done in Planual Way: Go to Versions and mark Forecast Version as Current VersionMisbah_4-1599470366945.png

    Simply refer the line item from Source Module

    Misbah_5-1599470372730.png

    Note: There are other benefits of using Current Version settings in your model such as the usage of CURRENTVERSION() and ISCURRENTVERSION