sqlc-dev / sqlc

Generate type-safe code from SQL
https://sqlc.dev
MIT License
13.51k stars 810 forks source link

Backticks are not supported #3684

Open dector opened 3 weeks ago

dector commented 3 weeks ago

Version

1.27.0

What happened?

Problem:

-- schema.sql
CREATE TABLE `users` (
    `name` text
);

This doesn't work ():

-- queries.sql

-- name: ListUsers :many
SELECT * FROM `users`;
error generating code: source error: 35:52: expected ')', found `id` (and 1 more errors)

sqlc is generating go code with

`name`

instead of just name.

Relevant log output

No response

Database schema

No response

SQL queries

No response

Configuration

No response

Playground URL

No response

What operating system are you using?

No response

What database engines are you using?

SQLite

What type of code are you generating?

Go