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

Do not create sequences for primary keys #1483

Merged
merged 1 commit into from Sep 12, 2017

Conversation

yahonda
Copy link
Collaborator

@yahonda yahonda commented Sep 12, 2017

Do not create sequences for primary keys. Sequences are generated by GENERATED BY DEFAULT AS IDENTITY

  • default_sequence_name returns sequence name created by GENERATED BY DEFAULT AS IDENTITY
  • Remove create_sequence_and_trigger method
  • reset_pk_sequence! method changes the sequence value created by GENERATED BY DEFAULT AS IDENTITY.
  • Skip specs which do not pass right now

Since this commit, there are some ActiveRecord unit tests start getting
fail. It will be addressed later, in some mid term.

…`GENERATED BY DEFAULT AS IDENTITY`

- `default_sequence_name` returns sequence name created by `GENERATED BY DEFAULT AS IDENTITY`
- Remove `create_sequence_and_trigger` method
- `reset_pk_sequence!` method changes the sequence value created by `GENERATED BY DEFAULT AS IDENTITY`.
- Skip specs which do not pass right now

Since this commit, there are some ActiveRecord unit tests start getting
fail. It will be addressed later, in some mid term.
@yahonda yahonda merged commit e44f222 into rsim:nextval Sep 12, 2017
@yahonda yahonda deleted the nextval_do_not_create_sequences branch September 12, 2017 00:51
yahonda added a commit to yahonda/oracle-enhanced that referenced this pull request Feb 14, 2018
`prefetch_primary_key?` returns `false` and `next_sequence_value`
does nothing to see how identity data type works.

It is similar with rsim#1483, but many sequence related code left
since this is still a POC.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant