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 — HTTP/SQL: "params" cannot be bucket names · Issue #1625 · ArcadeData/arcadedb

HTTP/SQL: "params" cannot be bucket names #1625

New issue
Copy link
New issue
Copy link
Closed
Feature
Closed
HTTP/SQL: "params" cannot be bucket names#1625
Feature
Copy link
Assignees
lvca
Milestone
26.2.1

Description

@gramian
gramian
opened on Jun 5, 2024
Issue body actions

ArcadeDB Version:

ArcadeDB Server v24.6.1-SNAPSHOT (build 6ff2d86d488fe6b3ca20f7a6554160d6017af118/1716919859476/main)

OS and JDK Version:

Running on Mac OS X 12.7.5 - OpenJDK 64-Bit Server VM 17.0.11 (Homebrew)

Using a parameter in POST request query where the parameter specifies a bucket name errors. This is maybe because the double colon, ie BUCKET::param cannot be parsed?

Expected behavior

Succesful query in bucket

Actual behavior

Error on command execution
<ArcadeDB_0> Error on command execution (PostQueryHandler)
com.arcadedb.exception.CommandSQLParsingException: SELECT FROM BUCKET::myparam limit 20000
	at com.arcadedb.query.sql.parser.StatementCache.throwParsingException(StatementCache.java:126)
	at com.arcadedb.query.sql.parser.StatementCache.parse(StatementCache.java:116)
	at com.arcadedb.query.sql.parser.StatementCache.get(StatementCache.java:70)
	at com.arcadedb.query.sql.SQLQueryEngine.parse(SQLQueryEngine.java:216)
	at com.arcadedb.query.sql.SQLQueryEngine.query(SQLQueryEngine.java:80)
	at com.arcadedb.database.LocalDatabase.query(LocalDatabase.java:1378)
	at com.arcadedb.server.ServerDatabase.query(ServerDatabase.java:494)
	at com.arcadedb.server.http.handler.PostQueryHandler.executeCommand(PostQueryHandler.java:38)
	at com.arcadedb.server.http.handler.PostCommandHandler.execute(PostCommandHandler.java:113)
	at com.arcadedb.server.http.handler.DatabaseAbstractHandler.execute(DatabaseAbstractHandler.java:100)
	at com.arcadedb.server.http.handler.AbstractServerHttpHandler.handleRequest(AbstractServerHttpHandler.java:127)
	at io.undertow.server.Connectors.executeRootHandler(Connectors.java:393)
	at io.undertow.server.HttpServerExchange$1.run(HttpServerExchange.java:859)
	at org.jboss.threads.ContextHandler$1.runWith(ContextHandler.java:18)
	at org.jboss.threads.EnhancedQueueExecutor$Task.run(EnhancedQueueExecutor.java:2513)
	at org.jboss.threads.EnhancedQueueExecutor$ThreadBody.run(EnhancedQueueExecutor.java:1538)
	at org.xnio.XnioWorker$WorkerThreadFactory$1$1.run(XnioWorker.java:1282)
	at java.base/java.lang.Thread.run(Thread.java:840)
Caused by: com.arcadedb.query.sql.parser.ParseException: Encountered <FROM> "FROM" at line 1, column 8.
Was expecting one of:
    <DISTINCT> ...
    <DISTINCT> ...
    <DISTINCT> ...
    <DISTINCT> ...
    <DISTINCT> ...
    <DISTINCT> ...
    <DISTINCT> ...
    <DISTINCT> ...
    <DISTINCT> ...
    
	at com.arcadedb.query.sql.parser.SqlParser.generateParseException(SqlParser.java:27774)
	at com.arcadedb.query.sql.parser.SqlParser.jj_consume_token(SqlParser.java:27619)
	at com.arcadedb.query.sql.parser.SqlParser.Projection(SqlParser.java:4892)
	at com.arcadedb.query.sql.parser.SqlParser.SelectWithoutTargetStatement(SqlParser.java:1548)
	at com.arcadedb.query.sql.parser.SqlParser.QueryStatement(SqlParser.java:1497)
	at com.arcadedb.query.sql.parser.SqlParser.StatementInternal(SqlParser.java:1287)
	at com.arcadedb.query.sql.parser.SqlParser.Statement(SqlParser.java:1055)
	at com.arcadedb.query.sql.parser.SqlParser.Parse(SqlParser.java:251)
	at com.arcadedb.query.sql.parser.StatementCache.parse(StatementCache.java:111)
	... 16 more

Steps to reproduce

CREATE DOCUMENT TYPE doc BUCKET mybucket
wget -qO- http://localhost:2480/api/v1/query/test --post-data='{"language":"sql","params":{"myparam":"mybucket"},"command":"SELECT FROM BUCKET::myparam"}' --user root --password arcadedb

Activity

  1. lvca commented on Jun 5, 2024

    @lvca
    lvca
    on Jun 5, 2024
    Member
    More actions

    It should be BUCKET:myparam

  2. lvca
    self-assigned this
    on Jun 5, 2024
  3. gramian commented on Jun 5, 2024

    @gramian
    gramian
    on Jun 5, 2024
    CollaboratorAuthor
    More actions
    Using `BUCKET:myparam` also errors
    <ArcadeDB_0> Error on command execution (PostQueryHandler)
    com.arcadedb.exception.SchemaException: Bucket with name 'myparam' was not found
    	at com.arcadedb.schema.LocalSchema.getBucketByName(LocalSchema.java:281)
    	at com.arcadedb.query.sql.executor.SelectExecutionPlanner.handleClustersAsTarget(SelectExecutionPlanner.java:2196)
    	at com.arcadedb.query.sql.executor.SelectExecutionPlanner.handleFetchFromTarget(SelectExecutionPlanner.java:780)
    	at com.arcadedb.query.sql.executor.SelectExecutionPlanner.createExecutionPlan(SelectExecutionPlanner.java:144)
    	at com.arcadedb.query.sql.parser.SelectStatement.createExecutionPlan(SelectStatement.java:208)
    	at com.arcadedb.query.sql.parser.SelectStatement.execute(SelectStatement.java:201)
    	at com.arcadedb.query.sql.parser.Statement.execute(Statement.java:85)
    	at com.arcadedb.query.sql.parser.Statement.execute(Statement.java:69)
    	at com.arcadedb.query.sql.SQLQueryEngine.query(SQLQueryEngine.java:85)
    	at com.arcadedb.database.LocalDatabase.query(LocalDatabase.java:1378)
    	at com.arcadedb.server.ServerDatabase.query(ServerDatabase.java:494)
    	at com.arcadedb.server.http.handler.PostQueryHandler.executeCommand(PostQueryHandler.java:38)
    	at com.arcadedb.server.http.handler.PostCommandHandler.execute(PostCommandHandler.java:113)
    	at com.arcadedb.server.http.handler.DatabaseAbstractHandler.execute(DatabaseAbstractHandler.java:100)
    	at com.arcadedb.server.http.handler.AbstractServerHttpHandler.handleRequest(AbstractServerHttpHandler.java:127)
    	at io.undertow.server.Connectors.executeRootHandler(Connectors.java:393)
    	at io.undertow.server.HttpServerExchange$1.run(HttpServerExchange.java:859)
    	at org.jboss.threads.ContextHandler$1.runWith(ContextHandler.java:18)
    	at org.jboss.threads.EnhancedQueueExecutor$Task.run(EnhancedQueueExecutor.java:2513)
    	at org.jboss.threads.EnhancedQueueExecutor$ThreadBody.run(EnhancedQueueExecutor.java:1538)
    	at org.xnio.XnioWorker$WorkerThreadFactory$1$1.run(XnioWorker.java:1282)
    	at java.base/java.lang.Thread.run(Thread.java:840)
    

    since then the parameter is not identified as such.

  4. lvca commented on Jun 5, 2024

    @lvca
    lvca
    on Jun 5, 2024
    Member
    More actions

    Sorry, I didn't notice the parameter. Correct, you can't use parameters there.

  5. gramian commented on Jun 5, 2024

    @gramian
    gramian
    on Jun 5, 2024
    CollaboratorAuthor
    More actions

    Too bad. So, does this bug report become a feature request or is this too unlikely to be implemented and should hence be closed?

  6. gramian commented on Jun 5, 2024

    @gramian
    gramian
    on Jun 5, 2024
    CollaboratorAuthor
    More actions

    Hmm, so I tried using

    wget -qO- http://localhost:2480/api/v1/query/test --post-data='{"language":"sql","params":{"myparam":"BUCKET:mybucket"},"command":"SELECT FROM :myparam"}' --user root --password arcadedb
    

    which errors, but

    wget -qO- http://localhost:2480/api/v1/query/test --post-data='{"language":"sql","params":{"myparam":"doc"},"command":"SELECT FROM :myparam"}' --user root --password arcadedb
    

    works. So can you describe what the syntactic rule is, so I can add it to the docs?

  7. lvca commented on Jun 5, 2024

    @lvca
    lvca
    on Jun 5, 2024
    Member
    More actions

    If it works without the BUCKET: prefix, then it should be easy to implement it. I'm ok with this as an enhancement.

    Reacted by Christian Himpe
  8. lvca
    added this to the 26.2.1 milestone on Jan 22, 2026
  9. lvca
    added the
    Feature
    issue type on Jan 22, 2026
  10. lvca
    added
    in progressThe team is actively working on this issue
    on Jan 22, 2026
  11. lvca
    added a commit that references this issue on Jan 22, 2026

    feat: SQL -> support for bucket name as parameter

    5521e3c
  12. lvca commented on Jan 22, 2026

    @lvca
    lvca
    on Jan 22, 2026
    Member
    More actions

    Now you can use:

    1. Named parameters: bucket::paramName (e.g., SELECT FROM bucket::bucketName)
    2. Positional parameters: bucket:? (e.g., SELECT FROM bucket:?)
  13. lvca
    closed this as completedon Jan 22, 2026
  14. lvca
    added
    fixed / implemented
    and removed
    in progressThe team is actively working on this issue
    on Jan 22, 2026
  15. lvca
    added a commit that references this issue on Jan 23, 2026

    New SQL parser using ANTLR4 replacing of JavaCC (#3195)

    7a8f45d
  16. gramian commented on Jan 24, 2026

    @gramian
    gramian
    on Jan 24, 2026
    CollaboratorAuthor
    More actions

    Works for me. Cool, thanks!

    Reacted by Luca Garulli
  17. robfrank
    added a commit that references this issue on Feb 17, 2026

    New SQL parser using ANTLR4 replacing of JavaCC (#3195)

    c569b10
  18. tae898
    added a commit that references this issue on Jun 28, 2026

    New SQL parser using ANTLR4 replacing of JavaCC (ArcadeData#3195)

    8777961
  19. mergify
    added a commit that references this issue on Aug 23, 2026

    build(deps): bump the github-actions group with 2 updates [skip ci]

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

Metadata

Metadata

Assignees

  • @lvca
    lvca

Labels

No labels
No labels

Type

Feature

Projects

No projects

    Milestone

    • 26.2.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.