# Ecto preoload with custom function

**URL:** <https://forum.elixirforum.com/t/ecto-preoload-with-custom-function/14382>\
**Category:** Questions\
**Tags:** ecto, phoenix, image\
**Created:** [May 26, 2018, 4:50am UTC](https://forum.elixirforum.com/t/ecto-preoload-with-custom-function/14382 "2018-05-26T04:50:04Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![lastday4you](https://forum.elixirforum.com/user_avatar/forum.elixirforum.com/lastday4you/32/10304_2.png) [@lastday4you](https://forum.elixirforum.com/u/lastday4you)\
**Post date:** [May 26, 2018, 4:50am UTC](https://forum.elixirforum.com/t/ecto-preoload-with-custom-function/14382/1 "2018-05-26T04:50:05Z")

</div>

Hi guys, I am a bit confused I am using Arc & Arc Ecto for image processing i have created many version of files but having problem to preload all the version url from the controller. currently it only return the default one with the original version.

 ![controller](https://forum.elixirforum.com/uploads/default/original/2X/a/a36c7c9d307de1fb241371b9424804d84ecb3127.png) ![19%20AM](https://forum.elixirforum.com/uploads/default/original/2X/0/0894449d30ed277d029f0124f3a56ce409f7e9da.png) ![image%20uploader](https://forum.elixirforum.com/uploads/default/original/2X/3/3d64e689dfe202c5ca0bbac9a286a247b0c77be0.jpg)

---

<div class="post-metadata">

**Author:** ![lastday4you](https://forum.elixirforum.com/user_avatar/forum.elixirforum.com/lastday4you/32/10304_2.png) [@lastday4you](https://forum.elixirforum.com/u/lastday4you)\
**Post date:** [May 26, 2018, 4:52am UTC](https://forum.elixirforum.com/t/ecto-preoload-with-custom-function/14382/2 "2018-05-26T04:52:24Z")

</div>

sorry guys I am so stupid i could change it in the view. haven’t touch phoenix for quite sometime and got confused

---

<div class="post-metadata">

**Author:** ![NobbZ](https://forum.elixirforum.com/user_avatar/forum.elixirforum.com/nobbz/32/27235_2.png) [@NobbZ](https://forum.elixirforum.com/u/NobbZ)\
**Post date:** [May 26, 2018, 1:25pm UTC](https://forum.elixirforum.com/t/ecto-preoload-with-custom-function/14382/3 "2018-05-26T13:25:47Z")

</div>

I’m happy that you were able to solve your problem. But I were even more happy if you could copy and paste your code in the future, as many users (including me) are accessing this forum through mobile phones or via a mailing list like interface. For such users plain text/code is much more accessible than screenshots of code.

---

<div class="post-metadata">

**Author:** ![lastday4you](https://forum.elixirforum.com/user_avatar/forum.elixirforum.com/lastday4you/32/10304_2.png) [@lastday4you](https://forum.elixirforum.com/u/lastday4you)\
**Post date:** [June 6, 2018, 4:53am UTC](https://forum.elixirforum.com/t/ecto-preoload-with-custom-function/14382/4 "2018-06-06T04:53:33Z")

</div>

sorry will do that next time
