在Repositories中的Rest Spring API中,我需要通過三個參數來查找值,但這是phone,password,找到delete = 0。我已經將它添加到實體,但它顯示錯誤無效的派生查詢!找不到類型爲CustomerEntity的屬性!兩個現場工作正常,但刪除的工作不Spring Rest Repository Error
@Repository
public interface CustomerRepository extends JpaRepository<CustomerEntity, Long> {
CustomerEntity findByfacebookID(String facebookID);
CustomerEntity findByPhoneAndPasswordAndIsDeleted(String phone, String password, Boolean isdeleted);
實體
@Entity
@Table(name = "CUSTOMER")
public class CustomerEntity {
@Column(name = "IS_DELETED", length = 3, nullable = false)
private Boolean isdeleted;
爲什麼你在屬性名稱中有一個空格?完全在'私人布爾被刪除' – DevDio