|
129 | 129 | import static org.hibernate.type.descriptor.DateTimeUtils.appendAsTimestampWithMillis; |
130 | 130 |
|
131 | 131 | /** |
132 | | - * A dialect for Microsoft SQL Server 2012 and above. |
| 132 | + * A dialect for Microsoft SQL Server 2016 and above. |
133 | 133 | * <p> |
134 | 134 | * Please refer to the |
135 | 135 | * <a href="https://learn.microsoft.com/en-us/sql/t-sql/language-reference">SQL Server documentation</a>. |
136 | 136 | * |
137 | 137 | * @author Gavin King |
138 | 138 | */ |
139 | 139 | public class SQLServerDialect extends AbstractTransactSQLDialect { |
140 | | - private final static DatabaseVersion MINIMUM_VERSION = DatabaseVersion.make( 11, 0 ); |
| 140 | + private final static DatabaseVersion MINIMUM_VERSION = DatabaseVersion.make( 13, 0 ); |
141 | 141 |
|
142 | 142 | /** |
143 | 143 | * NOTE : 2100 is the documented limit supposedly - but in my testing, sending |
@@ -445,20 +445,19 @@ public void initializeFunctionRegistry(FunctionContributions functionContributio |
445 | 445 | functionFactory.windowFunctions(); |
446 | 446 | functionFactory.inverseDistributionOrderedSetAggregates_windowEmulation(); |
447 | 447 | functionFactory.hypotheticalOrderedSetAggregates_windowEmulation(); |
448 | | - if ( getVersion().isSameOrAfter( 13 ) ) { |
449 | | - functionFactory.jsonValue_sqlserver(); |
450 | | - functionFactory.jsonQuery_sqlserver(); |
451 | | - functionFactory.jsonExists_sqlserver( getVersion().isSameOrAfter( 16 ) ); |
452 | | - functionFactory.jsonObject_sqlserver( getVersion().isSameOrAfter( 16 ) ); |
453 | | - functionFactory.jsonArray_sqlserver( getVersion().isSameOrAfter( 16 ) ); |
454 | | - functionFactory.jsonSet_sqlserver(); |
455 | | - functionFactory.jsonRemove_sqlserver(); |
456 | | - functionFactory.jsonReplace_sqlserver( getVersion().isSameOrAfter( 16 ) ); |
457 | | - functionFactory.jsonInsert_sqlserver( getVersion().isSameOrAfter( 16 ) ); |
458 | | - functionFactory.jsonArrayAppend_sqlserver( getVersion().isSameOrAfter( 16 ) ); |
459 | | - functionFactory.jsonArrayInsert_sqlserver(); |
460 | | - functionFactory.jsonTable_sqlserver(); |
461 | | - } |
| 448 | + functionFactory.jsonValue_sqlserver(); |
| 449 | + functionFactory.jsonQuery_sqlserver(); |
| 450 | + functionFactory.jsonExists_sqlserver( getVersion().isSameOrAfter( 16 ) ); |
| 451 | + functionFactory.jsonObject_sqlserver( getVersion().isSameOrAfter( 16 ) ); |
| 452 | + functionFactory.jsonArray_sqlserver( getVersion().isSameOrAfter( 16 ) ); |
| 453 | + functionFactory.jsonSet_sqlserver(); |
| 454 | + functionFactory.jsonRemove_sqlserver(); |
| 455 | + functionFactory.jsonReplace_sqlserver( getVersion().isSameOrAfter( 16 ) ); |
| 456 | + functionFactory.jsonInsert_sqlserver( getVersion().isSameOrAfter( 16 ) ); |
| 457 | + functionFactory.jsonArrayAppend_sqlserver( getVersion().isSameOrAfter( 16 ) ); |
| 458 | + functionFactory.jsonArrayInsert_sqlserver(); |
| 459 | + functionFactory.jsonTable_sqlserver(); |
| 460 | + |
462 | 461 | functionFactory.xmlelement_sqlserver(); |
463 | 462 | functionFactory.xmlcomment_sqlserver(); |
464 | 463 | functionFactory.xmlforest_sqlserver(); |
|
0 commit comments