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

Multiple query functions generated with same function name, breaks code compilation #320

Open
fho opened this issue Sep 13, 2021 · 0 comments

Comments

@fho
Copy link
Contributor

fho commented Sep 13, 2021

Hello,

we have a PostgreSQL table that is similar to:

create table xotest (id integer primary key, name varchar, constraint name_uniq UNIQUE(name));
create extension pg_trgm;
CREATE INDEX name_trgm_idx ON xotest USING gin ("name" gin_trgm_ops);

When I generate go code for its database schema, 2 query functions are generated that are both namedXotestByName.
Because of the naming collision the Go code does not compile.

I'm using xo version c38a7b6

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

No branches or pull requests

1 participant