in the entity generation process for Aurelius (and clearly Xdata) the fields that are used for foreign keys are missing. So we don't know their value in entities.
But these are REQUIRED for direct and optimized queries and for passing data into custom classes and vice versa, otherwise those values are missing.
Please include this possibility (even as an option) in the model generation in order to have the complete classes of all the fields present in the DB. Currently these fields are not present.