RE: How to get the Data from the Resultset
Yes, it's technically possible. It's not recommended for many reasons.
Also it's possible that Microsoft prevents you from shipping customizations where direct SQL queries are used.
There's a new tool called AppChecker, which is still in preview. This tool checks for many things and one thing is looking for direct SQL statements in your code. In the future it might be that MS will prevent you from using code that violates the AppChecker rules.
So I would not invest in a solution that includes direct SQL queries in x++ code.
General info about AppChecker: ariste.info/.../
Here's the rule that checks for direct SQL: github.com/.../DirectSQL.xq