René's URL Explorer Experiment


Title: Render single spaces in ALTER visibility, FORCE and row level security actions by minleejae · Pull Request #2819 · JSQLParser/JSqlParser · GitHub

Open Graph Title: Render single spaces in ALTER visibility, FORCE and row level security actions by minleejae · Pull Request #2819 · JSQLParser/JSqlParser

X Title: Render single spaces in ALTER visibility, FORCE and row level security actions by minleejae · Pull Request #2819 · JSQLParser/JSqlParser

Description: Purpose Follow-up to #2792. More renderers emit stray spaces. Today: ALTER TABLE t ALTER COLUMN c SET INVISIBLE renders SET INVISIBLE (also SET VISIBLE, and the form without COLUMN). ALTER TABLE t ALTER INDEX i INVISIBLE renders ALTER INDEX i INVISIBLE. ALTER TABLE t FORCE ends with a space, and FORCE, ALGORITHM = INPLACE renders FORCE , ALGORITHM = INPLACE. PostgreSQL ALTER TABLE t {ENABLE | DISABLE | FORCE | NO FORCE} ROW LEVEL SECURITY ends with a space. ALTER TABLE t MODIFY (c INT) renders MODIFY ( c INT ) . ADD CONSTRAINT UNIQUE KEY uk (a) renders uk (a). The Index of CREATE INDEX ON t (a) renders (a) when printed on its own. MySQL DEFAULT (JSON_ARRAY()) renders DEFAULT (JSON_ARRAY( ) ), and JSON_OBJECT() renders JSON_OBJECT( ) . The SQL still reparses, but the extra spaces differ from the input. Current design (As-is) ColumnSetVisibility appends " SET " and then " VISIBLE" or " INVISIBLE". Index puts two spaces before its trailing index spec when it has no columns. It also puts a space before the column list even when nothing precedes it. The general AlterExpression body appends a space after the operation keyword even when no payload follows. The row level security keywords add the same space. A bracketed single column definition is wrapped in " ( " and " ) ". The ADD CONSTRAINT header ends with a space before the column list's own separator. JSON_ARRAY and JSON_OBJECT always open with "( " and close with ") " or " ) ", even with no arguments. Target design (To-be) Separate these words with exactly one space and add no leading or trailing space: ALTER COLUMN c SET INVISIBLE, ALTER INDEX i INVISIBLE, FORCE and ... ROW LEVEL SECURITY; MODIFY (c INT), ADD CONSTRAINT UNIQUE KEY uk (a); an Index with no declaration renders (a). JSON_ARRAY() and JSON_OBJECT() render without inner spaces. No space follows the closing parenthesis. Calls with arguments keep their current inner spacing. The legacy EXCHANGE PARTITION ... WITH VALIDATION rendering of a plain AlterExpression drops its trailing space. Rendered SQL is otherwise unchanged. The SQL renderer and StatementDeParser produce the same text. The grammar is unchanged. Validation DeparseWhitespaceTest (added in #2792) now also: compares toString() and StatementDeParser output exactly for the forms above in MySQL, PostgreSQL and default mode; checks that JSON_ARRAY/JSON_OBJECT with arguments or ON NULL clauses render no double space; checks ColumnSetVisibility, a constructed Index and a constructed EXCHANGE PARTITION action directly. No existing assertion encoded these spaces, so no existing test changed. Java 17 offline Gradle spotlessApply check: 10,382 tests, 10,357 passed, 25 skipped, zero failures/errors. Compared with master (bdf8ac31) on a corpus of 635 MySQL 8.4 and PostgreSQL 18 DDL/DCL statements, each accepted by the server, with and without a dialect: no regressions. Only 6 MySQL and 3 PostgreSQL statements of the forms above change their toString(), in both dialect and default mode. In CREATE INDEX ON ..., the contained index renders (name) instead of (name). MySQL 8.4 and PostgreSQL 18.3: every corpus statement this branch parses ran as written on one server and as rendered by toString() on a second, identical server, in the same order. All 205 MySQL and 328 PostgreSQL statements give the same result (success, or the same error). Integration validation Applied #2806–#2819 together on master (bdf8ac31), with the stacked PRs on top of their bases (#2806 → #2807 → #2808, #2806 → #2809 → #2810 and #2811 → #2812). Each branch merges cleanly into master. Between the branches, conflicts are limited to adjacent additions (README/index rows, usage sections, imports, visitor and feature lists, one enum line and one alias guard). The integrated build passes Java 17 offline Gradle spotlessApply check: 11,494 tests, 11,469 passed, 25 skipped, zero failures/errors. The grammar choice conflict check passes. On a corpus of 635 MySQL 8.4 and PostgreSQL 18 DDL/DCL statements, each accepted by the server, the integrated build parses 265 of 271 MySQL statements (master: 206) and 363 of 364 PostgreSQL statements (master: 328). Every MySQL 8.4 non-reserved word and PostgreSQL 18 unreserved or column-name keyword parses as a column and table name. On paired MySQL 8.4 and PostgreSQL 18.3 servers, all 263 MySQL and 362 PostgreSQL statements rendered by the integrated build give the same results as the originals.

