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

Ambiguous column present in multiple tables #812

Closed
erizocosmico opened this issue May 10, 2019 · 2 comments · Fixed by #813
Closed

Ambiguous column present in multiple tables #812

erizocosmico opened this issue May 10, 2019 · 2 comments · Fixed by #813
Assignees
Labels
blocked Some other issue is blocking this bug Something isn't working

Comments

@erizocosmico
Copy link
Contributor

    SELECT repository_id, SUM(ARRAY_LENGTH(SPLIT(blob_content, '\n'))) AS n_loc
    FROM refs
    NATURAL JOIN commits
    NATURAL JOIN commit_files
    NATURAL JOIN files
    WHERE ref_name = 'HEAD'
          AND NOT IS_BINARY(blob_content)
          AND file_path NOT LIKE 'vendor/%%'
    GROUP BY repository_id
  LIMIT 1;
Query Failed - unknown error: ambiguous column name "repository_id", it's present in all these tables: refs, files

(not the exact error for this query, but the same kind of error)

@erizocosmico erizocosmico added the bug Something isn't working label May 10, 2019
@erizocosmico erizocosmico self-assigned this May 10, 2019
@erizocosmico
Copy link
Contributor Author

erizocosmico commented May 10, 2019

This will be fixed once this PR is merged and go-mysql-server version is updated here.

@erizocosmico erizocosmico added the blocked Some other issue is blocking this label May 14, 2019
@erizocosmico
Copy link
Contributor Author

Waiting for src-d/go-mysql-server#708 to be merged before updating

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
blocked Some other issue is blocking this bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant