GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — Double dash comment not working · Issue #604 · ArcadeData/arcadedb

Double dash comment not working #604

New issue
Copy link
New issue
Copy link
Closed
Closed
Double dash comment not working#604
Copy link
Assignees
gramian
Milestone
22.12.1

Description

@gramian
gramian
opened on Nov 6, 2022
Issue body actions

ArcadeDB Version: v22.10.1 (build e692f4c/1667424782661/main)

JDK Version: openjdk 11.0.16.1 2022-08-12

OS: MacOS 12.6

Expected behavior

literally nothing

Actual behavior

Error on command execution (PostCommandHandler)

Trace (sqlscript)
com.arcadedb.exception.CommandSQLParsingException: com.arcadedb.query.sql.parser.ParseException: Encountered " "--" "-- "" at line 1, column 14.
Was expecting one of:
    <EOF> 
    <ALIGN> ...
    <SELECT> ...
    <TRAVERSE> ...
    <MATCH> ...
    <INSERT> ...
    <CREATE> ...
    <DELETE> ...
    <UPDATE> ...
    <WHILE> ...
    <RETURN> ...
    <LET> ...
    <CHECK> ...
    <PROFILE> ...
    <TRUNCATE> ...
    <BACKUP> ...
    <ALTER> ...
    <DROP> ...
    <REBUILD> ...
    <EXPORT> ...
    <IMPORT> ...
    <EXPLAIN> ...
    <BEGIN> ...
    <COMMIT> ...
    <ROLLBACK> ...
    <IF> ...
    <SLEEP> ...
    <FOREACH> ...
    ";" ...
    
	at com.arcadedb.query.sql.executor.SQLEngine.parseScript(SQLEngine.java:110)
	at com.arcadedb.query.sql.executor.SQLEngine.parseScript(SQLEngine.java:102)
	at com.arcadedb.database.EmbeddedDatabase.execute(EmbeddedDatabase.java:1243)
	at com.arcadedb.server.ServerDatabase.execute(ServerDatabase.java:415)
	at com.arcadedb.server.http.handler.PostCommandHandler.executeScript(PostCommandHandler.java:100)
	at com.arcadedb.server.http.handler.PostCommandHandler.execute(PostCommandHandler.java:71)
	at com.arcadedb.server.http.handler.DatabaseAbstractHandler.execute(DatabaseAbstractHandler.java:85)
	at com.arcadedb.server.http.handler.AbstractHandler.handleRequest(AbstractHandler.java:111)
	at io.undertow.server.RoutingHandler.handleRequest(RoutingHandler.java:93)
	at io.undertow.server.handlers.PathHandler.handleRequest(PathHandler.java:104)
	at io.undertow.server.Connectors.executeRootHandler(Connectors.java:391)
	at io.undertow.server.protocol.http.HttpReadListener.handleEventWithNoRunningRequest(HttpReadListener.java:256)
	at io.undertow.server.protocol.http.HttpReadListener.handleEvent(HttpReadListener.java:136)
	at io.undertow.server.protocol.http.HttpOpenListener.handleEvent(HttpOpenListener.java:162)
	at io.undertow.server.protocol.http.HttpOpenListener.handleEvent(HttpOpenListener.java:100)
	at io.undertow.server.protocol.http.HttpOpenListener.handleEvent(HttpOpenListener.java:57)
	at org.xnio.ChannelListeners.invokeChannelListener(ChannelListeners.java:92)
	at org.xnio.ChannelListeners$10.handleEvent(ChannelListeners.java:291)
	at org.xnio.ChannelListeners$10.handleEvent(ChannelListeners.java:286)
	at org.xnio.ChannelListeners.invokeChannelListener(ChannelListeners.java:92)
	at org.xnio.nio.QueuedNioTcpServer2.acceptTask(QueuedNioTcpServer2.java:178)
	at org.xnio.nio.WorkerThread.safeRun(WorkerThread.java:612)
	at org.xnio.nio.WorkerThread.run(WorkerThread.java:479)
Caused by: com.arcadedb.query.sql.parser.ParseException: Encountered " "--" "-- "" at line 1, column 14.
Was expecting one of:
    <EOF> 
    <ALIGN> ...
    <SELECT> ...
    <TRAVERSE> ...
    <MATCH> ...
    <INSERT> ...
    <CREATE> ...
    <DELETE> ...
    <UPDATE> ...
    <WHILE> ...
    <RETURN> ...
    <LET> ...
    <CHECK> ...
    <PROFILE> ...
    <TRUNCATE> ...
    <BACKUP> ...
    <ALTER> ...
    <DROP> ...
    <REBUILD> ...
    <EXPORT> ...
    <IMPORT> ...
    <EXPLAIN> ...
    <BEGIN> ...
    <COMMIT> ...
    <ROLLBACK> ...
    <IF> ...
    <SLEEP> ...
    <FOREACH> ...
    ";" ...
    
	at com.arcadedb.query.sql.parser.SqlParser.generateParseException(SqlParser.java:26749)
	at com.arcadedb.query.sql.parser.SqlParser.jj_consume_token(SqlParser.java:26585)
	at com.arcadedb.query.sql.parser.SqlParser.ParseScript(SqlParser.java:342)
	at com.arcadedb.query.sql.executor.SQLEngine.parseScript(SQLEngine.java:108)
	... 22 more
