<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<oembed>
  <author_name>neginegitoro</author_name>
  <author_url>https://blog.hatena.ne.jp/neginegitoro/</author_url>
  <blog_title>ねぎとろ放浪記</blog_title>
  <blog_url>https://neginegitoro.hatenablog.com/</blog_url>
  <categories>
    <anon>Java</anon>
    <anon>Spring Boot</anon>
    <anon>Spring Data JPA</anon>
  </categories>
  <description>INNER JOIN などのテーブル結合を含むクエリの結果の受け取り方で詰まったのでメモ。 @SqlRusltSetMappingを使用するか、Objectの配列を目的の型に変換する方法がある。 例として、ItemsテーブルとPricesテーブルを結合し、ItemごとのPriceの結果を受け取る。 テーブルの定義 CREATE TABLE items( id BIGINT NOT NULL PRIMARY KEY AUTO_INCREMENT, name VARCHAR(16) NOT NULL ); CREATE TABLE prices( id BIGINT NOT NULL PRIMAR…</description>
  <height>190</height>
  <html>&lt;iframe src=&quot;https://hatenablog-parts.com/embed?url=https%3A%2F%2Fneginegitoro.hatenablog.com%2Fentry%2Fspring-data-jpa-join-query-result&quot; title=&quot;【Spring Data JPA】テーブル結合を含むクエリの結果を受け取る - ねぎとろ放浪記&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>https://cdn.blog.st-hatena.com/images/theme/og-image-1500.png</image_url>
  <provider_name>Hatena Blog</provider_name>
  <provider_url>https://hatena.blog</provider_url>
  <published>2022-05-31 20:45:08</published>
  <title>【Spring Data JPA】テーブル結合を含むクエリの結果を受け取る</title>
  <type>rich</type>
  <url>https://neginegitoro.hatenablog.com/entry/spring-data-jpa-join-query-result</url>
  <version>1.0</version>
  <width>100%</width>
</oembed>
