Retrieve user data and use it as a variable

Hi all, I am building an application where I import some data from a database. The problem is that different users should have access to different portions of the data. Just to make an example. As soon as I import the table below in Mendix, I want that: Anna is able to see only the projects Goldfinger and Thunderball, Beatrix is able to see only project Goldfinger, and so on. Now, my idea would be to catch in some way the user data (when the user logs into the app) and use this data (e.g. the email) as a filter when retrieving the table from the database (using OData syntax and so on, which is pretty straightforward). Does anyone know how can I get this user data in Mendix? it hasn’t be necessary the email, but something user specific which I then will use in my table
1 answers

Within a microflow you can always retrieve the current user account by doing a retrieve first Account object where your xpath is something like:


Then if accounts are associated to projects you could either have your page contain an account dataview and display a grid of related projects, or you could put an XPath on your project entity directly for your users to only ever be able to see related projects.

Hope this helps.