-
Notifications
You must be signed in to change notification settings - Fork 0
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
Add crossJoin, innerJoin, leftJoin, rightJoin and fullJoin. #32
Comments
Cross join added before. |
Problem
1. Force using an alias in join.query(childs)
.join(parents, 'p')
.on('parent_id').col.equal('p.id')
.get() And result is like: const r = {
id: 1,
name: 'foo',
/* [[OTHER CHILD PROPS]] */
p: {
id: 2,
name: 'bar',
/* [[OTHER PARENT PROPS]] */
}
} 2. Force using an alias for join and query when using join.query(childs, 'c')
.join(parents, 'p')
.on('c.parent_id').col.equal('p.id')
.get() And result is like: const r = {
c: {
id: 1,
name: 'foo',
/* [[OTHER CHILD PROPS]] */
},
p: {
id: 2,
name: 'bar',
/* [[OTHER PARENT PROPS]] */
}
} 3. Implement both ways 1 and 2, And make them optional.
|
Merged
Merged
I think this issue is too big and I must separate it into smaller issues that will handle in one sprint. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
join()
.innerJoin()
helper.leftJoin()
.rightJoin()
.fullJoin()
.The text was updated successfully, but these errors were encountered: