René's URL Explorer Experiment


Title: fix: check functions in PIVOT clauses of FROM items by tanjiroK-coder · Pull Request #2945 · JSQLParser/JSqlParser · GitHub

Open Graph Title: fix: check functions in PIVOT clauses of FROM items by tanjiroK-coder · Pull Request #2945 · JSQLParser/JSqlParser

X Title: fix: check functions in PIVOT clauses of FROM items by tanjiroK-coder · Pull Request #2945 · JSQLParser/JSqlParser

Description: FromItemVisitorAdapter never walks the PIVOT / UNPIVOT clause the grammar attaches to a FROM item: visit(Table) returns immediately, and the derived table, LATERAL, table function, parenthesized join and VALUES visits ignore getPivot() / getUnPivot(), so only MATCH_RECOGNIZE walked its pivot (SelectVisitorAdapter checks PlainSelect.getPivot(), which the parser does not set for this syntax). StatementFeatureVisitor is built on that adapter, so the aggregate calls of an Oracle PIVOT never reach the pure-function check: SELECT * FROM t PIVOT (sum(purge_audit()) FOR a IN (1)), the same clause on a derived or joined table, and a PIVOT XML IN subquery that calls a function come back with mayModifyData() == false and no unresolved reference and pass the read-only guard in usage.rst, while SELECT purge_audit() FROM t leaves MODIFIES_DATA possible with unresolved=[purge_audit]. Oracle takes any expression as the aggregate argument, and a user-defined aggregate in that position was not reported either. Validation had the matching gap: SelectValidator.visit(Pivot) only validated the FOR columns while visit(PivotXml) also validated the aggregate calls, so with Feature.pivot allowed and Feature.function removed, SELECT * FROM t PIVOT (max(upper(a)) FOR b IN (1)) validated with no errors and the PIVOT XML form did not. I found it while comparing the FROM-item clauses TablesNamesFinder walks with the ones the adapter walks. The adapter now walks the pivot of every FROM item through the PivotVisitorAdapter it already used for MATCH_RECOGNIZE, and visit(Pivot) validates the aggregate calls as visit(PivotXml) does; the IN values are left out there, since SQL Server writes them as bracketed identifiers that are not columns. Four new functionIsChecked cases and one testValidateFunctionOutsideWhere case fail before (5 failures) and pass after; spotless, Checkstyle, PMD and SpotBugs pass, and the rest of ./gradlew test is unchanged (the only local failures are 33 Mockito inline-mock-maker init errors and 2 temp-dir access errors, which fail the same way on master on this Windows machine).

Open Graph Description: FromItemVisitorAdapter never walks the PIVOT / UNPIVOT clause the grammar attaches to a FROM item: visit(Table) returns immediately, and the derived table, LATERAL, table function, parenthesized jo...

X Description: FromItemVisitorAdapter never walks the PIVOT / UNPIVOT clause the grammar attaches to a FROM item: visit(Table) returns immediately, and the derived table, LATERAL, table function, parenthesized jo...

Opengraph URL: https://github.com/JSQLParser/JSqlParser/pull/2945

X: @github

direct link

Domain: redirect.github.com

IPv4 address: 140.82.112.4

