nkjackzhang
82cb5dbf2b
NamedParameterUtils.parseSqlStatement should parse :{x} style parameter correctly
...
In my opinion, we should parse ":{x}" style parameter as "x" is parameter using "NamedParameterUtils.parseSqlStatement",
so the condition "j - i > 2" is the correct condition, not "j - i > 3", because if "i" is the index of
":" in ":{x}", and "j" is the index of "}" in ":{x}", "j - i == 3" is true.
Also add a test case for SPR-16663.
2018-03-29 15:00:25 +02:00
Juergen Hoeller
b2d87abcbb
Polishing
2018-03-28 12:06:38 +02:00
Juergen Hoeller
e3d0ef6015
Use Map.forEach instead of manual Map.Entry iteration wherever possible
...
Issue: SPR-16646
2018-03-27 00:38:32 +02:00
Juergen Hoeller
c441d60d1d
Upgrade to Kotlin 1.2.31 and RxJava 2.1.12
...
Includes H2 1.4.197 and Selenium HtmlUnit Driver 2.29.3 as well.
2018-03-24 16:48:53 +01:00
Juergen Hoeller
702b27e1e4
Polishing
2018-03-19 12:05:04 +01:00
Juergen Hoeller
2c7efbb9d0
Deprecate TableMetaDataContext.getSimulationQueryForGetGeneratedKey
2018-03-19 12:04:51 +01:00
Juergen Hoeller
b7c423813d
CallMetaDataContext handles 'procedureColumnResult' as return parameter
...
Issue: SPR-16611
2018-03-19 12:04:15 +01:00
Juergen Hoeller
4fef1fe820
Polishing
2018-03-16 18:49:12 +01:00
igor-suhorukov
2f9d0a7de8
simplify boolean NOT operation
2018-03-08 23:44:15 +01:00
igor-suhorukov
32b689a994
use StringBuilder for complex string concatenation
2018-03-08 21:25:47 +01:00
igor-suhorukov
407ecf7334
to get rid of "magic" time constants
2018-03-08 20:37:48 +01:00
Juergen Hoeller
50253f670e
Quick access to volatile field (full synchronization only for lazy init)
...
Issue: SPR-16570
2018-03-08 18:13:00 +01:00
Juergen Hoeller
139dc1d373
Polishing (collapsed if checks, consistent downcasts, refined javadoc)
2018-03-08 18:11:57 +01:00
igor-suhorukov
0f7485b01d
Polish: reorder the modifiers to comply with the Java Language Specification.
2018-03-08 17:57:47 +01:00
Juergen Hoeller
20287e0cb0
Polishing
2018-03-07 17:09:09 +01:00
Juergen Hoeller
82515a3f01
Consistent incrementer arrangement for PostgreSQL, DB2 and SAP HANA
...
Includes related polishing in core.metadata and datasource.embedded and a revision of the corresponding database definitions in sql-error-codes.
Issue: SPR-16558
2018-03-06 13:36:15 +01:00
Juergen Hoeller
4a4f2c2f08
Drop version check in isGetGeneratedKeysSimulated (for PostgreSQL 10)
...
Issue: SPR-16556
2018-03-06 13:31:26 +01:00
igor-suhorukov
49fd724d8f
Polish: String function use should be optimized for single characters
2018-02-25 20:48:47 +01:00
Juergen Hoeller
3732032ee4
Customizable PreparedStatementCreator in NamedParameterJdbcTemplate
...
Issue: SPR-16050
2018-02-25 18:23:00 +01:00
igor-suhorukov
c782075a13
Polish: Array designators "[]" should be on the type, not the variable
2018-02-25 13:14:20 +01:00
Juergen Hoeller
a5cbf5fe24
Consistent use of Collection.toArray with zero-sized array argument
...
Includes consistent use of ClassUtils.toClassArray (as non-null variant)
Issue: SPR-16523
2018-02-22 11:29:46 +01:00
Juergen Hoeller
d7cab23e6d
Consistent use of StringUtils.toStringArray
...
(cherry picked from commit 6d11b40
)
2018-02-16 20:49:17 +01:00
Juergen Hoeller
8d3264f680
Prefer List.sort(Comparator) over Collections.sort(List, Comparator)
2018-02-16 10:23:18 +01:00
Juergen Hoeller
3b810f3544
Consistent Class array vs vararg declarations (and related polishing)
2018-02-14 14:44:00 +01:00
Juergen Hoeller
766e6028d7
Defensively handle DatabaseMetaData.getConnection() returning null
...
Issue: SPR-16495
2018-02-14 14:40:52 +01:00
Kazuki Shimizu
8c623c8a42
Supports ConversionService on SingleColumnRowMapper
...
Issue: SPR-16483
2018-02-11 22:36:50 +01:00
igor-suhorukov
0ee505b73e
Polish: assertion arguments should be passed in the correct order,
...
use assertNull instead of assertEquals(null, value),
declare delta as double value in assertEquals
2018-02-10 17:17:28 +01:00
igor-suhorukov
9a6fbf59c5
Polish: follow name convention - make immutable fields final
2018-02-10 12:09:19 +01:00
Juergen Hoeller
fc93f99f53
Relaxed procedure existence check on Oracle (for non-exposed synonyms)
...
Issue: SPR-16478
2018-02-09 13:30:31 +01:00
Stephane Nicoll
991eb4858e
Update copyright header
2018-02-09 10:16:58 +01:00
igor-suhorukov
e381514b07
Collection.isEmpty() should be used to test for emptiness
...
Closes gh-1670
2018-02-09 10:11:44 +01:00
Juergen Hoeller
ac7a699356
NamedParameterUtils.isParameterSeparator checks for non-ASCII characters
...
Issue: SPR-16472
2018-02-07 14:10:39 +01:00
Johnny Lim
df3241e072
Polish SqlParameter.sqlTypesToAnonymousParameterList()
...
Closes gh-1657
2018-02-01 09:14:56 +01:00
Juergen Hoeller
9d0e62ef68
Javadoc format and related polishing
2018-01-22 11:43:21 +01:00
Juergen Hoeller
572c668726
Polishing
2018-01-19 21:30:37 +01:00
Juergen Hoeller
44fd2d96cc
Restore original separator set (but keep new isParameterSeparator impl)
...
Issue: SPR-16340
2018-01-14 17:57:32 +01:00
Philippe Marschall
91e39d558f
Use ArrayList instead of LinkedList for known size
...
Spring JDBC unlike other modules uses LinkedList instead of ArrayList
in several places. There is a large body of evidence suggesting that on
contemporary hardware ArrayList is both faster and has less overhead
than even in degenerate cases of empty lists [3] or unknown size.
There are two places in Spring JDBC where the size of the list is known
in advance and an ArrayList of the correct final size can be created
[1] https://bugs.java.com/bugdatabase/view_bug.do?bug_id=8011200
[2] http://cliffc.org/blog/2017/11/05/modern-hardware-performance-cache-lines/
[3] https://bugs.openjdk.java.net/browse/JDK-8011200
Issue: SPR-16378
2018-01-14 17:45:32 +01:00
Juergen Hoeller
c8bdb3c602
Polishing
2018-01-09 22:20:22 +01:00
Juergen Hoeller
e43439c6c3
SqlParameterSource interface exposes parameter names
...
Includes default implementations of getSqlType and getTypeName.
Issue: SPR-16361
2018-01-09 22:19:46 +01:00
Juergen Hoeller
b2322e58d9
Support for PostgreSQL array syntax
...
Includes efficient separator determination.
Issue: SPR-16340
2018-01-09 22:19:05 +01:00
Christoph Dreis
260ebeca3a
Improve performance of some string operations
...
Issue: SPR-16293
2017-12-12 17:14:24 +01:00
Juergen Hoeller
b55a2631ba
NamedParameterJdbcTemplate provides accessor for classic JdbcTemplate
...
Issue: SPR-16241
2017-11-29 15:38:21 +01:00
Juergen Hoeller
b1c657fa4b
Consistent nullability in DataAccessUtils through nullableSingleResult
...
Issue: SPR-16225
2017-11-26 17:16:39 +01:00
sdeleuze
9f1d8517ba
Polish Kotlin source code style
2017-11-21 15:59:23 +01:00
Juergen Hoeller
a8b48848b9
SqlParameterSourceUtils.createBatch with Collection support
...
Issue: SPR-16215
2017-11-19 21:17:24 +01:00
benoit
667e0341fa
Improve memory allocations when substituting named parameters.
...
Create the buffer with at least the original sql length to avoid
multiple re-allocations
Add a fast path if the original sql doesn't contain any parameters
2017-11-08 23:45:53 +01:00
Juergen Hoeller
db050ac38c
Polishing
2017-11-04 01:07:09 +01:00
jmaxwell
e4c5b77de7
SPR-16154 - Correctly handle NVARCHAR, LONGNVARCHAR and NCLOBs
2017-11-03 14:49:32 -05:00
Juergen Hoeller
ee7b928300
Upgrade to Derby 10.14.1.0
2017-10-26 21:26:31 +02:00
Juergen Hoeller
75bd516251
Refined TemporaryLobCreator null handling (from 4.3.x)
...
Issue: SPR-15656
2017-09-27 15:40:13 +02:00