diff --git a/pom.xml b/pom.xml
index 3d4491cc9..21ab38c57 100644
--- a/pom.xml
+++ b/pom.xml
@@ -55,7 +55,7 @@
hibernate-5
- 5.0.0.Beta2
+ 5.0.0.CR1
diff --git a/src/test/java/org/springframework/data/jpa/domain/sample/User.java b/src/test/java/org/springframework/data/jpa/domain/sample/User.java
index 962972c46..78fb72ab2 100644
--- a/src/test/java/org/springframework/data/jpa/domain/sample/User.java
+++ b/src/test/java/org/springframework/data/jpa/domain/sample/User.java
@@ -38,6 +38,7 @@ import javax.persistence.NamedStoredProcedureQueries;
import javax.persistence.NamedStoredProcedureQuery;
import javax.persistence.ParameterMode;
import javax.persistence.StoredProcedureParameter;
+import javax.persistence.Table;
import javax.persistence.Temporal;
import javax.persistence.TemporalType;
@@ -64,6 +65,7 @@ import javax.persistence.TemporalType;
@NamedStoredProcedureQuery(name = "User.plus1IO", procedureName = "plus1inout", parameters = {
@StoredProcedureParameter(mode = ParameterMode.IN, name = "arg", type = Integer.class),
@StoredProcedureParameter(mode = ParameterMode.OUT, name = "res", type = Integer.class) })
+@Table(name = "SD_User")
public class User {
@Id @GeneratedValue(strategy = GenerationType.AUTO) private Integer id;
diff --git a/src/test/java/org/springframework/data/jpa/repository/sample/UserRepository.java b/src/test/java/org/springframework/data/jpa/repository/sample/UserRepository.java
index 774b56a9e..3d968a27b 100644
--- a/src/test/java/org/springframework/data/jpa/repository/sample/UserRepository.java
+++ b/src/test/java/org/springframework/data/jpa/repository/sample/UserRepository.java
@@ -48,8 +48,8 @@ import com.google.common.base.Optional;
* @author Oliver Gierke
* @author Thomas Darimont
*/
-public interface UserRepository extends JpaRepository, JpaSpecificationExecutor,
- UserRepositoryCustom {
+public interface UserRepository
+ extends JpaRepository, JpaSpecificationExecutor, UserRepositoryCustom {
/**
* Retrieve users by their lastname. The finder {@literal User.findByLastname} is declared in
@@ -224,7 +224,7 @@ public interface UserRepository extends JpaRepository, JpaSpecifi
/**
* @see DATAJPA-117
*/
- @Query(value = "SELECT * FROM User WHERE lastname = ?1", nativeQuery = true)
+ @Query(value = "SELECT * FROM SD_User WHERE lastname = ?1", nativeQuery = true)
List findNativeByLastname(String lastname);
/**
@@ -268,7 +268,7 @@ public interface UserRepository extends JpaRepository, JpaSpecifi
*/
List findByFirstnameContaining(String firstname);
- @Query(value = "SELECT 1 FROM User", nativeQuery = true)
+ @Query(value = "SELECT 1 FROM SD_User", nativeQuery = true)
List findOnesByNativeQuery();
/**
@@ -460,7 +460,7 @@ public interface UserRepository extends JpaRepository, JpaSpecifi
/**
* @see DATAJPA-506
*/
- @Query(value = "select u.binaryData from User u where u.id = ?1", nativeQuery = true)
+ @Query(value = "select u.binaryData from SD_User u where u.id = ?1", nativeQuery = true)
byte[] findBinaryDataByIdNative(Integer id);
/**
@@ -533,8 +533,8 @@ public interface UserRepository extends JpaRepository, JpaSpecifi
* @see DATAJPA-564
*/
@Query(
- value = "select * from (select rownum() as RN, u.* from User u) where RN between ?#{ #pageable.offset -1} and ?#{#pageable.offset + #pageable.pageSize}",
- countQuery = "select count(u.id) from User u", nativeQuery = true)
+ value = "select * from (select rownum() as RN, u.* from SD_User u) where RN between ?#{ #pageable.offset -1} and ?#{#pageable.offset + #pageable.pageSize}",
+ countQuery = "select count(u.id) from SD_User u", nativeQuery = true)
Page findUsersInNativeQueryWithPagination(Pageable pageable);
/**