react-profiling0
react-import-mapreact,react-dom,react-dom/client,react-dom/profiling,react-is,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@b8488ee2c322
route-pattern/:user_id/:repository/pull/:id/files(.:format)
route-controllerpull_requests
route-actionfiles
fetch-noncev2:d2b850e7-8299-67e9-e3a8-df3342a9dea5
current-catalog-service-hashae870bc5e265a340912cde392f23dad3671a0a881730ffdadd82f2f57d81641b
request-idD9BA:73F1E:FC9BCF:16379AA:6B044AE3
html-safe-nonce38255fa2e325df8e8edd40150bf14928a33ce5180c04ac4bc44dc57a1d46255f
visitor-payloadeyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJEOUJBOjczRjFFOkZDOUJDRjoxNjM3OUFBOjZCMDQ0QUUzIiwidmlzaXRvcl9pZCI6IjIxNjM1MDUyMzUwMTkxODg5NjMiLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ==
visitor-hmac06da2fc6b872f6d517dbcc9bb15a956162b7416461ab863284e4d88ae57f0a74
hovercard-subject-tagpull_request:5393785448
github-keyboard-shortcutsrepository,pull-request-list,pull-request-conversation,pull-request-files-changed,copilot
google-site-verificationApib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I
octolytics-urlhttps://collector.github.com/github/collect
analytics-location///pull_requests/show/files
fb:app_id1401488693436528
apple-itunes-appapp-id=1477376905, app-argument=https://github.com/JSQLParser/JSqlParser/pull/2945/files
twitter:imagehttps://avatars.githubusercontent.com/u/294423647?s=400&v=4
twitter:cardsummary_large_image
og:imagehttps://avatars.githubusercontent.com/u/294423647?s=400&v=4
og:image:altFromItemVisitorAdapter never walks the PIVOT / UNPIVOT clause the grammar attaches to a FROM item: visit(Table) returns immediately, and the derived table, LATERAL, table function, parenthesized jo...
og:site_nameGitHub
og:typeobject
hostnamegithub.com
expected-hostnamegithub.com
Noned4495c3631faba668036f176d1f5946901c5172efd73a6edb984029e7d4f8e46
turbo-cache-controlno-preview
diff-viewunified
go-importgithub.com/JSQLParser/JSqlParser git https://github.com/JSQLParser/JSqlParser.git
octolytics-dimension-user_id4643847
octolytics-dimension-user_loginJSQLParser
octolytics-dimension-repository_id1944709
octolytics-dimension-repository_nwoJSQLParser/JSqlParser
octolytics-dimension-repository_publictrue
octolytics-dimension-repository_is_forkfalse
octolytics-dimension-repository_network_root_id1944709
octolytics-dimension-repository_network_root_nwoJSQLParser/JSqlParser
turbo-body-classeslogged-out env-production page-responsive full-width
disable-turbotrue
browser-stats-urlhttps://api.github.com/_private/browser/stats
browser-errors-urlhttps://api.github.com/_private/browser/errors
release9ac4337fb7c6a5846cdfdb1a04f154d3c33ebc77
ui-targetfull
theme-color#1e2327
color-schemelight dark

Links:

