Commit Graph

18 Commits

Author SHA1 Message Date
dan
9f3e6fadde Handle blobs that are the return values of functions being cast to text in utf16 databases in the same way as blobs read directly from the database. Fix for [771fe617].
FossilOrigin-Name: e782096aa06fcf410c3a0a6ee26a9e4f44333da39b28b2efe675814a8652911a
2020-01-02 16:24:22 +00:00
drh
0ce974d122 Adjust requirements marks and add new requirements tests.
FossilOrigin-Name: ebb81dad1f43dac4636cd44d4055d1d4b198c675f73e23c5a2d8d992ae27fe1f
2019-06-12 22:46:04 +00:00
drh
13d0402077 As a special case, casting '-0.0' into numeric should yield 0.
Fix for ticket [674385aeba91c774].

FossilOrigin-Name: 491f0f9bbddb6302536d99abd1ea481fd747ddcf6c6eaaacc0338d147b119081
2019-06-12 20:51:38 +00:00
drh
378a7d356b A string consisting of a single '.' is not a floating point literal with extra
text at the end.  Fix for ticket [412bba9b22c677da]

FossilOrigin-Name: 57050162294efec90caa5cc3c2f8c1a85215526adcf57b284ce2d2e799286b78
2019-06-10 23:45:10 +00:00
drh
c285ded26c Make sure a CAST to "NUMERIC" results in an integer if the value can be
losslessly expressed as an integer, as the documentation requires.
Ticket [dd6bffbfb6e61db9].

FossilOrigin-Name: c0c90961b4fa1c1185772d04fe1915bc1a1af27ed8ddb8db1c524bf90d68ccbf
2019-06-10 18:33:16 +00:00
drh
9a2782293c When casting string values into numeric and the string has a prefix that looks
like a number but total string is not a well-formed number, then take extra
care that the result is either integer or real depending on what the prefix
looks like.  Fix for tickets [e8bedb2a184001] and [4c2d7639f076aa].

FossilOrigin-Name: 67a68af5578f08d2be2e48cf4fd12a6cf35a09c47d259deda81950f7ee1f02f7
2019-06-07 22:26:08 +00:00
drh
4eb57ceffc Improve text-to-integer conversion in boundary cases. The
sqlite3Atoi64() function always returns the minimum or maximum integer
if the magnitude of the text value is too large.  Trailing whitespace is
now ignored.

FossilOrigin-Name: ace0644a1a2a42a3ea42d44f00a31915b8a7e56c9ba90f90a6c02001f89f9c86
2018-01-26 18:37:34 +00:00
dan
33f5379c43 Changes to various test scripts so that they pass on windows.
FossilOrigin-Name: 1586244b6d86d5a98af8c6f7a8324672e02df9c3
2011-05-05 19:44:22 +00:00
drh
1735fa8892 Fix a bug in the CAST operator associated with the column cache. (CVS 5866)
FossilOrigin-Name: 1b6a5140446da896f69fddc8d1ea076815bb45e3
2008-11-06 15:33:03 +00:00
drh
91fd4d46ad Miscellaneous code simplifications and cleanup and test coverage
enhancements. (CVS 4730)

FossilOrigin-Name: af129b6d158cc90ce9752dd6383c1de47f7b3e43
2008-01-19 20:11:25 +00:00
drh
a7fba4b055 Disable tests that require 80-bit long doubles when the host only
provides 64-bit long doubles.  Ticket #2570. (CVS 4215)

FossilOrigin-Name: 4f4f8ef416394b7e54e8894f7a0d067d64636fc4
2007-08-13 15:18:27 +00:00
danielk1977
5b159dc312 Fix a problem with casting blobs to numeric types. (CVS 4021)
FossilOrigin-Name: f2ce727c4d798c666e95876a2b67e8a305d82e3a
2007-05-17 16:34:43 +00:00
drh
cd7b46db84 Keep the full precision of integers if possible when casting to "numeric".
Ticket #2364. (CVS 4012)

FossilOrigin-Name: 2ac985a38034da87b0fa3837976e1f2164b22672
2007-05-16 11:55:56 +00:00
drh
57bacb2282 Ignore leading spaces on text to numeric conversions. Ticket #1662.
Fixes to test cases broken by the recent changes to round(). (CVS 3118)

FossilOrigin-Name: cdca3383c54b33aeafbbdbbb4ae7c90796cf66e5
2006-03-03 19:12:29 +00:00
danielk1977
ff890793fc Test file fixes for libaries compiled with various SQLITE_OMIT_ macros. (CVS 2961)
FossilOrigin-Name: c058f483a52c8043178b6329aa5e58bedf0c8277
2006-01-16 16:24:25 +00:00
drh
8df447f0e6 Omit the SQLITE_AFF_INTEGER type affinity. All numeric values are now
of type real, though an integer representation is still sometimes used
internally for efficiency. (CVS 2753)

FossilOrigin-Name: e0d6f61c7de2c03b8fd17ef37cf1a0add36ee618
2005-11-01 15:48:24 +00:00
drh
df0bddaef3 The TCL interface binds variables as BLOB only if they have a bytearray
representation but no text representation. Ticket #1287. (CVS 2528)

FossilOrigin-Name: 8c99dca60aebee0ec5de9ed11350de864bc76584
2005-06-25 19:31:48 +00:00
drh
487e262f44 Remove the blob(), text() and numeric() functions added in (2524) and
replace them with the standard CAST operator.
Ticket #1287. (CVS 2527)

FossilOrigin-Name: 17631785f9ee8ab280c82677eb53886912e085bc
2005-06-25 18:42:14 +00:00