Commit Graph

464 Commits (e7539ef509626cae4e323b7f01a5caa92b154e90)
 

Author SHA1 Message Date
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 2155c12963 Update branding to 8.0.0-alpha.2. 2 years ago
Laurents Meyer 914bd5a2ee Fix namespace. 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 009b9de606 Add some further test classes that JetComplianceTest is not finding implemented 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 1df474d720 Some minor test fixups 2 years ago
Christopher Jolly cd320052ce Update tests 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 2b937ef4ae Do not compare the Timeline property when checking if Mission is equal. This is a DateTimeOffset and we currently don't have good round-trip support for this type without losing info 2 years ago
Christopher Jolly b1bffdff8c Update tests 2 years ago
Christopher Jolly 352734a537 Update the base Gears of War to be synced with .Net RC1 2 years ago
Christopher Jolly 0211d16ea1 Update some tests due to .Net 8 changing the order of certain phrases 2 years ago
Christopher Jolly 02886b2570 Add our own GearsOfWar set of base classes and models. This allows us to modify it so that we can work around the complex/multi-field foreign key set up it uses so that we can use our own Match Simple mode rather than the Match Full mode Jet normally does.
See the readme in the CustomBaseTests for full details
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 d78256f53d update tests 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
Christopher Jolly 6f38fe6e90 Update tests 2 years ago
Christopher Jolly db7a513b64 Remove the DeepSkip tag on FirstOrDefault. When generating the sql it was preventing the TOP expression from being generated 2 years ago
Christopher Jolly fbf0f794a7 use .GetMAppStoreObjects to try get the correct table (this is especially needed for properties in split tables). Default to the original storeObject if can't find anything 2 years ago
Christopher Jolly 9e6617903f v7.0.3 2 years ago
Christopher Jolly 3ff59259ed Use the correct function in SQL for Date (Jet doesn't do GetUTCDate) 2 years ago
Christopher Jolly 2dbd0fde32 Rewrite some INNER JOIN's. According to the docs Jet doesn't support an INNER JOIN being nested under a LEFT JOIN. We try to figure out which one's they are and rewrite it. As an INNER JOIN is a join where both sides have a value, we can rewrite it as a LEFT JOIN and then filter out the rows where the columns the join is on is not NULL 2 years ago
Christopher Jolly 83b0bea0b8 another test update 2 years ago
Christopher Jolly 78f9226030 Update tests 2 years ago
Christopher Jolly c46f980c09 Start work on some support for sequence value generation. Still under investigation if possible 2 years ago
Christopher Jolly 7cee2d0581 update dependencies 2 years ago
Christopher Jolly 673e56ed60 Add a whole heap of new tests. Work to implement all the test bases so that All_test_bases_must_be_implemented can pass 2 years ago
Christopher Jolly 944843bfad Some datetime parameters don't work unless they have been properly converted 2 years ago
Christopher Jolly 70af0c286c Set query splitting behaviour. Prevents errors due to it not being set 2 years ago
Christopher Jolly 629398c76b Set CanExecuteQueryString to false. When running tests, if it is set to true, the Query Asserter will also try to create a query string from the IQueryable. While most cases are fine, the problem comes in when there are parameters. Creating the query string declares the parameters and values at the beginning of the query and the DbCommand is set up with no parameters. While this can work in Sql Server (see the DECLARE keyword), this is not supported with Jet.
The Query Asserter already runs the CreateDbCommand on the IQueryable which creates the DbCommand with the parameters all set up. Creating the query string and running that as a separate command is not really necessary.

By the looks of it this only affects the test system which specifically creates a query string from an IQueryable and creates a new DbCommand with that as the command text. It doesn't seem to affect anywhere else
2 years ago
Christopher Jolly 3ef1503bb9 Translate the Atan2 function 2 years ago
Christopher Jolly 5e32650f6d Dispose of any new JetCommands created when splitting commands properly. This were not being disposed of and still holding a link to the database thereby preventing some file access e.g. Deleting a file 2 years ago
Christopher Jolly 424c9fc8f3 Update dependencies 2 years ago