Open Graph Description: Purpose Follow-up to #2792. More renderers emit stray spaces. Today: ALTER TABLE t ALTER COLUMN c SET INVISIBLE renders SET INVISIBLE (also SET VISIBLE, and the form without COLUMN). ALTER TABLE...

X Description: Purpose Follow-up to #2792. More renderers emit stray spaces. Today: ALTER TABLE t ALTER COLUMN c SET INVISIBLE renders SET INVISIBLE (also SET VISIBLE, and the form without COLUMN). ALTER TABLE...

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

X: @github

direct link

Domain: github.com

IPv4 address: 140.82.114.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:582d3be0-6fce-789f-4825-88933250ef09
current-catalog-service-hashae870bc5e265a340912cde392f23dad3671a0a881730ffdadd82f2f57d81641b
request-idCBCE:2366B8:19FE32:22F1AD:6B049778
html-safe-nonce8aa0f5aebe348ddacbf1e08ccb56a5247f5b01f7dfd912719e94ec087f8c395e
visitor-payloadeyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJDQkNFOjIzNjZCODoxOUZFMzI6MjJGMUFEOjZCMDQ5Nzc4IiwidmlzaXRvcl9pZCI6IjQ2NzE2ODUwMjU0MjU4MjM2MDgiLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ==
visitor-hmaca6e1d42deb117130b09ed0313179b7c348d65254030889b310a0278f8a56a851
hovercard-subject-tagpull_request:4854553439
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/2819/files
twitter:imagehttps://avatars.githubusercontent.com/u/55116920?s=400&v=4
twitter:cardsummary_large_image
og:imagehttps://avatars.githubusercontent.com/u/55116920?s=400&v=4
og:image:altPurpose Follow-up to #2792. More renderers emit stray spaces. Today: ALTER TABLE t ALTER COLUMN c SET INVISIBLE renders SET INVISIBLE (also SET VISIBLE, and the form without COLUMN). ALTER TABLE...
og:site_nameGitHub
og:typeobject
hostnamegithub.com
expected-hostnamegithub.com
None9784b6f42e2d5eac4e394fa88cad134c0dc5b6662b4ff2787a1ed1ef5a96331d
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
release3fd14143b75b2af7b76bbd23b069867d091adfcc
ui-targetfull
theme-color#1e2327
color-schemelight dark

Links:

