mendix / docs

Mendix documentation repository
https://docs.mendix.com
Creative Commons Attribution 4.0 International
141 stars 724 forks source link

execute-an-sql-statement-on-an-external-database #5229

Closed cyeongb closed 1 year ago

cyeongb commented 2 years ago

Please use the form below, leaving the prefilled data to help us. Thank you.

Page link: execute-an-sql-statement-on-an-external-database

Document link: execute-an-sql-statement-on-an-external-database.md

My Issue/Suggestion

I want to know about "Result Object" in Execute Query section. i can't find way that how to set the result object properly and how to use that please add that part and update the documents("Execute an SQL Statement on an External Database") thank you.

johannahemminger commented 1 year ago

Hi @cyeongb , thanks for opening this issue. Indeed, this doc does not cover the Execute Query action, just the Execute statement.

I checked with the team, and regarding your question, you have to create an actual object of the entity that will reflect the structure of the result set. The Java action needs the Result Object for mapping. It is an empty object; the only purpose is to pass on the structure, as Java actions can't access the model. Does this help? In the meantime, I will work on clarifying this in the connector documentation (see PR https://github.com/mendix/docs/pull/5291) and will add another use case/doc for executing a query.

johannahemminger commented 1 year ago

I'm going to close this issue, but if you have any other ideas for improving our docs please let us know!