How to get the ResultSet Object to the client

I have established the connection in the gateway scope using GatewayContext context

con = context.getDatasourceManager().getConnection(“mySQL”);
Statement stat = con.createStatement();
rs = stat.executeQuery(“Select * from test_1.currency;”);

I have executed the query and now have a resultset.

I need this ResultSet Object in the Client scope to fill a table component.

How do i get a ResultSet Object in the client scope?

A ResultSet object won’t work in the client – it needs its connection object. You need to process the resultset into a Dataset object, and send that to the client. Hint: look at the BasicStreamingDataset() constructors.