This article will give you a basic idea on how the usage of RefRecId is changed from AX 3.0 to AX 4.0
In AX 3.0 the RefRecId is generated unique per company where as in 4.0 its generated unique per table. This makes difficult to refer to RefRecId in 4.0.
You can easily refer to EDT RefRecID as they are unique per company where as in 4.0 it would not be possible. For Example 5637144576 can be there in both Address table as well as AddressCountryRegion or any table in AX...
To avoid this in 4.0 you can use a new EDT which extends EDT RefRecId and create a relation on the new EDT.
For example, Table VendTansOpen has field RefRecId which extends new EDT VensTransOpenRefRecId which extends EDT RefRecId. Create a relation on VensTransOpenRefRecId as "VensTransOpenRefRecId= VendTansOpe.RefRecId
That is how you refer to RefRecId in 4.0.
Exploring more on RecIds in my future posts