Example #1
0
        public SelectQuery Where(string Clause)
        {
            if (top == null)
            {
                var clone = Clone();

                string[] new_where = null;
                if (where == null) new_where = new string[] { Clause };
                else
                {
                    new_where = new string[where.Length + 1];
                    Array.Copy(where, new_where, where.Length);
                    new_where[where.Length] = Clause;
                }

                clone.where = new_where;
                return clone;
            }
            else
            {
#warning constant name :(
                var clone = new SelectQuery(this.name("T"), fields);
                var new_where = new string[] { Clause };
                clone.where = new_where;
                return clone;
            }
        }
Example #2
0
 internal SubQuery(SelectQuery Base, LocalIdentifier Alias)
 {
     if (Alias == null) throw new ArgumentNullException("Name", "Subquery must have a name.");
     baseQuery = Base;
     AS = Alias;
     SourceDefinion = new Builder(Compile);
 }
Example #3
0
 internal RowSource(DatabaseContext ConnectionContext, SelectQuery Query)
 {
     Context = ConnectionContext;
     theQuery = Query;
 }