Skip to Main Content
Autodesk
Status For Review
Categories Automation
Created by Nathan Gerdts
Created on Jun 25, 2024

Ruby support for 'run_sql' method to return results

The method WSOpenNetwork.run_sql supports running a SQL query on the current network and results, e.g. to select and update objects in the network: Help | WSOpenNetwork | Autodesk. The current method cannot return the results of a SELECT query i.e. anything that would open in a grid.


SQL queries are useful because they're much faster to execute when aggregating fields and results, and users starting out with Ruby may be more familiar with it. I think this would be a useful addition, since the only workaround is to use an 'INTO FILE' statement which is quite messy (the type of statement determines where it needs to go, the user still has to open and parse the result, etc).

  • Attach files