Auto Increment doesn't work properly in Oracle #1039

Open
opened 3 years ago by rofly · 4 comments
rofly commented 3 years ago (Migrated from github.com)
Owner

When a field has the tag "autoincr", in the insert process Xorm will always try to select the next value for the sequence from a fixed sequence, named:

https://github.com/go-xorm/xorm/blob/master/session_insert.go#L386

Instead of having an option to specify the sequence name that the value should be extracted from.

When a field has the tag "autoincr", in the insert process Xorm will always try to select the next value for the sequence from a fixed sequence, named: https://github.com/go-xorm/xorm/blob/master/session_insert.go#L386 Instead of having an option to specify the sequence name that the value should be extracted from.
Owner

Please feel free to send a PR.

Please feel free to send a PR.
yixin19 commented 3 years ago (Migrated from github.com)
Owner

Did someone fix this issue?
I have the same problem.
ORA-01036: illegal variable name/number

Did someone fix this issue? I have the same problem. ORA-01036: illegal variable name/number
rofly commented 3 years ago (Migrated from github.com)
Poster
Owner

I started building the code for autoincrement back in 2018, but the project i was working on was canceled and I'm no longer working with Go + Oracle.

I can take a look in the code on monday and reply here.

I started building the code for autoincrement back in 2018, but the project i was working on was canceled and I'm no longer working with Go + Oracle. I can take a look in the code on monday and reply here.
yixin19 commented 3 years ago (Migrated from github.com)
Owner

I started building the code for autoincrement back in 2018, but the project i was working on was canceled and I'm no longer working with Go + Oracle.

I can take a look in the code on monday and reply here.

I will appreciate it if you have the code

> I started building the code for autoincrement back in 2018, but the project i was working on was canceled and I'm no longer working with Go + Oracle. > > I can take a look in the code on monday and reply here. I will appreciate it if you have the code
lunny added the
kind/bug
label 2 years ago
lunny added this to the 1.1.1 milestone 2 years ago
lunny added the
db/oracle
label 5 months ago
lunny modified the milestone from 1.1.1 to 1.3.0 5 months ago
Sign in to join this conversation.
No Milestone
No Assignees
1 Participants
Notifications
Due Date

No due date set.

Dependencies

This issue currently doesn't have any dependencies.

Loading…
There is no content yet.