I have the following query that runs fine.
sprint in openSprints() and sprint not in closedSprints() and issue in (239562,437238) and issuetype != "sub task"
It runs in JQL
I have another qurey that runs in ScriptRunner
sprint in openSprints() and sprint not in closedSprints() and issueFunction in addedAfterSprintStart("Team Eagle Scrum Board") and issuetype != "sub task"
Somehow the portion in bold in the first query is pulling the results of the ScriptRunner query, but for the life of me, I cannot find any documentation on how that is set up.