Database Connector --> Execute Query is not working.

Hi Team,   I am facing issue while using execute query for getting list of records from the database. Configuration is done in “Execute Query” as shown below:-   I am getting the way to return list of emp in returnObject.   I am getting below objects only. while deploying objects I am getting NULL pointer exception as below:-     Could you please help me out to resolve this issue and achieve the select query targets from external mysql DB.  
3 answers

Hi Priya Kataria,

            I think you have mapped empty in the Result Object dropdown. Create one persistable helper entity with the name you like. For example “Employee”. You want to retrieve the FirstName of all the employees in your emp table. So, create one FirstName attribute in that Helper entity (Employee). 

Before the Execute Query activity, create one Helper entity object (Employee) and then pass this object into the Result Object section. I hope It will work! Can you test and let me know If you face any issues regarding that!


Thanks and regards,



If your result entity object in Mendix is called empty I would change the name. I think that is a reserved word. It seems you are doing something with persons so rename it to that and try again. And do make sure that the username and password is correct.





What result do you get if you run your query directly to the MySql database?