Allow table fields to reference process queries, but only for single record questions - #142
Merged
Conversation
Foxcapades
approved these changes
Jul 31, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
TableFields allow a table of data (rows/cols) to be added to an instance of a WDK recordclass (e.g. a gene). The way these traditionally work is the model writer adds a SqlQuery to the XML that returns all rows of the table for all records (including ID columns), then WDK either joins to a cached set of IDs (for a gene search result), or adds a where clause when looking for a single records (gene), which is what we use when displaying tables on the record page (gene page).
DataDev requested the ability to use a process query (WSF plugin/Java code) instead of a SQL query to provide the tables. This has been a longstanding request but we have resisted because we would have to decide how to feed the process query the genes we want tables for (could be many for search results) e.g. Implement some sort of streaming logic? Give the process query the ID SQL?
In this case, they're ok with it being allowed only for the single record case (not search results), so the content of this PR is:
For an example process query to serve this purpose, see: VEuPathDB/ApiCommonWebService@master...table-process-queries