Trace (sql)
com.arcadedb.exception.CommandSQLParsingException: SELECT true; -- A comment
	at com.arcadedb.query.sql.parser.StatementCache.throwParsingException(StatementCache.java:123)
	at com.arcadedb.query.sql.parser.StatementCache.parse(StatementCache.java:115)
	at com.arcadedb.query.sql.parser.StatementCache.get(StatementCache.java:70)
	at com.arcadedb.query.sql.executor.SQLEngine.parse(SQLEngine.java:97)
	at com.arcadedb.query.sql.SQLQueryEngine.command(SQLQueryEngine.java:75)
	at com.arcadedb.database.EmbeddedDatabase.command(EmbeddedDatabase.java:1232)
	at com.arcadedb.server.ServerDatabase.command(ServerDatabase.java:410)
	at com.arcadedb.server.http.handler.PostCommandHandler.executeCommand(PostCommandHandler.java:109)
	at com.arcadedb.server.http.handler.PostCommandHandler.execute(PostCommandHandler.java:72)
	at com.arcadedb.server.http.handler.DatabaseAbstractHandler.execute(DatabaseAbstractHandler.java:85)
	at com.arcadedb.server.http.handler.AbstractHandler.handleRequest(AbstractHandler.java:111)
	at io.undertow.server.RoutingHandler.handleRequest(RoutingHandler.java:93)
	at io.undertow.server.handlers.PathHandler.handleRequest(PathHandler.java:104)
	at io.undertow.server.Connectors.executeRootHandler(Connectors.java:391)
	at io.undertow.server.protocol.http.HttpReadListener.handleEventWithNoRunningRequest(HttpReadListener.java:256)
	at io.undertow.server.protocol.http.HttpReadListener.handleEvent(HttpReadListener.java:136)
	at io.undertow.server.protocol.http.HttpOpenListener.handleEvent(HttpOpenListener.java:162)
	at io.undertow.server.protocol.http.HttpOpenListener.handleEvent(HttpOpenListener.java:100)
	at io.undertow.server.protocol.http.HttpOpenListener.handleEvent(HttpOpenListener.java:57)
	at org.xnio.ChannelListeners.invokeChannelListener(ChannelListeners.java:92)
	at org.xnio.ChannelListeners$10.handleEvent(ChannelListeners.java:291)
	at org.xnio.ChannelListeners$10.handleEvent(ChannelListeners.java:286)
	at org.xnio.ChannelListeners.invokeChannelListener(ChannelListeners.java:92)
	at org.xnio.nio.QueuedNioTcpServer2.acceptTask(QueuedNioTcpServer2.java:178)
	at org.xnio.nio.WorkerThread.safeRun(WorkerThread.java:612)
	at org.xnio.nio.WorkerThread.run(WorkerThread.java:479)
Caused by: com.arcadedb.query.sql.parser.ParseException: Encountered " "--" "-- "" at line 1, column 14.
Was expecting:
    <EOF> 
    
	at com.arcadedb.query.sql.parser.SqlParser.generateParseException(SqlParser.java:26749)
	at com.arcadedb.query.sql.parser.SqlParser.jj_consume_token(SqlParser.java:26585)
	at com.arcadedb.query.sql.parser.SqlParser.parse(SqlParser.java:239)
	at com.arcadedb.query.sql.parser.StatementCache.parse(StatementCache.java:110)
	... 24 more

Steps to reproduce

SELECT true; -- A comment

Activity

  1. gramian
    changed the title [-]Double dash comment no working[/-] [+]Double dash comment not working[/+] on Nov 7, 2022
  2. gramian commented on Nov 10, 2022

    @gramian
    gramian
    on Nov 10, 2022
    CollaboratorAuthor
    More actions

    Could this be related to SQLGrammar.jjt#L68, since

    SELECT true; /** -- hi
    

    works as line comment!?

  3. gramian
    closed this as completedon Dec 15, 2022
  4. lvca
    assigned
    gramian
    on Dec 15, 2022
  5. lvca
    added
    enhancementNew feature or request
    on Dec 15, 2022
  6. lvca
    added this to the 22.12.1 milestone on Dec 15, 2022
  7. lvca
    added a commit that references this issue on Dec 15, 2022

    Added test cases for recent PR about double dashed comments

    bad2029
  8. lvca
    added
    bug
    bug fixed
    and removed
    enhancementNew feature or request
    on Dec 15, 2022
  9. mergify
    added a commit that references this issue on Feb 22, 2026

    chore(studio-deps)(deps): bump pdfmake from 0.3.4 to 0.3.5 in /studio…

    1a1c434
  10. mergify
    added a commit that references this issue on May 3, 2026

    chore(deps): bump actions/setup-dotnet from 4.3.1 to 5.2.0 [skip ci]

    f0474ec
  11. mergify
    added a commit that references this issue on Jun 7, 2026

    chore(studio-deps-dev)(deps-dev): bump enhanced-resolve from 5.22.1 t…

    72ea39b
  12. tae898
    added 4 commits that reference this issue on Jun 28, 2026

    Added test cases for recent PR about double dashed comments

    6769de0

    chore(studio-deps)(deps): bump pdfmake from 0.3.4 to 0.3.5 in /studio…

    0f397ed

    chore(deps): bump actions/setup-dotnet from 4.3.1 to 5.2.0 [skip ci]

    0e3c6a8

    chore(studio-deps-dev)(deps-dev): bump enhanced-resolve from 5.22.1 t…

    092ce5a
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

  • @gramian
    gramian

Labels

No labels
No labels

Type

No type

Projects

No projects

    Milestone

    • 22.12.1

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

    You are visitor 01402775 — GeezerVison does not store the pages you look up.
    Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.