Author: stliu
Date: 2010-01-09 08:54:02 -0500 (Sat, 09 Jan 2010)
New Revision: 18474
Modified:
annotations/branches/v3_4_0_GA_CP/src/test/java/org/hibernate/test/annotations/collectionelement/Boy.java
annotations/branches/v3_4_0_GA_CP/src/test/java/org/hibernate/test/annotations/collectionelement/LocalizedString.java
annotations/branches/v3_4_0_GA_CP/src/test/java/org/hibernate/test/annotations/collectionelement/Matrix.java
Log:
JBPAPP-3375 HHH-4773 unit tests fail cos db2 doesn't allow primary key column
nullable
Modified:
annotations/branches/v3_4_0_GA_CP/src/test/java/org/hibernate/test/annotations/collectionelement/Boy.java
===================================================================
---
annotations/branches/v3_4_0_GA_CP/src/test/java/org/hibernate/test/annotations/collectionelement/Boy.java 2010-01-09
13:36:10 UTC (rev 18473)
+++
annotations/branches/v3_4_0_GA_CP/src/test/java/org/hibernate/test/annotations/collectionelement/Boy.java 2010-01-09
13:54:02 UTC (rev 18474)
@@ -19,6 +19,7 @@
import org.hibernate.annotations.CollectionOfElements;
import org.hibernate.annotations.IndexColumn;
+import org.hibernate.annotations.MapKey;
/**
* @author Emmanuel Bernard
@@ -74,7 +75,7 @@
public void setNickNames(Set<String> nickName) {
this.nickNames = nickName;
}
-
+ @MapKey(columns=@Column(nullable=false))
@CollectionOfElements
@JoinTable(name = "ScorePerNickName", joinColumns = @JoinColumn(name =
"BoyId"))
@Column(name = "score", nullable = false)
Modified:
annotations/branches/v3_4_0_GA_CP/src/test/java/org/hibernate/test/annotations/collectionelement/LocalizedString.java
===================================================================
---
annotations/branches/v3_4_0_GA_CP/src/test/java/org/hibernate/test/annotations/collectionelement/LocalizedString.java 2010-01-09
13:36:10 UTC (rev 18473)
+++
annotations/branches/v3_4_0_GA_CP/src/test/java/org/hibernate/test/annotations/collectionelement/LocalizedString.java 2010-01-09
13:54:02 UTC (rev 18474)
@@ -33,7 +33,7 @@
new HashMap<String, String>( 1 );
@CollectionOfElements
- @MapKey( columns = @Column( name = "language_code" ) )
+ @MapKey( columns = @Column( name = "language_code",nullable=false) )
@Fetch( FetchMode.JOIN )
@Filter( name = "selectedLocale",
condition = " language_code = :param " )
Modified:
annotations/branches/v3_4_0_GA_CP/src/test/java/org/hibernate/test/annotations/collectionelement/Matrix.java
===================================================================
---
annotations/branches/v3_4_0_GA_CP/src/test/java/org/hibernate/test/annotations/collectionelement/Matrix.java 2010-01-09
13:36:10 UTC (rev 18473)
+++
annotations/branches/v3_4_0_GA_CP/src/test/java/org/hibernate/test/annotations/collectionelement/Matrix.java 2010-01-09
13:54:02 UTC (rev 18474)
@@ -5,6 +5,7 @@
import java.util.SortedMap;
import java.util.TreeMap;
+import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
@@ -24,7 +25,7 @@
@GeneratedValue
private Integer id;
- @MapKey(type = @Type(type="integer") )
+ @MapKey(type =
@Type(type="integer"),columns=@Column(name="mapkey",nullable=false) )
@CollectionOfElements
@Sort(type = SortType.NATURAL)
@Type(type = "float")
Show replies by date