Saturday, December 12, 2009

This is our final release for ES2009, the version number is 2009.2.1214.0. The Developer version and Source Version are available now. The trial version is now available as well. Watch for an announcement on our twitter account if you are waiting on the new Trial version.

Release Notes:

  • The DynamicQuery API “Between” bug has been fixed.
  • The VB.NET Hierarchical Model Equals vs IsNot bug has been fixed.
  • All SQL CE providers now correctly support the SQL TOP syntax.
  • There was a bug that would sometimes occur in the Microsoft SQL Contains clause. This has been fixed.
  • We tweaked the IDataErorrInfo so that it shouldn’t matter if column names or property names are passed in.
  • Modified SqlClientProvider.Shared.BuildDynamicInsertCommand to ignore modifications to dis-allowed columns, such as Computed, Concurrency, and AutoIncrement.
  • Added a mapping entry for the Microsoft SQL HierarchyId data type.
  • Added an overload for SetColumn() which should be used when setting the values of virtual properties that exist in the underlying DataTable. The usage is covered in this blog post. We plan to make big improvements our virtual column handling in ES2010. The signature is as follows, you pass in true as the last parameter for virtual properties.

          public void SetColumn(string columnName, object Value, bool isVirtualColumn)
  • Greatly improved our Schema/Catalog handling in the DynamicQuery API making cross schema/catalog joins much better now.
  • During an insert all columns that are either computed or that have defaults are now returned (currently only implemented for Microsoft SQL Server). We will revisit this for all providers in ES2010.
  • Greatly improved the power of the ON clause of a JOIN statement. The ON clause can now fully parse anything that can be used in a Where clause. This means the full Where syntax can now be used in the ON clause of a JOIN statement. This is true for all providers accept for Microsoft Access which requires extra parenthesis be paced around each join condition. We will revisit this functionality for MS Access in ES2010.
  • Due to our relocation to a new dedicated hosting server some of our links on the Windows “EntitySpaces 2009” menu were no longer valid. This was also true for “Forums” link on the “Whats New” tab, these have been fixed.
  • Added WithNoLock support. This is currently support for Microsoft SQL Server only (Locking hints are vastly different on all database systems).

    OrderQuery oq = new OrderQuery("o");
    OrderItemQuery oiq = new OrderItemQuery("oi");

    oq.Select(oq.CustID, oq.OrderDate, "<sub.OrderTotal>");
    oq.From
        (
            oiq.Select(oiq.OrderID,
                (oiq.UnitPrice * oiq.Quantity).Sum().As("OrderTotal"))
                .GroupBy(oiq.OrderID)
        ).As("sub");
    oq.InnerJoin(oq).On(oq.OrderID == oiq.OrderID);

    OrderCollection collection = new OrderCollection();
    oq.es.WithNoLock = true; // <== NEW
    collection.Load(oq);

    Notice that even though many query objects are being used you only need to set WithNoLock to true for the parent or main query object. The SQL generated is as follows:

    SELECT o.[CustID],o.[OrderDate],sub.OrderTotal 
    FROM
    (
       SELECT oi.[OrderID],SUM((oi.[UnitPrice]*oi.[Quantity])) AS 'OrderTotal' 
       FROM [OrderItem] oi WITH (NOLOCK)
       GROUP BY oi.[OrderID]
    ) AS sub
    INNER JOIN [Order] o WITH (NOLOCK)
    ON o.[OrderID] = sub.[OrderID]
     

EntitySpaces

From Mobile Devices to large scale enterprise solutions in need of serious transaction support, EntitySpaces can meet your needs. Whether you’re writing an ASP.NET application with Medium Trust requirements, a Silverlight/WCF application, a Mono application, or a Windows.Forms application, the EntitySpaces architecture is there for you. EntitySpaces is provider independent, which means that you can run the same binary code against any of the supported databases. EntitySpaces is available in both C# and VB.NET. EntitySpaces uses no reflection, no XML files, and sports a tiny foot print of less than 200k. Pound for pound, EntitySpaces is one tough, dependable .NET architecture.

EntitySpaces LLC
Persistence Layer and Business Objects for Microsoft .NET
http://www.entityspaces.net

Comments are closed.