{"id":1670,"date":"2025-05-15T11:15:14","date_gmt":"2025-05-15T02:15:14","guid":{"rendered":"https:\/\/route-zero.com\/recruit\/?post_type=route&#038;p=1670"},"modified":"2025-10-15T11:15:22","modified_gmt":"2025-10-15T02:15:22","slug":"spring-boot-repository%e5%be%b9%e5%ba%95%e8%a7%a3%e8%aa%ac%ef%bd%9cjpa%e3%83%bbnativequery%e3%81%ae%e4%bd%bf%e3%81%84%e6%96%b9%e3%81%a8%e5%a4%b1%e6%95%97%e4%be%8b","status":"publish","type":"route","link":"https:\/\/route-zero.com\/recruit\/route\/1670\/","title":{"rendered":"Spring Boot Repository\u5fb9\u5e95\u89e3\u8aac\uff5cJPA\u30fbnativeQuery\u306e\u4f7f\u3044\u65b9\u3068\u5931\u6557\u4f8b"},"content":{"rendered":"<div>\n<h2>\u5c0e\u5165\u6587<\/h2>\n<p>\n    \u300c<strong>Repository<\/strong>\u3063\u3066\u5b9f\u969b\u3069\u3046\u4f7f\u3048\u3070\u3044\u3044\u306e\uff1f\u300d\u2500\u2500\u305d\u3093\u306a\u7591\u554f\u3092\u62b1\u3044\u305f\u3053\u3068\u306f\u3042\u308a\u307e\u305b\u3093\u304b\uff1f<br \/>\n    \u79c1\u305f\u3061\u958b\u767a\u8005\u306b\u3068\u3063\u3066\u3001Spring Boot\u306eRepository\u306f\u696d\u52d9\u52b9\u7387\u3068\u54c1\u8cea\u3092\u4e21\u7acb\u3055\u305b\u308b\u9375\u3067\u3059\u3002\n  <\/p>\n<p><strong>JPA<\/strong>\u3067SQL\u3092\u62bd\u8c61\u5316\u3057\u3001<strong>nativeQuery<\/strong>\u3067\u67d4\u8edf\u306a\u64cd\u4f5c\u3092\u5b9f\u73fe\u3002 \u3055\u3089\u306b\u3001<strong>@Entity<\/strong>\u3084<strong>@Query<\/strong>\u306a\u3069\u306e\u30a2\u30ce\u30c6\u30fc\u30b7\u30e7\u30f3\u3092\u6b63\u3057\u304f\u4f7f\u3044\u5206\u3051\u308b\u3053\u3068\u3067\u3001 \u8a2d\u8a08\u306e\u81ea\u7531\u5ea6\u304c\u5927\u304d\u304f\u5e83\u304c\u308a\u307e\u3059\u3002<\/p>\n<p>\u672c\u8a18\u4e8b\u3067\u306f\u3001<strong>Repository\u306e\u5b9a\u7fa9\u30fb\u8a2d\u8a08\u30fb\u5b9f\u88c5<\/strong>\u304b\u3089\u3001<strong>JPA<\/strong>\u306e\u57fa\u672c\u3001<strong>nativeQuery<\/strong>\u306e\u6d3b\u7528\u6cd5\u3001 \u4e3b\u8981\u30a2\u30ce\u30c6\u30fc\u30b7\u30e7\u30f3\u306e\u5f79\u5272\u3068\u6ce8\u610f\u70b9\u307e\u3067\u3092\u4f53\u7cfb\u7684\u306b\u89e3\u8aac\u3057\u3001\u73fe\u5834\u3067\u3059\u3050\u518d\u73fe\u3067\u304d\u308b\u77e5\u8b58\u3092\u63d0\u4f9b\u3057\u307e\u3059\u3002<\/p>\n<hr \/>\n<h2>Spring Boot Repository\u3068\u306f\uff1f\u5b9a\u7fa9\u3068\u57fa\u672c\u8a2d\u8a08<\/h2>\n<p>\n    <strong>Repository\u30d1\u30bf\u30fc\u30f3<\/strong>\u306f\u30c7\u30fc\u30bf\u30a2\u30af\u30bb\u30b9\u5c64\u306e\u5171\u901a\u5316\u3092\u76ee\u7684\u3068\u3057\u305f\u8a2d\u8a08\u624b\u6cd5\u3067\u3059\u3002<br \/>\n    Spring Boot\u3067\u306f\u3001<code>CrudRepository<\/code>\u3084<code>JpaRepository<\/code>\u3092\u7d99\u627f\u3059\u308b\u3060\u3051\u3067\u3001 \u6a19\u6e96\u7684\u306aCRUD\u64cd\u4f5c\uff08Create, Read, Update, Delete\uff09\u3092\u7c21\u6f54\u306b\u5b9f\u88c5\u3067\u304d\u307e\u3059\u3002\n  <\/p>\n<p>\u7d50\u679c\u3068\u3057\u3066\u3001SQL\u3084JDBC\u306e\u7169\u96d1\u306a\u8a18\u8ff0\u3092\u5927\u5e45\u306b\u524a\u6e1b\u3057\u3001\u4fdd\u5b88\u6027\u3068\u518d\u5229\u7528\u6027\u3092\u4e21\u7acb\u3067\u304d\u307e\u3059\u3002<\/p>\n<div style=\"background: #f8f8f8; border-left: 4px solid #1976d2; padding: 10px; margin-top: 10px\">\n    <strong>\u30dd\u30a4\u30f3\u30c8\u89e3\u8aac\uff1a<\/strong><br \/>\n    Repository\u306f\u300c\u30c7\u30fc\u30bf\u30d9\u30fc\u30b9\u3068\u3084\u308a\u3068\u308a\u3059\u308b\u7a93\u53e3\u300d\u3067\u3059\u3002<br \/>\n    \u4f8b\u3048\u3070\u300c\u30e6\u30fc\u30b6\u30fc\u4e00\u89a7\u3092\u53d6\u5f97\u3057\u305f\u3044\u300d\u300c\u65b0\u3057\u3044\u30c7\u30fc\u30bf\u3092\u4fdd\u5b58\u3057\u305f\u3044\u300d\u3068\u3044\u3063\u305f\u64cd\u4f5c\u3092\u3001\u8907\u96d1\u306aSQL\u3092\u66f8\u304b\u305a\u306b\u7c21\u5358\u306a\u30e1\u30bd\u30c3\u30c9\u547c\u3073\u51fa\u3057\u3067\u5b9f\u73fe\u3067\u304d\u307e\u3059\u3002<br \/>\n    \u3053\u308c\u306b\u3088\u308a\u3001\u30a2\u30d7\u30ea\u306e\u30ed\u30b8\u30c3\u30af\u3068\u30c7\u30fc\u30bf\u64cd\u4f5c\u3092\u5206\u3051\u3066\u7ba1\u7406\u3067\u304d\u3001\u30b3\u30fc\u30c9\u304c\u898b\u3084\u3059\u304f\u306a\u308a\u307e\u3059\u3002\n  <\/div>\n<blockquote>\n<p>\n      <strong>\u7528\u8a9e\u89e3\u8aac\uff1aRepository\u30d1\u30bf\u30fc\u30f3<\/strong><br \/>\n      \u30c7\u30fc\u30bf\u30a2\u30af\u30bb\u30b9\u51e6\u7406\u3092\u62bd\u8c61\u5316\u3057\u3001\u30d3\u30b8\u30cd\u30b9\u30ed\u30b8\u30c3\u30af\u3068\u5206\u96e2\u3059\u308b\u8a2d\u8a08\u624b\u6cd5\u3002 Spring Boot\u3067\u306f\u3001Repository\u30a4\u30f3\u30bf\u30fc\u30d5\u30a7\u30fc\u30b9\u3092\u7d99\u627f\u3059\u308b\u3053\u3068\u3067\u3001SQL\u8a18\u8ff0\u3092\u6e1b\u3089\u3057\u4fdd\u5b88\u6027\u3092\u9ad8\u3081\u307e\u3059\u3002\n    <\/p>\n<\/blockquote>\n<hr \/>\n<h2>JPA\u306b\u3088\u308b\u62bd\u8c61\u5316\u306e\u30e1\u30ea\u30c3\u30c8<\/h2>\n<p><strong>JPA<\/strong>\u306f\u3001\u30aa\u30d6\u30b8\u30a7\u30af\u30c8\u3068DB\u9593\u306e\u30de\u30c3\u30d4\u30f3\u30b0\u3092\u81ea\u52d5\u5316\u3057\u3001 \u958b\u767a\u8005\u306e\u8a18\u8ff0\u91cf\u3092\u6e1b\u3089\u3059\u3068\u540c\u6642\u306b\u4e00\u8cab\u3057\u305f\u8a2d\u8a08\u3092\u5b9f\u73fe\u3057\u307e\u3059\u3002 <strong>Spring Data JPA<\/strong>\u3092\u4f7f\u3048\u3070\u3001\u8907\u96d1\u306a\u30af\u30a8\u30ea\u3082\u30a2\u30ce\u30c6\u30fc\u30b7\u30e7\u30f3\u3067\u5b8c\u7d50\u3067\u304d\u307e\u3059\u3002<\/p>\n<p>\uff08JPA\u3068JDBC\u306e\u4f7f\u3044\u5206\u3051\u306b\u3064\u3044\u3066\u306f\u300e<a href=\"https:\/\/route-zero.com\/recruit\/route\/1264\/\">JPA vs JDBC\u2502Spring Boot\u3067\u306e\u5b9f\u52d9\u7684\u306a\u4f7f\u3044\u5206\u3051\u3068\u5c0e\u5165\u5224\u65ad\u30ac\u30a4\u30c9<\/a>\u300f\u3092\u3054\u53c2\u7167\u304f\u3060\u3055\u3044\uff09<\/p>\n<div style=\"background: #f8f8f8; border-left: 4px solid #1976d2; padding: 10px; margin-top: 10px\">\n    <strong>\u30dd\u30a4\u30f3\u30c8\u89e3\u8aac\uff1a<\/strong><br \/>\n    JPA\u3092\u4f7f\u3046\u3053\u3068\u3067\u300cSQL\u3092\u66f8\u304f\u624b\u9593\u304c\u6e1b\u308b\u300d\u300c\u30c6\u30b9\u30c8\u3084\u8a2d\u8a08\u304c\u30b7\u30f3\u30d7\u30eb\u306b\u306a\u308b\u300d\u300cDB\u5909\u66f4\u306b\u3082\u67d4\u8edf\u306b\u5bfe\u5fdc\u3067\u304d\u308b\u300d\u3068\u3044\u3063\u305f\u30e1\u30ea\u30c3\u30c8\u304c\u3042\u308a\u307e\u3059\u3002<br \/>\n    \u4f8b\u3048\u3070\u3001\u30a8\u30f3\u30c6\u30a3\u30c6\u30a3\u30af\u30e9\u30b9\u3092\u5909\u66f4\u3059\u308b\u3060\u3051\u3067DB\u69cb\u9020\u306e\u5909\u66f4\u306b\u8ffd\u5f93\u3067\u304d\u3001\u4fdd\u5b88\u6027\u304c\u9ad8\u307e\u308a\u307e\u3059\u3002\n  <\/div>\n<p>\n    \u516c\u5f0f\u30c9\u30ad\u30e5\u30e1\u30f3\u30c8\u306b\u3088\u308b\u3068\u3001\u3053\u306e\u62bd\u8c61\u5316\u306b\u3088\u3063\u3066\u300c\u30c6\u30b9\u30c8\u5bb9\u6613\u6027\u300d\u300c\u8a2d\u8a08\u306e\u4e00\u8cab\u6027\u300d\u300c\u30d1\u30d5\u30a9\u30fc\u30de\u30f3\u30b9\u6700\u9069\u5316\u300d\u304c\u53ef\u80fd\u3067\u3059\u3002<br \/>\n    \u3010\u51fa\u5178\uff1a<a href=\"https:\/\/spring.pleiades.io\/guides\/gs\/accessing-data-jpa\/\">Spring\u516c\u5f0f\u30ac\u30a4\u30c9<\/a>\u3011\n  <\/p>\n<blockquote>\n<p>\n      <strong>\u7528\u8a9e\u89e3\u8aac\uff1aJPA\uff08Java Persistence API\uff09<\/strong><br \/>\n      Java\u30aa\u30d6\u30b8\u30a7\u30af\u30c8\u3068\u30ea\u30ec\u30fc\u30b7\u30e7\u30ca\u30ebDB\u3092\u81ea\u52d5\u7684\u306b\u30de\u30c3\u30d4\u30f3\u30b0\u3059\u308b\u4ed5\u7d44\u307f\u3002SQL\u3092\u76f4\u63a5\u66f8\u304b\u305a\u306b\u30c7\u30fc\u30bf\u64cd\u4f5c\u304c\u53ef\u80fd\u3067\u3059\u3002\n    <\/p>\n<\/blockquote>\n<hr \/>\n<h2>Repository\u3067\u4f7f\u3046\u4e3b\u8981\u30a2\u30ce\u30c6\u30fc\u30b7\u30e7\u30f3\u4e00\u89a7\u3068\u5f79\u5272<\/h2>\n<h3>@Entity, @Id, @GeneratedValue, @Table<\/h3>\n<ul>\n<li><strong>@Entity<\/strong>\uff1aJPA\u7ba1\u7406\u5bfe\u8c61\u30af\u30e9\u30b9\u3092\u6307\u5b9a<\/li>\n<li><strong>@Id<\/strong>\uff1a\u4e3b\u30ad\u30fc\u3092\u6307\u5b9a<\/li>\n<li><strong>@GeneratedValue<\/strong>\uff1a\u4e3b\u30ad\u30fc\u306e\u81ea\u52d5\u751f\u6210\u65b9\u6cd5\u3092\u6307\u5b9a<\/li>\n<li><strong>@Table<\/strong>\uff1a\u30c6\u30fc\u30d6\u30eb\u540d\u3084\u30b9\u30ad\u30fc\u30de\u3092\u660e\u793a<\/li>\n<\/ul>\n<p>\u3053\u308c\u3089\u306f\u30a8\u30f3\u30c6\u30a3\u30c6\u30a3\u5b9a\u7fa9\u306e\u57fa\u790e\u3067\u3042\u308a\u3001DB\u8a2d\u8a08\u3068Java\u30af\u30e9\u30b9\u306e\u6a4b\u6e21\u3057\u3092\u62c5\u3044\u307e\u3059\u3002<\/p>\n<p>\uff08Spring Boot\u306e\u3088\u304f\u4f7f\u308f\u308c\u308b\u30a2\u30ce\u30c6\u30fc\u30b7\u30e7\u30f3\u306b\u3064\u3044\u3066\u306f\u300e<a href=\"https:\/\/route-zero.com\/recruit\/route\/1104\/\">Spring Boot\u306e\u3088\u304f\u4f7f\u308f\u308c\u308b\u30a2\u30ce\u30c6\u30fc\u30b7\u30e7\u30f3\u3068\u306f\uff1f\u521d\u5fc3\u8005\u5fc5\u898b\u306e\u89e3\u8aac\u3068\u6d3b\u7528\u6cd5<\/a>\u300f\u3092\u3054\u53c2\u7167\u304f\u3060\u3055\u3044\uff09<\/p>\n<blockquote>\n<p>\n      <strong>\u7528\u8a9e\u89e3\u8aac\uff1a\u30a2\u30ce\u30c6\u30fc\u30b7\u30e7\u30f3<\/strong><br \/>\n      Java\u306e\u30af\u30e9\u30b9\u3084\u30e1\u30bd\u30c3\u30c9\u306b\u4ed8\u4e0e\u3059\u308b\u300c\u76ee\u5370\u300d\u3002Spring Boot\u3067\u306fDB\u69cb\u9020\u3068\u5bfe\u5fdc\u4ed8\u3051\u306b\u4f7f\u308f\u308c\u307e\u3059\u3002\n    <\/p>\n<\/blockquote>\n<h3>@Query, @Modifying, @Transactional<\/h3>\n<ul>\n<li><strong>@Query<\/strong>\uff1aJPQL\u3084nativeQuery\u3092\u4f7f\u3063\u305f\u30ab\u30b9\u30bf\u30e0\u30af\u30a8\u30ea\u3092\u8a18\u8ff0<\/li>\n<li><strong>@Modifying<\/strong>\uff1a\u66f4\u65b0\u7cfb\u30af\u30a8\u30ea\u306b\u4ed8\u4e0e\uff08UPDATE \/ DELETE\uff09<\/li>\n<li><strong>@Transactional<\/strong>\uff1a\u30e1\u30bd\u30c3\u30c9\u5358\u4f4d\u3067\u30c8\u30e9\u30f3\u30b6\u30af\u30b7\u30e7\u30f3\u3092\u5236\u5fa1<\/li>\n<\/ul>\n<p>\u7279\u306b\u8907\u96d1\u306a\u691c\u7d22\u3084\u4e00\u62ec\u66f4\u65b0\u51e6\u7406\u3067\u306f\u3001\u3053\u308c\u3089\u306e\u30a2\u30ce\u30c6\u30fc\u30b7\u30e7\u30f3\u304c\u4e0d\u53ef\u6b20\u3067\u3059\u3002<\/p>\n<blockquote>\n<p>\n      <strong>\u7528\u8a9e\u89e3\u8aac\uff1anativeQuery<\/strong><br \/>\n      DB\u56fa\u6709\u306eSQL\u3092\u76f4\u63a5\u5b9f\u884c\u3059\u308b\u6a5f\u80fd\u3002JOIN\u3084\u96c6\u7d04\u95a2\u6570\u306a\u3069\u3001JPA\u3067\u8868\u73fe\u3057\u3065\u3089\u3044\u51e6\u7406\u306b\u6709\u52b9\u3067\u3059\u3002\n    <\/p>\n<p>\n      <strong>\u7528\u8a9e\u89e3\u8aac\uff1aJPQL \/ nativeQuery \/ \u30c8\u30e9\u30f3\u30b6\u30af\u30b7\u30e7\u30f3<\/strong><br \/>\n      JPQL\u306fJPA\u7528\u306eSQL\u30e9\u30a4\u30af\u306a\u8a00\u8a9e\u3002<strong>nativeQuery<\/strong>\u306f\u751fSQL\u3092\u76f4\u63a5\u8a18\u8ff0\u3067\u304d\u3001<br \/>\n      <strong>@Transactional<\/strong>\u306f\u4e00\u9023\u306e\u51e6\u7406\u3092\u5b89\u5168\u306b\u307e\u3068\u3081\u307e\u3059\u3002\n    <\/p>\n<\/blockquote>\n<hr \/>\n<h2>nativeQuery\u3068\u306f\uff1f\u4f7f\u3044\u65b9\u3068\u6ce8\u610f\u70b9<\/h2>\n<p>\n    <strong>nativeQuery<\/strong>\u3068\u306f\u3001JPA\u306e@Query\u30a2\u30ce\u30c6\u30fc\u30b7\u30e7\u30f3\u3067\u300c\u751f\u306eSQL\u300d\u3092\u76f4\u63a5\u8a18\u8ff0\u3067\u304d\u308b\u6a5f\u80fd\u3067\u3059\u3002<br \/>\n    \u901a\u5e38\u306eJPQL\u3067\u306f\u8868\u73fe\u3057\u3065\u3089\u3044\u8907\u96d1\u306aJOIN\u3084\u96c6\u7d04\u95a2\u6570\u3001DB\u56fa\u6709\u306e\u69cb\u6587\u3082\u5229\u7528\u3067\u304d\u307e\u3059\u3002\n  <\/p>\n<p>\u4f8b\u3048\u3070\u6b21\u306e\u3088\u3046\u306b\u8a18\u8ff0\u3057\u307e\u3059\u3002<\/p>\n<pre><code>@Query(value = \"SELECT * FROM users WHERE status = ?1\", nativeQuery = true)<\/code><\/pre>\n<p>\u203bnativeQuery=true\u3092\u6307\u5b9a\u3059\u308b\u3053\u3068\u3067\u3001SQL\u6587\u304c\u305d\u306e\u307e\u307eDB\u306b\u6e21\u3055\u308c\u307e\u3059\u3002<\/p>\n<p>\n    \u305f\u3060\u3057\u3001\u578b\u5909\u63db\u3084SQL\u69cb\u6587\u30a8\u30e9\u30fc\u3001\u8fd4\u5374\u578b\u306e\u4e0d\u4e00\u81f4\u306a\u3069\u306b\u6ce8\u610f\u304c\u5fc5\u8981\u3067\u3059\u3002<br \/>\n    \u30d1\u30e9\u30e1\u30fc\u30bf\u30d0\u30a4\u30f3\u30c9\u3092\u5fb9\u5e95\u3057\u3001SQL\u30a4\u30f3\u30b8\u30a7\u30af\u30b7\u30e7\u30f3\u5bfe\u7b56\u3082\u5fd8\u308c\u305a\u306b\u884c\u3044\u307e\u3057\u3087\u3046\u3002\n  <\/p>\n<hr \/>\n<h2>Spring Boot Repository\u306e\u5b9f\u88c5\u624b\u9806\u3068\u5931\u6557\u4e8b\u4f8b<\/h2>\n<h3>\u5178\u578b\u7684\u306a\u30a8\u30e9\u30fc<\/h3>\n<ul>\n<li>\u30a8\u30f3\u30c6\u30a3\u30c6\u30a3\u306e\u30d5\u30a3\u30fc\u30eb\u30c9\u540d\u3068DB\u30ab\u30e9\u30e0\u540d\u306e\u4e0d\u4e00\u81f4<\/li>\n<li><strong>@Query<\/strong>\u69cb\u6587\u30df\u30b9<\/li>\n<li><strong>nativeQuery<\/strong>\u306e\u8fd4\u5374\u578b\u4e0d\u4e00\u81f4<\/li>\n<li><strong>@Transactional<\/strong>\u306e\u4ed8\u3051\u5fd8\u308c<\/li>\n<\/ul>\n<p>\u3053\u308c\u3089\u306f\u300c\u52d5\u304f\u3051\u3069\u7f8e\u3057\u304f\u306a\u3044\u300d\u30b3\u30fc\u30c9\u306e\u4ee3\u8868\u4f8b\u3067\u3059\u3002 \u8a2d\u8a08\u6bb5\u968e\u3067\u30ec\u30d3\u30e5\u30fc\u3092\u884c\u3044\u3001\u65e9\u671f\u306b\u9632\u304e\u307e\u3057\u3087\u3046\u3002<\/p>\n<p>\uff08NullPointerException\u306e\u539f\u56e0\u3068\u5bfe\u7b56\u306b\u3064\u3044\u3066\u306f\u300e<a href=\"https:\/\/route-zero.com\/recruit\/route\/1624\/\">Spring Boot NullPointerException\u5b8c\u5168\u5bfe\u7b56\uff5c3\u5927\u539f\u56e0\u3068\u5b9f\u88c5\u4f8b\u307e\u3068\u3081<\/a>\u300f\u3092\u3054\u53c2\u7167\u304f\u3060\u3055\u3044\uff09<\/p>\n<hr \/>\n<h2>Repository\u306e\u30c6\u30b9\u30c8\u6226\u7565\u3068\u30d1\u30d5\u30a9\u30fc\u30de\u30f3\u30b9\u6700\u9069\u5316<\/h2>\n<h3>\u30c6\u30b9\u30c8\u30b3\u30fc\u30c9\u4f8b<\/h3>\n<pre><code>@DataJpaTest\r\npublic class UserRepositoryTest {\r\n    @Autowired\r\n    private UserRepository userRepository;\r\n\r\n    @Test\r\n    public void testFindByStatus() {\r\n        List&lt;User&gt; users = userRepository.findByStatus(\"ACTIVE\");\r\n        assertEquals(2, users.size());\r\n    }\r\n}\r\n<\/code><\/pre>\n<p>\u30c6\u30b9\u30c8\u3067<strong>nativeQuery<\/strong>\u3084<strong>@Query<\/strong>\u306e\u52d5\u4f5c\u3092\u691c\u8a3c\u3057\u3001 \u30d0\u30b0\u306e\u65e9\u671f\u767a\u898b\u306b\u3064\u306a\u3052\u307e\u3059\u3002<\/p>\n<h3>\u30d1\u30d5\u30a9\u30fc\u30de\u30f3\u30b9\u6539\u5584\u306e\u30d9\u30b9\u30c8\u30d7\u30e9\u30af\u30c6\u30a3\u30b9<\/h3>\n<ul>\n<li>\u30a4\u30f3\u30c7\u30c3\u30af\u30b9\u8a2d\u8a08\u306e\u6700\u9069\u5316<\/li>\n<li>\u30d0\u30c3\u30c1\u51e6\u7406\u306e\u6d3b\u7528<\/li>\n<li>\u4e0d\u8981\u306aSELECT\u306e\u6392\u9664<\/li>\n<li>\u30ad\u30e3\u30c3\u30b7\u30e5\u6226\u7565\u306e\u5c0e\u5165<\/li>\n<\/ul>\n<p>\n    \u8a2d\u8a08\u6bb5\u968e\u304b\u3089\u30d1\u30d5\u30a9\u30fc\u30de\u30f3\u30b9\u3092\u610f\u8b58\u3057\u3001\u516c\u5f0f\u30ac\u30a4\u30c9\u3092\u6d3b\u7528\u3057\u307e\u3057\u3087\u3046\u3002<br \/>\n    \u3010\u51fa\u5178\uff1a<a href=\"https:\/\/www.baeldung.com\/spring-data-jpa-performance\">Baeldung: Spring Data JPA Performance<\/a>\u3011 <br \/>\uff08Spring Boot\u3067List\u66f4\u65b0\u3059\u308b\u65b9\u6cd5\u306b\u3064\u3044\u3066\u306f\u300e<a href=\"https:\/\/route-zero.com\/recruit\/route\/1621\/\">Spring Boot\u3067List\u66f4\u65b0\u3059\u308b\u65b9\u6cd5\uff5cfor\u6587\u30fbStream\u30fbsave\/saveAll\u306e\u9055\u3044\u3092\u5fb9\u5e95\u89e3\u8aac<\/a\n    >\u300f\u3092\u3054\u53c2\u7167\u304f\u3060\u3055\u3044\uff09\n  <\/p>\n<blockquote>\n<p>\n      <strong>\u7528\u8a9e\u89e3\u8aac\uff1a\u30a4\u30f3\u30c7\u30c3\u30af\u30b9 \/ \u30ad\u30e3\u30c3\u30b7\u30e5<\/strong><br \/>\n      <strong>\u30a4\u30f3\u30c7\u30c3\u30af\u30b9<\/strong>\u306f\u691c\u7d22\u3092\u9ad8\u901f\u5316\u3057\u3001<strong>\u30ad\u30e3\u30c3\u30b7\u30e5<\/strong>\u306f\u30c7\u30fc\u30bf\u518d\u5229\u7528\u3067\u30ec\u30b9\u30dd\u30f3\u30b9\u3092\u5411\u4e0a\u3055\u305b\u307e\u3059\u3002\n    <\/p>\n<\/blockquote>\n<hr \/>\n<h2>\u307e\u3068\u3081<\/h2>\n<p><strong>Spring Boot Repository<\/strong>\u306f\u3001 <strong>JPA<\/strong>\u306e\u62bd\u8c61\u5316\u3068<strong>nativeQuery<\/strong>\u306e\u67d4\u8edf\u6027\u3092\u4e21\u7acb\u3055\u305b\u308b\u4e2d\u6838\u6280\u8853\u3067\u3059\u3002<\/p>\n<p>\u4e3b\u8981\u30a2\u30ce\u30c6\u30fc\u30b7\u30e7\u30f3\uff08<strong>@Entity<\/strong>, <strong>@Query<\/strong>, <strong>@Modifying<\/strong>, <strong>@Transactional<\/strong>\uff09\u3092\u6b63\u3057\u304f\u4f7f\u3044\u5206\u3051\u308b\u3053\u3068\u3067\u3001 \u4fdd\u5b88\u6027\u30fb\u518d\u73fe\u6027\u30fb\u30d1\u30d5\u30a9\u30fc\u30de\u30f3\u30b9\u3092\u5411\u4e0a\u3055\u305b\u3089\u308c\u307e\u3059\u3002<\/p>\n<p>\n    \u305c\u3072\u3053\u306e\u8a18\u4e8b\u3092\u53c2\u8003\u306b\u3001\u624b\u5143\u306e\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u3067\u8a66\u3057\u3066\u307f\u3066\u304f\u3060\u3055\u3044\u3002<br \/>\n    \u5c0f\u3055\u306a\u5b9f\u8df5\u306e\u7a4d\u307f\u91cd\u306d\u304c\u3001\u5805\u7262\u306a\u30a2\u30d7\u30ea\u8a2d\u8a08\u306b\u3064\u306a\u304c\u308a\u307e\u3059\u3002\n  <\/p>\n<\/div>\n","protected":false},"featured_media":1672,"template":"","_links":{"self":[{"href":"https:\/\/route-zero.com\/recruit\/wp-json\/wp\/v2\/route\/1670"}],"collection":[{"href":"https:\/\/route-zero.com\/recruit\/wp-json\/wp\/v2\/route"}],"about":[{"href":"https:\/\/route-zero.com\/recruit\/wp-json\/wp\/v2\/types\/route"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/route-zero.com\/recruit\/wp-json\/wp\/v2\/media\/1672"}],"wp:attachment":[{"href":"https:\/\/route-zero.com\/recruit\/wp-json\/wp\/v2\/media?parent=1670"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}