# Issue with Ecto query preloading

**URL:** <https://forum.elixirforum.com/t/issue-with-ecto-query-preloading/8882>\
**Category:** Questions\
**Tags:** ecto, book-programming-phoenix, phoenix\
**Created:** [September 25, 2017, 1:48pm UTC](https://forum.elixirforum.com/t/issue-with-ecto-query-preloading/8882 "2017-09-25T13:48:40Z")\
**Posts on this page:** 1\
**Showing post:** 3

<div class="post-metadata">

**Author:** ![lapinkoira](https://forum.elixirforum.com/letter_avatar_proxy/v4/letter/l/f4b2a3/32.png) [@lapinkoira](https://forum.elixirforum.com/u/lapinkoira)\
**Post date:** [September 25, 2017, 2:21pm UTC](https://forum.elixirforum.com/t/issue-with-ecto-query-preloading/8882/3 "2017-09-25T14:21:08Z")

</div>

Thanks that works, is there a way to make it more elegant handling it at the template? like “if video.category is nil dont ask for it”

---

_[View the full topic](https://forum.elixirforum.com/t/issue-with-ecto-query-preloading/8882)._