Skip to contenthttps://github.com/JSQLParser/JSqlParser/pull/2819/files#start-of-content
https://github.com/
Sign inhttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2FJSQLParser%2FJSqlParser%2Fpull%2F2819%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://github.com/login?return_to=https%3A%2F%2Fgithub.com%2FJSQLParser%2FJSqlParser%2Fpull%2F2819%2Ffiles
Sign uphttps://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://github.com/JSQLParser/JSqlParser/pull/2819/files
Reloadhttps://github.com/JSQLParser/JSqlParser/pull/2819/files
Reloadhttps://github.com/JSQLParser/JSqlParser/pull/2819/files
JSQLParserhttps://github.com/JSQLParser
JSqlParserhttps://github.com/JSQLParser/JSqlParser
Codehttps://github.com/JSQLParser/JSqlParser
Issues2 (2)https://github.com/JSQLParser/JSqlParser/issues
Pull requests2 (2)https://github.com/JSQLParser/JSqlParser/pulls
Discussionshttps://github.com/JSQLParser/JSqlParser/discussions
Actionshttps://github.com/JSQLParser/JSqlParser/actions
Projectshttps://github.com/JSQLParser/JSqlParser/projects
Wikihttps://github.com/JSQLParser/JSqlParser/wiki
Security and qualityhttps://github.com/JSQLParser/JSqlParser/security
Insightshttps://github.com/JSQLParser/JSqlParser/insights
Sign up for GitHub https://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://github.com/login?return_to=%2FJSQLParser%2FJSqlParser%2Fissues%2Fnew%2Fchoose
manticore-projectshttps://github.com/manticore-projects
JSQLParser:masterhttps://github.com/JSQLParser/JSqlParser/tree/master
minleejae:fix/alter-render-spacing-20261014https://github.com/minleejae/JSqlParser/tree/fix/alter-render-spacing-20261014
Conversation 0 https://github.com/JSQLParser/JSqlParser/pull/2819
Commits 1 https://github.com/JSQLParser/JSqlParser/pull/2819/commits
Checks 10 https://github.com/JSQLParser/JSqlParser/pull/2819/checks
Files changed https://github.com/JSQLParser/JSqlParser/pull/2819/files
Please reload this pagehttps://github.com/JSQLParser/JSqlParser/pull/2819/files
Render single spaces in ALTER visibility, FORCE and row level security actions https://github.com/JSQLParser/JSqlParser/pull/2819/files#top
Show all changes 1 commit https://github.com/JSQLParser/JSqlParser/pull/2819/files
b79f20d fix: render single spaces in ALTER visibility, FORCE and row level se… minleejae Oct 14, 2026 https://github.com/JSQLParser/JSqlParser/pull/2819/commits/b79f20dea117eedabf3b8913fcdaf1ca72fa9701
Clear filters https://github.com/JSQLParser/JSqlParser/pull/2819/files
Please reload this pagehttps://github.com/JSQLParser/JSqlParser/pull/2819/files
Please reload this pagehttps://github.com/JSQLParser/JSqlParser/pull/2819/files
JsonFunction.java https://github.com/JSQLParser/JSqlParser/pull/2819/files#diff-1faa1370ff03c1f81aaacd7c0a1442f662a53c6f9d539f2338d3f66a4f4ce52d
AlterExpression.java https://github.com/JSQLParser/JSqlParser/pull/2819/files#diff-fc44472f677ed768eaa549485c7ef8096a5efb18be17c46e44c1ed5c6348ef4b
Index.java https://github.com/JSQLParser/JSqlParser/pull/2819/files#diff-299909b425e3448e5aecaa71be2ac9bfb9dbf79e182bcdc1aaa3940881c15797
DeparseWhitespaceTest.java https://github.com/JSQLParser/JSqlParser/pull/2819/files#diff-b5a0cad32dd1d3a6ae5d01b691a23d75230e2ad67728027e10befbe1cd322929
src/main/java/net/sf/jsqlparser/expression/JsonFunction.javahttps://github.com/JSQLParser/JSqlParser/pull/2819/files#diff-1faa1370ff03c1f81aaacd7c0a1442f662a53c6f9d539f2338d3f66a4f4ce52d
View file https://github.com/minleejae/JSqlParser/blob/b79f20dea117eedabf3b8913fcdaf1ca72fa9701/src/main/java/net/sf/jsqlparser/expression/JsonFunction.java
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/JSQLParser/JSqlParser/pull/2819/{{ revealButtonHref }}
https://github.com/JSQLParser/JSqlParser/pull/2819/files#diff-1faa1370ff03c1f81aaacd7c0a1442f662a53c6f9d539f2338d3f66a4f4ce52d
https://github.com/JSQLParser/JSqlParser/pull/2819/files#diff-1faa1370ff03c1f81aaacd7c0a1442f662a53c6f9d539f2338d3f66a4f4ce52d
https://github.com/JSQLParser/JSqlParser/pull/2819/files#diff-1faa1370ff03c1f81aaacd7c0a1442f662a53c6f9d539f2338d3f66a4f4ce52d
https://github.com/JSQLParser/JSqlParser/pull/2819/files#diff-1faa1370ff03c1f81aaacd7c0a1442f662a53c6f9d539f2338d3f66a4f4ce52d
https://github.com/JSQLParser/JSqlParser/pull/2819/files#diff-1faa1370ff03c1f81aaacd7c0a1442f662a53c6f9d539f2338d3f66a4f4ce52d
src/main/java/net/sf/jsqlparser/statement/alter/AlterExpression.javahttps://github.com/JSQLParser/JSqlParser/pull/2819/files#diff-fc44472f677ed768eaa549485c7ef8096a5efb18be17c46e44c1ed5c6348ef4b
View file https://github.com/minleejae/JSqlParser/blob/b79f20dea117eedabf3b8913fcdaf1ca72fa9701/src/main/java/net/sf/jsqlparser/statement/alter/AlterExpression.java
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/JSQLParser/JSqlParser/pull/2819/{{ revealButtonHref }}
https://github.com/JSQLParser/JSqlParser/pull/2819/files#diff-fc44472f677ed768eaa549485c7ef8096a5efb18be17c46e44c1ed5c6348ef4b
https://github.com/JSQLParser/JSqlParser/pull/2819/files#diff-fc44472f677ed768eaa549485c7ef8096a5efb18be17c46e44c1ed5c6348ef4b
https://github.com/JSQLParser/JSqlParser/pull/2819/files#diff-fc44472f677ed768eaa549485c7ef8096a5efb18be17c46e44c1ed5c6348ef4b
https://github.com/JSQLParser/JSqlParser/pull/2819/files#diff-fc44472f677ed768eaa549485c7ef8096a5efb18be17c46e44c1ed5c6348ef4b
https://github.com/JSQLParser/JSqlParser/pull/2819/files#diff-fc44472f677ed768eaa549485c7ef8096a5efb18be17c46e44c1ed5c6348ef4b
https://github.com/JSQLParser/JSqlParser/pull/2819/files#diff-fc44472f677ed768eaa549485c7ef8096a5efb18be17c46e44c1ed5c6348ef4b
https://github.com/JSQLParser/JSqlParser/pull/2819/files#diff-fc44472f677ed768eaa549485c7ef8096a5efb18be17c46e44c1ed5c6348ef4b
https://github.com/JSQLParser/JSqlParser/pull/2819/files#diff-fc44472f677ed768eaa549485c7ef8096a5efb18be17c46e44c1ed5c6348ef4b
https://github.com/JSQLParser/JSqlParser/pull/2819/files#diff-fc44472f677ed768eaa549485c7ef8096a5efb18be17c46e44c1ed5c6348ef4b
https://github.com/JSQLParser/JSqlParser/pull/2819/files#diff-fc44472f677ed768eaa549485c7ef8096a5efb18be17c46e44c1ed5c6348ef4b
https://github.com/JSQLParser/JSqlParser/pull/2819/files#diff-fc44472f677ed768eaa549485c7ef8096a5efb18be17c46e44c1ed5c6348ef4b
https://github.com/JSQLParser/JSqlParser/pull/2819/files#diff-fc44472f677ed768eaa549485c7ef8096a5efb18be17c46e44c1ed5c6348ef4b
src/main/java/net/sf/jsqlparser/statement/create/table/Index.javahttps://github.com/JSQLParser/JSqlParser/pull/2819/files#diff-299909b425e3448e5aecaa71be2ac9bfb9dbf79e182bcdc1aaa3940881c15797
View file https://github.com/minleejae/JSqlParser/blob/b79f20dea117eedabf3b8913fcdaf1ca72fa9701/src/main/java/net/sf/jsqlparser/statement/create/table/Index.java
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/JSQLParser/JSqlParser/pull/2819/{{ revealButtonHref }}
https://github.com/JSQLParser/JSqlParser/pull/2819/files#diff-299909b425e3448e5aecaa71be2ac9bfb9dbf79e182bcdc1aaa3940881c15797
https://github.com/JSQLParser/JSqlParser/pull/2819/files#diff-299909b425e3448e5aecaa71be2ac9bfb9dbf79e182bcdc1aaa3940881c15797
src/test/java/net/sf/jsqlparser/statement/alter/DeparseWhitespaceTest.javahttps://github.com/JSQLParser/JSqlParser/pull/2819/files#diff-b5a0cad32dd1d3a6ae5d01b691a23d75230e2ad67728027e10befbe1cd322929
View file https://github.com/minleejae/JSqlParser/blob/b79f20dea117eedabf3b8913fcdaf1ca72fa9701/src/test/java/net/sf/jsqlparser/statement/alter/DeparseWhitespaceTest.java
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/JSQLParser/JSqlParser/pull/2819/{{ revealButtonHref }}
https://github.com/JSQLParser/JSqlParser/pull/2819/files#diff-b5a0cad32dd1d3a6ae5d01b691a23d75230e2ad67728027e10befbe1cd322929
https://github.com/JSQLParser/JSqlParser/pull/2819/files#diff-b5a0cad32dd1d3a6ae5d01b691a23d75230e2ad67728027e10befbe1cd322929
https://github.com/JSQLParser/JSqlParser/pull/2819/files#diff-b5a0cad32dd1d3a6ae5d01b691a23d75230e2ad67728027e10befbe1cd322929
Please reload this pagehttps://github.com/JSQLParser/JSqlParser/pull/2819/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.