<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<oembed>
  <author_name>mogami74</author_name>
  <author_url>https://blog.hatena.ne.jp/mogami74/</author_url>
  <blog_title>Because We Love Happy Coding</blog_title>
  <blog_url>https://code.74th.net/</blog_url>
  <categories>
    <anon>PHP</anon>
    <anon>MySQL</anon>
    <anon>RestaurantDB</anon>
  </categories>
  <description>json_encode()で作ったデータをつなぎたい。 最初はMySQLのクエリでLEFT JOINしようとしたんだけど、欲しいデータが2重ループみたいな感じになっている。 foo1 bar1 bar2 foo2 barA barB barC MySQLのLEFT JOINで作ると、1段階目のデータが重複してちょっと扱いづらい。まぁ重複して出て来たデータは無視すりゃいいんだけども。 foo1 bar1 foo1 bar2 foo2 barA foo2 barB foo2 barC MySQLの結果もらってfetchで回す時に、2重ループ作るしかないか…。 while($result1=$stm…</description>
  <height>190</height>
  <html>&lt;iframe src=&quot;https://hatenablog-parts.com/embed?url=https%3A%2F%2Fcode.74th.net%2Fentry%2F2017%2F02%2F26%2F055711&quot; title=&quot;jsonデータを開いて連結する - Because We Love Happy Coding&quot; class=&quot;embed-card embed-blogcard&quot; scrolling=&quot;no&quot; frameborder=&quot;0&quot; style=&quot;display: block; width: 100%; height: 190px; max-width: 500px; margin: 10px 0px;&quot;&gt;&lt;/iframe&gt;</html>
  <image_url></image_url>
  <provider_name>Hatena Blog</provider_name>
  <provider_url>https://hatena.blog</provider_url>
  <published>2017-02-26 05:57:11</published>
  <title>jsonデータを開いて連結する</title>
  <type>rich</type>
  <url>https://code.74th.net/entry/2017/02/26/055711</url>
  <version>1.0</version>
  <width>100%</width>
</oembed>
