Skip to content

Instantly share code, notes, and snippets.

@benfalk
Created December 7, 2016 21:21
Show Gist options
  • Save benfalk/8d75c4200281b0527b9e61a9fcb5f5c3 to your computer and use it in GitHub Desktop.
Save benfalk/8d75c4200281b0527b9e61a9fcb5f5c3 to your computer and use it in GitHub Desktop.
from(
q in query,
where: fragment(
"""
EXISTS(
SELECT NULL FROM froo
WHERE foo.foreign_id = ?
AND foo.is_published = 't'
)
""", q.id
)
)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment