public void GroupFacts()
        {
            var builder   = new SqlExpressionBuilderSelect();
            var fromTable = new Table("table", "t");
            var joinTable = new Table("join", "j");

            builder.From(fromTable);
            builder.Select("Id", fromTable);
            builder.Select(new AliasedExpression <CountExpression>(
                               new CountExpression(joinTable.GetColumn("moo")), "count"));
            builder.JoinLeft(fromTable.GetColumn("Id"), joinTable.GetColumn("fromId"));
            builder.Group(new[] { "t.Id" });

            const string expected =
                "SELECT t.Id, COUNT(j.moo) AS count " +
                "FROM table t " +
                "LEFT JOIN join j ON t.Id = j.fromId " +
                "GROUP BY t.Id";

            Assert.Equal(expected, builder.ToString());
        }