markrendle/Simple.Data — pull request #108 by richardhopton (2011-10-30 10:05:56+00:00)
Title: Issue 106

Resolves issue 106 as proposed in the issue text - this is needed for SqlServer and SqlAnywhere type inference.

This can be observed on HavingWithMinDateShouldReturnCorrectRow and HavingWithMaxDateShouldReturnCorrectRow where the DateTime value parameter is actually passed the DBMS as AnsiString:-

exec sp_executesql N'select [dbo].[GroupTestMaster].[Id],[dbo].[GroupTestMaster].[Name] from [dbo].[GroupTestMaster] JOIN [dbo].[GroupTestDetail] ON ([dbo].[GroupTestMaster].[Id] = [dbo].[GroupTestDetail].[MasterId]) GROUP BY [dbo].[GroupTestMaster].[Id],[dbo].[GroupTestMaster].[Name] HAVING Min([dbo].[GroupTestDetail].[Date]) >= @p1',N'@p1 varchar(19)',@p1='01/01/2000 00:00:00'