Exemplo n.º 1
0
        /// <summary>
        /// Appends an AND restriction to this Sub selects last JOIN statements
        /// </summary>
        /// <param name="reference"></param>
        /// <returns></returns>
        public DBClause And(DBClause reference)
        {
            IDBBoolean join = (IDBBoolean)this.Joins[this.Joins.Count - 1];

            join.And(reference);
            return((DBClause)join);
        }
Exemplo n.º 2
0
        /// <summary>
        /// Adds an AND comparison to the last join
        /// </summary>
        /// <param name="reference"></param>
        /// <returns></returns>
        public DBClause And(DBClause reference)
        {
            if (this.HasJoins == false)
            {
                throw new InvalidOperationException("No joined tables or sub queries to join to");
            }

            IDBBoolean join = (IDBBoolean)this.Joins[this.Joins.Count - 1];

            join.And(reference);
            return((DBClause)join);
        }