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

Basic Update statement with increment value not working #1931

Open
IvRRimum opened this issue Nov 24, 2021 · 0 comments
Open

Basic Update statement with increment value not working #1931

IvRRimum opened this issue Nov 24, 2021 · 0 comments

Comments

@IvRRimum
Copy link

IvRRimum commented Nov 24, 2021

Issue tracker is used for reporting bugs and discussing new features. Please use
Discord or stackoverflow for supporting
issues.

Expected Behavior

Should increment amount

Current Behavior

Does not increment amount

Steps to Reproduce

_, err := j.DB.Model((*orm.Wallet)(nil)).Exec(`
UPDATE wallets SET amount = amount + 1, updated_at = ? WHERE id = ?
`, time.Now(), tx.Wallet.ID)

Context (Environment)

I cant increment value

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