Skip to contenthttps://redirect.github.com/JSQLParser/JSqlParser/pull/2945/files#start-of-content
https://redirect.github.com/
Sign inhttps://redirect.github.com/login?return_to=https%3A%2F%2Fgithub.com%2FJSQLParser%2FJSqlParser%2Fpull%2F2945%2Ffiles
GitHubRepository hosting, code review, and collaborationhttps://github.com/platform
CopilotAI coding agent for tasks, projects, and automated workhttps://github.com/features/copilot
ActionsCI/CD and automationhttps://github.com/features/actions
Code QualityQuality analysis, fixes, and enforcementhttps://github.com/features/code-quality
CodespacesCloud development environmentshttps://github.com/features/codespaces
Code SecurityVulnerability detection and remediationhttps://github.com/security/advanced-security/code-security
Secret ProtectionSecret scanning and leak preventionhttps://github.com/security/advanced-security/secret-protection
All Featureshttps://github.com/features
Documentationhttps://docs.github.com/en
Traininghttps://learn.github.com/skills
Certificationshttps://learn.github.com/credentials
Build with Copilothttps://github.com/features/ai
Customize Copilothttps://docs.github.com/en/copilot/how-tos/copilot-on-github/customize-copilot/customize-copilot-overview
Integrationshttps://github.com/marketplace
Trending reposhttps://github.com/trending
GitHub Sponsorshttps://github.com/open-source/sponsors
Developer articleshttps://github.com/resources/articles
ChangelogYour source for the latest features, improvements, and fixes across GitHub products, all in one place.https://github.blog/changelog/
Enterpriseshttps://github.com/enterprise
Teamhttps://github.com/team
Startupshttps://github.com/enterprise/startups
Nonprofitshttps://github.com/solutions/industry/nonprofits
Healthcarehttps://github.com/solutions/industry/healthcare
Financial serviceshttps://github.com/solutions/industry/financial-services
Manufacturinghttps://github.com/solutions/industry/manufacturing
Governmenthttps://github.com/solutions/industry/government
See all industrieshttps://github.com/solutions/industry
Why GitHubhttps://github.com/why-github
Customer Storieshttps://github.com/customer-stories
Business insightshttps://github.com/solutions/executive-insights
Trust Centerhttps://github.com/trust-center
GitHub Advanced SecurityEnterprise-grade code securityhttps://github.com/security/advanced-security
Copilot for businessEnterprise-grade AI featureshttps://github.com/features/copilot/copilot-business
Premium SupportEnterprise-grade 24/7 supporthttps://github.com/enterprise/premium-support
Documentationhttps://docs.github.com/en
Resource centerhttps://github.com/resources
Bloghttps://github.blog/
Events & webinarshttps://github.com/resources/events
Community Forumhttps://github.com/orgs/community/discussions
Customer Storieshttps://github.com/customer-stories
Integrationshttps://github.com/marketplace
Customer supporthttps://help.github.com/
Traininghttps://learn.github.com/skills
GitHub Statushttps://www.githubstatus.com/
Abouthttps://github.com/about
Partnershttps://github.com/partners
Changeloghttps://github.blog/changelog/
GitHub UniverseThe event for developers, by developers — talks, workshops, and what’s next for GitHub.https://githubuniverse.com/
Pricinghttps://github.com/pricing
Sign inhttps://redirect.github.com/login?return_to=https%3A%2F%2Fgithub.com%2FJSQLParser%2FJSqlParser%2Fpull%2F2945%2Ffiles
Sign uphttps://redirect.github.com/signup?ref_cta=Sign+up&ref_loc=header+logged+out&ref_page=%2F%3Cuser-name%3E%2F%3Crepo-name%3E%2Fpull_requests%2Fshow%2Ffiles&source=header-repo&source_repo=JSQLParser%2FJSqlParser
Reloadhttps://redirect.github.com/JSQLParser/JSqlParser/pull/2945/files
Reloadhttps://redirect.github.com/JSQLParser/JSqlParser/pull/2945/files
Reloadhttps://redirect.github.com/JSQLParser/JSqlParser/pull/2945/files
JSQLParserhttps://redirect.github.com/JSQLParser
JSqlParserhttps://redirect.github.com/JSQLParser/JSqlParser
Codehttps://redirect.github.com/JSQLParser/JSqlParser
Issues2 (2)https://redirect.github.com/JSQLParser/JSqlParser/issues
Pull requests2 (2)https://redirect.github.com/JSQLParser/JSqlParser/pulls
Discussionshttps://redirect.github.com/JSQLParser/JSqlParser/discussions
Actionshttps://redirect.github.com/JSQLParser/JSqlParser/actions
Projectshttps://redirect.github.com/JSQLParser/JSqlParser/projects
Wikihttps://redirect.github.com/JSQLParser/JSqlParser/wiki
Security and qualityhttps://redirect.github.com/JSQLParser/JSqlParser/security
Insightshttps://redirect.github.com/JSQLParser/JSqlParser/insights
Sign up for GitHub https://redirect.github.com/signup?return_to=%2FJSQLParser%2FJSqlParser%2Fissues%2Fnew%2Fchoose
terms of servicehttps://docs.github.com/terms
privacy statementhttps://docs.github.com/privacy
Sign inhttps://redirect.github.com/login?return_to=%2FJSQLParser%2FJSqlParser%2Fissues%2Fnew%2Fchoose
manticore-projectshttps://redirect.github.com/manticore-projects
JSQLParser:masterhttps://redirect.github.com/JSQLParser/JSqlParser/tree/master
tanjiroK-coder:pivot-clause-traversalhttps://redirect.github.com/tanjiroK-coder/JSqlParser/tree/pivot-clause-traversal
Conversation 1 https://redirect.github.com/JSQLParser/JSqlParser/pull/2945
Commits 2 https://redirect.github.com/JSQLParser/JSqlParser/pull/2945/commits
Checks 8 https://redirect.github.com/JSQLParser/JSqlParser/pull/2945/checks
Files changed https://redirect.github.com/JSQLParser/JSqlParser/pull/2945/files
Please reload this pagehttps://redirect.github.com/JSQLParser/JSqlParser/pull/2945/files
fix: check functions in PIVOT clauses of FROM items https://redirect.github.com/JSQLParser/JSqlParser/pull/2945/files#top
Show all changes 2 commits https://redirect.github.com/JSQLParser/JSqlParser/pull/2945/files
6b1f363 fix: check functions in PIVOT clauses of FROM items tanjiroK-coder Nov 19, 2026 https://redirect.github.com/JSQLParser/JSqlParser/pull/2945/commits/6b1f36318d2b9c7da47208a066110a5879c248a5
05846f3 Merge branch 'master' into pivot-clause-traversal manticore-projects Nov 21, 2026 https://redirect.github.com/JSQLParser/JSqlParser/pull/2945/commits/05846f3da647fe6292c48f1ac3c68eeebfa2c789
Clear filters https://redirect.github.com/JSQLParser/JSqlParser/pull/2945/files
Please reload this pagehttps://redirect.github.com/JSQLParser/JSqlParser/pull/2945/files
Please reload this pagehttps://redirect.github.com/JSQLParser/JSqlParser/pull/2945/files
FromItemVisitorAdapter.java https://redirect.github.com/JSQLParser/JSqlParser/pull/2945/files#diff-bf282f570c25d1101f146dce847505caae5f541fe3d29f1d11ac2df24a4880f6
SelectValidator.java https://redirect.github.com/JSQLParser/JSqlParser/pull/2945/files#diff-e056eb7f5faea9bb429020501d2812ccca1b21d11d9c3911286fe65264b39777
StatementFeatureVisitorTest.java https://redirect.github.com/JSQLParser/JSqlParser/pull/2945/files#diff-582ea4322cf253e7c8e7eb918c685113c579c025b3b655132490ef2a6d713629
SelectValidatorTest.java https://redirect.github.com/JSQLParser/JSqlParser/pull/2945/files#diff-38b6bc2cc964e078dfb407ca9d47a9c9e6565fcfddb6ea7f4c07137321ac6a8e
src/main/java/net/sf/jsqlparser/statement/select/FromItemVisitorAdapter.javahttps://redirect.github.com/JSQLParser/JSqlParser/pull/2945/files#diff-bf282f570c25d1101f146dce847505caae5f541fe3d29f1d11ac2df24a4880f6
View file https://redirect.github.com/tanjiroK-coder/JSqlParser/blob/05846f3da647fe6292c48f1ac3c68eeebfa2c789/src/main/java/net/sf/jsqlparser/statement/select/FromItemVisitorAdapter.java
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://redirect.github.com/JSQLParser/JSqlParser/pull/2945/{{ revealButtonHref }}
https://redirect.github.com/JSQLParser/JSqlParser/pull/2945/files#diff-bf282f570c25d1101f146dce847505caae5f541fe3d29f1d11ac2df24a4880f6
https://redirect.github.com/JSQLParser/JSqlParser/pull/2945/files#diff-bf282f570c25d1101f146dce847505caae5f541fe3d29f1d11ac2df24a4880f6
https://redirect.github.com/JSQLParser/JSqlParser/pull/2945/files#diff-bf282f570c25d1101f146dce847505caae5f541fe3d29f1d11ac2df24a4880f6
https://redirect.github.com/JSQLParser/JSqlParser/pull/2945/files#diff-bf282f570c25d1101f146dce847505caae5f541fe3d29f1d11ac2df24a4880f6
src/main/java/net/sf/jsqlparser/util/validation/validator/SelectValidator.javahttps://redirect.github.com/JSQLParser/JSqlParser/pull/2945/files#diff-e056eb7f5faea9bb429020501d2812ccca1b21d11d9c3911286fe65264b39777
View file https://redirect.github.com/tanjiroK-coder/JSqlParser/blob/05846f3da647fe6292c48f1ac3c68eeebfa2c789/src/main/java/net/sf/jsqlparser/util/validation/validator/SelectValidator.java
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://redirect.github.com/JSQLParser/JSqlParser/pull/2945/{{ revealButtonHref }}
https://redirect.github.com/JSQLParser/JSqlParser/pull/2945/files#diff-e056eb7f5faea9bb429020501d2812ccca1b21d11d9c3911286fe65264b39777
https://redirect.github.com/JSQLParser/JSqlParser/pull/2945/files#diff-e056eb7f5faea9bb429020501d2812ccca1b21d11d9c3911286fe65264b39777
https://redirect.github.com/JSQLParser/JSqlParser/pull/2945/files#diff-e056eb7f5faea9bb429020501d2812ccca1b21d11d9c3911286fe65264b39777
src/test/java/net/sf/jsqlparser/statement/StatementFeatureVisitorTest.javahttps://redirect.github.com/JSQLParser/JSqlParser/pull/2945/files#diff-582ea4322cf253e7c8e7eb918c685113c579c025b3b655132490ef2a6d713629
View file https://redirect.github.com/tanjiroK-coder/JSqlParser/blob/05846f3da647fe6292c48f1ac3c68eeebfa2c789/src/test/java/net/sf/jsqlparser/statement/StatementFeatureVisitorTest.java
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://redirect.github.com/JSQLParser/JSqlParser/pull/2945/{{ revealButtonHref }}
https://redirect.github.com/JSQLParser/JSqlParser/pull/2945/files#diff-582ea4322cf253e7c8e7eb918c685113c579c025b3b655132490ef2a6d713629
https://redirect.github.com/JSQLParser/JSqlParser/actions/runs/44849693194/job/136677846723?pr=2945
https://redirect.github.com/JSQLParser/JSqlParser/actions/runs/44849693194/job/136677847124?pr=2945
https://redirect.github.com/JSQLParser/JSqlParser/actions/runs/44849693194/job/136677846723?pr=2945
https://redirect.github.com/JSQLParser/JSqlParser/actions/runs/44849693194/job/136677847124?pr=2945
https://redirect.github.com/JSQLParser/JSqlParser/pull/2945/files#diff-582ea4322cf253e7c8e7eb918c685113c579c025b3b655132490ef2a6d713629
https://redirect.github.com/JSQLParser/JSqlParser/pull/2945/files#diff-582ea4322cf253e7c8e7eb918c685113c579c025b3b655132490ef2a6d713629
https://redirect.github.com/JSQLParser/JSqlParser/actions/runs/44849693194/job/136677846723?pr=2945
https://redirect.github.com/JSQLParser/JSqlParser/actions/runs/44849693194/job/136677847124?pr=2945
src/test/java/net/sf/jsqlparser/util/validation/validator/SelectValidatorTest.javahttps://redirect.github.com/JSQLParser/JSqlParser/pull/2945/files#diff-38b6bc2cc964e078dfb407ca9d47a9c9e6565fcfddb6ea7f4c07137321ac6a8e
View file https://redirect.github.com/tanjiroK-coder/JSqlParser/blob/05846f3da647fe6292c48f1ac3c68eeebfa2c789/src/test/java/net/sf/jsqlparser/util/validation/validator/SelectValidatorTest.java
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://redirect.github.com/JSQLParser/JSqlParser/pull/2945/{{ revealButtonHref }}
https://redirect.github.com/JSQLParser/JSqlParser/pull/2945/files#diff-38b6bc2cc964e078dfb407ca9d47a9c9e6565fcfddb6ea7f4c07137321ac6a8e
https://redirect.github.com/JSQLParser/JSqlParser/pull/2945/files#diff-38b6bc2cc964e078dfb407ca9d47a9c9e6565fcfddb6ea7f4c07137321ac6a8e
Please reload this pagehttps://redirect.github.com/JSQLParser/JSqlParser/pull/2945/files
https://github.com
Termshttps://docs.github.com/site-policy/github-terms/github-terms-of-service
Privacyhttps://docs.github.com/site-policy/privacy-policies/github-privacy-statement
Securityhttps://github.com/security
Statushttps://www.githubstatus.com/
Communityhttps://github.community/
Docshttps://docs.github.com/
Contacthttps://support.github.com?tags=dotcom-footer

Response headers:
Servergithub.com
Content-Typetext/html; charset=utf-8
Cache-Controlno-cache

Viewport: width=device-width


URLs of crawlers that visited me.