4 ms·
I like it! One problem you will run into is putting a LIMIT on relationship queries You can't use a limit for this select post [ id title # Can
by gavinray 4y ago
I like it!
One problem you will run into is putting a LIMIT on relationship queries
You can't use a limit for this
select post [
id
title
# Can't generate simple LIMIT here
user { nickname } limit 2
]
limit 5
- aabbcc1241 4y agoIt doesn't make sense to put two limit here, it's essential a single select query with join table. If you mean use sub-query. You may write something like below select post [ id title user { nickname } ] limit 5 where user_id in ( select user [ id ] order by created_at desc limit 2 ) Thanks for your interest, welcome more questions and ideas :)