Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

update statements: the semantic stage does not resolve the relation in the from clause #6248

Closed
monetdb-team opened this issue Nov 30, 2020 · 0 comments

Comments

@monetdb-team
Copy link

@monetdb-team monetdb-team commented Nov 30, 2020

Date: 2017-03-21 09:41:14 +0100
From: Dean De Leo <>
To: SQL devs <>
Version: -- development
CC: @njnes

Last updated: 2017-03-31 13:28:29 +0200

Comment 25166

Date: 2017-03-21 09:41:14 +0100
From: Dean De Leo <>

User-Agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/57.0.2987.98 Safari/537.36
Build Identifier:

Related to bug #6246, my query still cannot bind to the table expression in the from clause in an update statement. The bug is still present after https://www.monetdb.org/hg/MonetDB/rev/235ab012ead8

Reproducible: Always

Steps to Reproduce:

  1. See repro

Actual Results:

An error "no such column 'xxx'" is raised

Expected Results:

Referred fields should be bound to the table expr~ in the FROM clause.

Comment 25167

Date: 2017-03-21 09:41:34 +0100
From: Dean De Leo <>

Created attachment 546
repro.sql

Attached file: update_repro.sql (application/sql, 1289 bytes)
Description: repro.sql

Comment 25168

Date: 2017-03-21 10:00:16 +0100
From: Dean De Leo <>

okay, there is a small mistake in the query :D

undirectedEdges AS (
SELECT person1, person2, CAST(SUM(cost) AS bigint) AS weight
FROM commentsByFriends
GROUP BY person1, person2
)

but the error raised is still unhelpful.. it should be `SELECT: cannot use non GROUP BY column 'cost' in query results without an aggregate function'

Comment 25172

Date: 2017-03-22 20:42:01 +0100
From: @njnes

fixed the error message

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
1 participant