0

I have a workorder management system (WMS).

  • The WMS has functionality that allows users to save queries.
  • The queries are saved in a Oracle database table called QUERY (in a CLAUSE column).

An example of a value in the CLAUSE column would be:

((woclass = 'WORKORDER' or woclass = 'ACTIVITY') and contains(description,'$paint') > 0 and historyflag = 0 and istask = 0 and siteid = 'SERVICES')


I would like to utilize the saved WMS queries by applying them as filters to layers in a Portal web map.

From a drop-down menu, a user would choose a CLAUSENAME (from the QUERY table), the widget would programmatically extract the WHERE clause value from the CLAUSE column, and use it to automatically filter a layer.

To be clear, this would be a programmatic/custom widget solution, not manual copying and pasting.

Is it possible to do this?

  • Totally possible. You just need to construct your SQL statement to include the chosen filter clause. Unless I miss something, this is trivial – Albert Godfrind Oct 16 '19 at 4:47
  • @AlbertGodfrind : I edited the question to try to make it clearer that I'd like a custom widget to do this programmatically, not the user to do it manually with copy/paste. In hindsight, I might need to rewrite the question. – User1973 Oct 16 '19 at 10:50
  • There was never a question about the user doing any copy / pasting. The user selects the filters to apply (drop down list or similar) and the application then constructs the proper SQL statement and sends it for execution to the database – Albert Godfrind Oct 17 '19 at 12:04

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.