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

Disable timestamp fields for many_to_many relation table #462

Open
fnaysee opened this issue Apr 3, 2019 · 0 comments
Open

Disable timestamp fields for many_to_many relation table #462

fnaysee opened this issue Apr 3, 2019 · 0 comments
Labels
project:soda/pop This concerns soda/pop

Comments

@fnaysee
Copy link

fnaysee commented Apr 3, 2019

I have two tables called tags and cards
There is also a table called card_tags for making relation between cards and their tags
I have disabled timestamp fields for the relation table because they are really unnecessary and i created a model CardTag with following content:

package models

type CardTag struct {
	CardId 	int64 `json:"card_id" db:"card_id"`
	TagId 	int64 `json:"tag_id" db:"tag_id"`
}

But in runtime sounds like the framework is not using above model and gives this error:

pq: column "created_at" of relation "card_tags" does not exist.

Is there a way to disable timestamps for this table ?

Thanks.

@stanislas-m stanislas-m added the project:soda/pop This concerns soda/pop label Feb 21, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
project:soda/pop This concerns soda/pop
Projects
None yet
Development

No branches or pull requests

2 participants