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

Configurable primary_key #3

Open
caspiano opened this issue Mar 6, 2020 · 0 comments
Open

Configurable primary_key #3

caspiano opened this issue Mar 6, 2020 · 0 comments
Labels
enhancement New feature or request

Comments

@caspiano
Copy link
Contributor

caspiano commented Mar 6, 2020

# usage
class Model < RethinkORM::Base
  primary_key hash
  attribute hash : String
end

This will require configuring the table with the desired primary_key on startup.
We'll also need a validator to ensure that key lengths are less than 127 chars (a RethinkDB system limit).

We'll also need to update queries to use the primary key by default.

@caspiano caspiano added the enhancement New feature or request label Mar 6, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant