Skip to content
This repository has been archived by the owner on Aug 13, 2021. It is now read-only.

Do not enforce PK sort when table has no PK. #57

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

devinivy
Copy link
Contributor

Intended to fix #23. Would like a bit of testing on this, if anyone has the time.

@yisyang
Copy link

yisyang commented Sep 13, 2015

Would like to see fix on the issue also.

Also would like someone with more knowledge to comment on the following comment present in 3 places in the code, each of them with a childPK that would resolve into undefined nearby:

// Ensure a sort is always set so that we get back consistent results

@devinivy
Copy link
Contributor Author

The assumption the code makes is that there is indeed a primary key. Given that assumption, waterline-sequel is opting to sort using that PK so that the order of the result set is well-defined, which would just be a nice property of the query.

@tjwebb
Copy link
Contributor

tjwebb commented Nov 18, 2015

@devinivy what's the status of this? tested? kind of unclear to me

@Crusader4Christ
Copy link

+1

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Development

Successfully merging this pull request may close these issues.

Calling destroy() with criteria on a model without a PK defined generates an error on MySQL
4 participants