Example #1
0
        public SqlSelect FullJoin <TLeft, TJoin>(Expression <Func <TLeft, TJoin, bool> > condition,
                                                 SqlAlias <TLeft> leftAlias = null, SqlAlias <TJoin> joinAlias = null)
        {
            if (condition == null)
            {
                throw new ArgumentNullException(nameof(condition));
            }
            if (leftAlias == null)
            {
                leftAlias = MetadataProvider.AliasFor <TLeft>();
            }
            if (joinAlias == null)
            {
                joinAlias = MetadataProvider.AliasFor <TJoin>();
            }

            return(FullJoin(GetJoinFilter(condition.Body as BinaryExpression, leftAlias, joinAlias), joinAlias));
        }
Example #2
0
 public SqlSelect<T> GroupBy<TEntity>(params Expression<Func<TEntity, object>>[] fields)
 {
     if (fields == null) throw new ArgumentNullException(nameof(fields));
     return GroupBy(CreateSqlFields(MetadataProvider.AliasFor<TEntity>(), fields));
 }
Example #3
0
 static MetadataProvider()
 {
     Instance = new MetadataProvider();
 }