vapor / fluent-postgres-driver

🐘 PostgreSQL driver for Fluent.
MIT License
149 stars 53 forks source link

Allow to create model with pre-given UUID idKey #76

Closed MihaelIsaev closed 6 years ago

MihaelIsaev commented 6 years ago

The problem

When I'm trying to save model to the database with specified UUID ID it saves with another random UUID ID.

Why I need this fix

I'm trying to transfer data from another database and I really need to use my old UUIDs as PRIMARY KEY ID.

Workaround

We should check if UUID ID is already specified and only in case when it isn't fluent should generate random UUID.

MihaelIsaev commented 6 years ago

I've updated PR description and created related issue.

addisonwebb commented 6 years ago

fixes #56 and #78 - similar to PR #60

penny-coin commented 6 years ago

Hey @MihaelIsaev, you just merged a pull request, have a coin!

You now have 84 coins.

addisonwebb commented 6 years ago

Thanks @tanner0101