Commit Graph

281 Commits (2e4f22e30d0dbcecc030efb6c14a9b3fc0eb05e3)

Author SHA1 Message Date
Christopher Jolly 2f69290f44 Generate proper SQL for UPDATE and DELETE when we have multiple tables, select expression, joins 2 years ago
Christopher Jolly 21b07705ce Return empty list for state indices when having parsed an empty string 2 years ago
Christopher Jolly 559cdc6d3c Some updates to the migration/update sql. Main change is if we are doing an INSERT, if there is no values to be read back we don't have to follow it up with a 'SELECT @@ROWCOUNT' 2 years ago
Christopher Jolly c73f4a3013 Add the onDelete convention so that we match the behaviour of sql server when configuring self-referencing skip navigations. Ends up configured as ClientCascade instead of Cascade 2 years ago
Christopher Jolly 6fe74929cf Remove tag lines/comments from the sql to be executed 2 years ago
Christopher Jolly 4bdd001eda Add the default warning config in. Some of the defaults set warnings to throw instead of Log 2 years ago
Christopher Jolly caeb6db77b
Lift subqueries from the ORDER BY clause into their own projection (#173)
* Lift scalar subqueries out of order by and into a projection

* Add back in missed verifier for skip without order by in split query

* [GitHub Actions] Update green tests.

* Scalar expressions within a function or case expression, within the ORDER BY also need to be lifted

* [GitHub Actions] Update green tests.

---------

Co-authored-by: github-actions <github-actions@github.com>
2 years ago
Christopher Jolly 7caea4dcdb
Provide a valid count argument to LEFT,RIGHT,MID (#172)
* Coalesce the result of LEN on a string to 0 when within a LEFT/RIGHT/MID function as it cannot take NULL for the count of characters
2 years ago
Christopher Jolly d9f2c8eb2c
Interception tests (#171)
* Allow unconfigured dataaccessproviderfactory and null connection string

* [GitHub Actions] Update green tests.

---------
2 years ago
Christopher Jolly b389b88705
Further built in types fixes (#170) 2 years ago
Christopher Jolly 6ccebae028
Db model factory updates (#166) 2 years ago
Laurents Meyer a95017e38b
Auto skip statements that are not supported by Jet. Track unsupported statements in log files. (#169) 2 years ago
Christopher Jolly e70f682c0c
Fix BuiltInDataTypes tests (#163)
* Update the BuiltInDataTypes set of tests

* Update JetTypeMappingSource.cs

Add back `alphanumeric` as its line somehow got deleted

* Add Element Type Mapping check back in
2 years ago
Laurents Meyer 2e23e60dad Remove duplicate string entry. 2 years ago
Christopher Jolly fcb97a4e63
Improve support for primitive collections and Json Types (#159) 2 years ago
Laurents Meyer d32eae0867
Update project in regards to new organization and CI. (#160) 2 years ago
Laurents Meyer 9babf78263
Revert "Type MApping: a long gets mapped to integer in Jet" (#151)
This reverts commit 05b10ea856.
2 years ago
Christopher Jolly 0d5676a4e5
Merge pull request #158 from ChrisJollyAU/fixdecint64param
Fix using decimal and Int64 in parameters
2 years ago
Christopher Jolly d359492662 Use reflection so we don't have to reference Odbc or OleDb in main package 2 years ago
Christopher Jolly 8c64a29730 Fix using decimal and Int64 in parameters 2 years ago
Laurents Meyer 43d0002123 Fix automatic test skipping. 2 years ago
Laurents Meyer ca8472c96e Fix ExecuteNonQuery() return value logic to be case sensitivity proof. 2 years ago
Christopher Jolly b4c07a382c Merge branch 'master' of https://github.com/bubibubi/EntityFrameworkCore.Jet 2 years ago
Christopher Jolly 67f98ee8ac More test updates 2 years ago
Laurents Meyer 7bc7ee3708
Revert pull-in of GearsOfWar related classes and remove constraint (#145)
* Revert pull-in of GearsOfWar related classes.

* Clean-up GearsOfWar fixtures.

* Drop constraint to workaround Jet limitation regarding compound foreign keys and NULL.

* Fix SQL assertions.

* Revert "Add code to add a "MatchSimple" annotation to a foreign key", because it doesn't do anything at the moment.

This reverts commit 76408338e0.
2 years ago
Christopher Jolly 0ddfe1ce3b Update to .Net 8 RC2 2 years ago
Christopher Jolly 331da3810e Forgot the case of the parameter having NullTypeMapping. In that case go with adding the conversion 2 years ago
Christopher Jolly 6f31403f13 Merge branch 'master' of https://github.com/bubibubi/EntityFrameworkCore.Jet 2 years ago
Christopher Jolly a16569f65b Add some further testbases 2 years ago
Christopher Jolly ed50bb0dfa Only add the date conversion if the type mapping is also a datetime 2 years ago
Laurents Meyer f086526d02
Fix and update dependencies and project files. (#144) 2 years ago
Christopher Jolly 01775d1b2f Implement Degrees to Radians and Radians to Degrees by first principal as there is no inbulilt function. Thankfully it is not a difficult calculation 2 years ago
Christopher Jolly bb90784c11 If we can get a numeric out of the ComputedColumnSql string then we know it is a numeric constant. We can transfer that to DefaultValue in this case 2 years ago
Christopher Jolly a6d9058c05 Some date and time updates
- Don't derive Timespan and DateTimeOffset type mapping from our JetDateTimeTypeMapping. We can derive from the normal base class for those types
- DateTimeOffset is now mapped to a string. This allows us to round-trip all the details, however any calculations or queries for any components do not work
2 years ago
Christopher Jolly 0d4f61e3fd The dateAdd function can not take null for the amount to add. Coalesce to 0 2 years ago
Christopher Jolly 80973bb3c8 When generating the SELECT, to select the values of the newly inserted row we only are able to use the first key column with @@identity 2 years ago
Christopher Jolly 08718b8165 Convert a null constant in a projection to a variant. We only do this if the type is meant to be a numeric. This is because NULL on its own has some issues when unioning with int values. Some joins with this issue were fixed in an earlier commit 2 years ago
Christopher Jolly 4fc2cb55b7 Extract column expression from UnaryExpression as well 2 years ago
Christopher Jolly ab3449349f No need to wrap an expression in a CaseExpression (generating IIF...) if the expression we are meant to be checking is a non-null constant expression 2 years ago
Christopher Jolly c1d263aedc Initial support for DateOnly/TimeOnly 2 years ago
Christopher Jolly ba913012ce The default value for DateTime in Jet is 30/12/1899 . When we save if we get a 1/1/001 we translate to this value. When reading we need to do the reverse translation 2 years ago
Christopher Jolly 76408338e0 Add code to add a "MatchSimple" annotation to a foreign key 2 years ago
Christopher Jolly 5b591b73fd UNIONing projection with a numeric column to another projection that specifically projects NULL the the same name as a numeric field, the JOINING that to another table can leave that numeric field as another data type (NULL is not a numeric data type). Hence when using that supposedly numeric field in the join predicat against another numeric field we get a data type mismatch.
We try to detect this and when visiting the column (but only if we are within a binary expression and not a projection) we quickly wrap it in a convert function to make it properly numeric

The top/outer projection of this field can still be in a non numeric format, but JetDataReader is able to handle that. Would be better to produce the correctly converted data output anyway
2 years ago
Christopher Jolly cae7f8372b Add Check_all_tests_overridden to more test classes and ensure that it passes 2 years ago
Christopher Jolly 3191ca6851 Fix some conversion errors when getting a numeric value. See detailed notes in the GetInt32 function 2 years ago
Christopher Jolly a594e2f81f DISTINCT AND TOP can't be in the same stateement with Jet. Push DISTINCT into a subquery 2 years ago
Christopher Jolly 2281916b88 Fix generating sets (union, intersect). The code was originally executing and returning before it could handle adding the SQL for the Alias in (including wrapping the section in brackets). This realigns with how the parent VisitSelect works 2 years ago
Christopher Jolly a2dc62d12d Fix the formatting for a string literal of a byte 2 years ago
Christopher Jolly 1090ee3b8f Make sure the start index for Instr is set. Normally is optional but it seems some sections seem to prefer it to be defined 2 years ago
Christopher Jolly 34f124c0f8 Update to .Net 8 2 years ago