JPAについて JPAの参照系について getResultList()の検索件数0件のときはどんな動きになる? Size = 0のリストが帰ってくる感じです (nullじゃないので注意)。 entityの静的クエリはじぶんで追加してっていいんだよね? なんか、普通に追加したら not foudと言われてしまった…… @NamedQueries({ : @NamedQuery(name = "Customer.findByIdAndName", query = "SELECT c FROM Customer c WHERE c.customerId = :customerId AND c.name = :name")}) public class Customer implements Serializable { :
![JavaEE6をいじったときのメモ - Qiita](https://cdn-ak-scissors.b.st-hatena.com/image/square/1c2b410b91a210e4a08ebe0bbdd5b33328ca8ecd/height=288;version=1;width=512/https%3A%2F%2Fqiita-user-contents.imgix.net%2Fhttps%253A%252F%252Fcdn.qiita.com%252Fassets%252Fpublic%252Farticle-ogp-background-412672c5f0600ab9a64263b751f1bc81.png%3Fixlib%3Drb-4.0.0%26w%3D1200%26mark64%3DaHR0cHM6Ly9xaWl0YS11c2VyLWNvbnRlbnRzLmltZ2l4Lm5ldC9-dGV4dD9peGxpYj1yYi00LjAuMCZ3PTk3MiZoPTM3OCZ0eHQ9SmF2YUVFNiVFMyU4MiU5MiVFMyU4MSU4NCVFMyU4MSU5OCVFMyU4MSVBMyVFMyU4MSU5RiVFMyU4MSVBOCVFMyU4MSU4RCVFMyU4MSVBRSVFMyU4MyVBMSVFMyU4MyVBMiZ0eHQtYWxpZ249bGVmdCUyQ3RvcCZ0eHQtY29sb3I9JTIzMjEyMTIxJnR4dC1mb250PUhpcmFnaW5vJTIwU2FucyUyMFc2JnR4dC1zaXplPTU2JnM9NzlkMmRkY2QxNWFlMzExMTU4YjBkNGY2YWVjZTY1ZDc%26mark-x%3D142%26mark-y%3D57%26blend64%3DaHR0cHM6Ly9xaWl0YS11c2VyLWNvbnRlbnRzLmltZ2l4Lm5ldC9-dGV4dD9peGxpYj1yYi00LjAuMCZoPTc2Jnc9NzcwJnR4dD0lNDB5dWl6aG8mdHh0LWNvbG9yPSUyMzIxMjEyMSZ0eHQtZm9udD1IaXJhZ2lubyUyMFNhbnMlMjBXNiZ0eHQtc2l6ZT0zNiZ0eHQtYWxpZ249bGVmdCUyQ3RvcCZzPTY0MTdjYWYyZDFjOTIxNTZiODJjMTAzMjY4ZjFmMjhm%26blend-x%3D142%26blend-y%3D486%26blend-mode%3Dnormal%26s%3Dd9f1d60e135643e11f900071f69638af)