Is there any other way to add data into an entity without user input?

0
Any other alternative where we can manually add data in the Mendix database without form handling or using REST services?
asked
3 answers
3

if you mean that you want to create objects from an entity without any user input, you can use scheduled event run every 1 min and inside this scheduled event create the object that you need, or you can do the logic on After startup on runtime setting 

answered
0

You could use an excel importer for instance, but the sky is the limit. You could add data by scanning QR codes, you could implement AI that interprets smoke signals recorded on a webcam, etc. Can you explain a bit more about your use case? That could help us give more useful suggestions :)

answered
0

One thing we do in our Mendix 9 applications is to set up Deeplinks in the after-startup microflow. This populates the Deeplink entities when the application starts if they aren't already in the database.

 

You could take a similar approach to load dummy data. If the data always needs to be in a fresh state when you load up, you could create a microflow to wipe the entities you need to populate with test data, then use Create Object actions to load in test data. If there is a lot of data, maybe use CSV or Excel imports. You may want to add a constant that you check against at the start of the microflow so you can decide if you want the data to be preserved or reset. 

 

Another approach you could take would be to add the data manually and include it in a data snapshot.

https://docs.mendix.com/howto/data-models/sharing-the-development-database/#7-committing-the-data-snapshot

 

There are a number of options, and these are just a few ideas.

 

Good luck

answered