Skip to content

Singular Table Name Ending with "s" #430

Closed
@cstoltze

Description

@cstoltze

With the following schema:

CREATE TABLE public.campus (
    id integer NOT NULL
);

Running gqlgen produces

type Campu struct {
	ID             int32          `json:"id"`
}

I would prefer to have the struct keep the "s" at the end of campus.

I also tried to use the rename configuration option in my sqlc.yaml file but the "s" is still stripped.

rename:
  campus: Campus

Is there a supported way to force the struct name to be "Campus"?

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions