HHH-10183 - Mapping for NVARCHAR in SqlServer not working with native queries; org.hibernate.MappingException: No Dialect mapping for JDBC type: -9
This commit is contained in:
parent
34d92507c9
commit
0693b54256
|
@ -229,6 +229,7 @@ public abstract class Dialect implements ConversionContext {
|
|||
registerHibernateType( Types.TIME, StandardBasicTypes.TIME.getName() );
|
||||
registerHibernateType( Types.TIMESTAMP, StandardBasicTypes.TIMESTAMP.getName() );
|
||||
registerHibernateType( Types.VARCHAR, StandardBasicTypes.STRING.getName() );
|
||||
registerHibernateType( Types.NVARCHAR, StandardBasicTypes.NSTRING.getName() );
|
||||
registerHibernateType( Types.VARBINARY, StandardBasicTypes.BINARY.getName() );
|
||||
registerHibernateType( Types.LONGVARCHAR, StandardBasicTypes.TEXT.getName() );
|
||||
registerHibernateType( Types.LONGVARBINARY, StandardBasicTypes.IMAGE.getName() );
|
||||
|
|
|
@ -127,6 +127,11 @@ public final class StandardBasicTypes {
|
|||
*/
|
||||
public static final StringType STRING = StringType.INSTANCE;
|
||||
|
||||
/**
|
||||
* The standard Hibernate type for mapping {@link String} to JDBC {@link java.sql.Types#NVARCHAR NVARCHAR}
|
||||
*/
|
||||
public static final StringNVarcharType NSTRING = StringNVarcharType.INSTANCE;
|
||||
|
||||
/**
|
||||
* The standard Hibernate type for mapping {@link java.net.URL} to JDBC {@link java.sql.Types#VARCHAR VARCHAR}.
|
||||
*
|
||||
|
|
|
@ -15,7 +15,6 @@ import javax.persistence.Table;
|
|||
import org.hibernate.annotations.Nationalized;
|
||||
import org.hibernate.dialect.SQLServer2008Dialect;
|
||||
|
||||
import org.hibernate.testing.FailureExpected;
|
||||
import org.hibernate.testing.RequiresDialect;
|
||||
import org.hibernate.testing.TestForIssue;
|
||||
import org.hibernate.testing.junit4.BaseCoreFunctionalTestCase;
|
||||
|
@ -37,7 +36,6 @@ public class NationalizedScalarQueryTest extends BaseCoreFunctionalTestCase {
|
|||
}
|
||||
|
||||
@Test
|
||||
@FailureExpected(jiraKey = "HHH-10183")
|
||||
public void testScalarResult() {
|
||||
|
||||
User user1 = new User( 1, "Chris" );
|
||||
|
|
Loading…
Reference in New Issue