<turbo-stream action="append" target="posts_list"><template>    <div class="postbit" id="128670" data-post-id="128670">
  <section>
    <div class="post-wrap">


					<div class="post-header">
		        <div class="user-avatar">
		          <img alt="Rainer" src="https://forum.elixirforum.com/user_avatar/forum.elixirforum.com/Rainer/120/15469_2.png" width="120" height="120" />
		        </div>
					
						<div class="user-details">
		          <div class="user-name">
		            <h3>
                  Rainer
                  </h3>
		          </div>
						
						</div>
					
					</div>

	        <div class="thread-main">
	            <div class="post-body" data-turbo="false">
								<p>I updated my test to output the uuid’s:<br>
insert: a0569da7-4201-47a8-bab0-4aca263b735a =&gt; ok<br>
insert: cc2d9293-5898-4118-8352-c192090bf6ef =&gt; fail, got new id: 3f2d3f3f-583f-4118-3f52-3f3f090b3f00</p>
<p>another run:<br>
insert: 2361f715-48f9-4574-9cb2-379883a8adc4 =&gt; got new id: 23613f15-483f-4574-3f3f-373f3f3f3f00</p>
<p>interesting: the new id’s are sharing some parts with the original ones…</p>
<p>/e: now found this: <a href="https://github.com/elixir-ecto/ecto/issues/2602" class="inline-onebox" rel="noopener nofollow ugc">binary id odd bug · Issue #2602 · elixir-ecto/ecto · GitHub</a><br>
i’ll try that later, hope it fixes the problem <img src="https://forum.elixirforum.com/images/emoji/apple/slight_smile.png?v=15" title=":slight_smile:" class="emoji" alt=":slight_smile:" loading="lazy" width="20" height="20"></p>
<p>/e²: Fixed it by adding utf8mb4 to the repo config (config/dev.exs):</p>
<pre data-code-wrap="elixir"><code class="lang-elixir"># Configure your database
config :testproject, Testproject.Repo,
  username: "xyz",
  password: "xyz",
  database: "xyz",
  hostname: "xyz",
  charset: "utf8mb4",
  collate: "utf8mb4_unicode_ci"
</code></pre> 
	            </div>

	            <div class="base-line">
	                <div class="thread-counters">
	                    <span class="thread-count count-likes js-likers-trigger" title="Likes" data-post-id="128670" data-batch-url="/posts/batch_likers">
                        3
                      </span>
                      <!-- <span class="thread-count js-solved-indicator" title="Marked as solution"></span> -->
	                </div>
	                <div class="go-to-post">
	                  <a title="Go to post" alt="Go to post" href="https://forum.elixirforum.com/t/ecto-mysql-and-uuid/21768/22">Post #21</a>
	                </div>
	            </div>
              <div id="likers-container-128670" 
                   class="likers-container"
                   data-first-post="false"
                   data-batch-url="/posts/batch_likers">
                   <div class="likers-placeholder" 
                     data-likers-post-id="128670"
                     data-batch-url="/posts/batch_likers">
                  <div class="post-likers"></div>
                </div>
              </div>
	        </div>
			

    </div>

    <div class="triangle-top-right type-last-post cat-last-post" title="Last post!"></div>
  </section>
</div>
</template></turbo-stream><turbo-stream action="replace" target="load-more-container"><template><div id="load-more-container" class="load-more-container">
    <span class="all-loaded">— All posts loaded —</span>
</div></template></turbo-stream>