You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm seeing this in 1.22 locally, but I've tested it in 1.25 in the playground.
If you create a view that uses select *, the generated model for that view does not get updated when the base tables are altered.
In the attached playground link, I'd expect the structures of the Author and AuthorsView types to be the same.
Relevant log output
No response
Database schema
CREATETABLEauthors (
id BIGSERIALPRIMARY KEY,
name textNOT NULL,
bio text
);
CREATEVIEWauthors_viewASselect*from authors;
ALTERTABLE authors ADD COLUMN foo text;
SQL queries
-- name: GetAuthor :oneSELECT*FROM authors_view
WHERE id = $1LIMIT1;
Version
1.22.0
What happened?
I'm seeing this in
1.22
locally, but I've tested it in1.25
in the playground.If you create a view that uses
select *
, the generated model for that view does not get updated when the base tables are altered.In the attached playground link, I'd expect the structures of the
Author
andAuthorsView
types to be the same.Relevant log output
No response
Database schema
SQL queries
Configuration
Playground URL
https://play.sqlc.dev/p/cc18541c6f9abb2ac15ebde4a91eec5f8d0bc85c0669e5cfb93616a3f1263a6e
What operating system are you using?
No response
What database engines are you using?
PostgreSQL
What type of code are you generating?
Go
The text was updated successfully, but these errors were encountered: