---
# System prepended metadata

title: Trouble shooting
tags: [Spring boot]

---

# Trouble shooting

1. Java JPA 报java.lang.IllegalArgumentException: Validation failed for query for method public abstract ...异常的一种原因和解决办法
>
JPA使用原生SQL语句时，需要nativeQuery = true
```java
@Query(value = "SELECT * FROM course", nativeQuery = true)
```
>
---
資料來源:
[ Java JPA報錯](https://www.cnblogs.com/codecat/p/12096717.html)
###### tags: `Spring boot`

