anchor.diff:          | None, Some r -> r::curParams
           | Some l, Some r -> r::l::curParams
           
  -    let boolValueToWhereClause quote (body:MemberExpression) curParams isTrue = 
  -        let _, value, _ = constantOrMemberAccessValue quote body curParams
  +    let boolValueToWhereClause quote nameExtractor (body:MemberExpression) curParams isTrue = 
  +        let _, value, _ = constantOrMemberAccessValue quote nameExtractor body curParams
           value + (sprintf " = @%i" curParams.Length), (isTrue:obj)::curParams
           
       let binExpToSqlOper (body:BinaryExpression) =
  
positive.code:         | _ -> false, sprintf "@%i" curParams.Length, Some v 
          //use sqlparameters instead of inline sql due to PetaPoco's static query cache growing
  
      let rec constantOrMemberAccessValue (quote:IQuoter) (body:Expression) curParams = 
          match (body.NodeType, body) with
          | ExpressionType.Constant, (:? ConstantExpression as body) -> 
              literalToSql body.Value curParams
          | ExpressionType.Convert, (:? UnaryExpression as body) -> 
              constantOrMemberAccessValue quote body.Operand curParams
          | ExpressionType.MemberAccess, (:? MemberExpression as body) -> 
              match body.Member.GetType().Name with
              |"RtFieldInfo"|"MonoField" -> 
                  let unaryExpr = Expression.Convert(body, typeof<obj>)
                  let v = Expression.Lambda<Func<obj>>(unaryExpr).Compile()
                  literalToSql (v.Invoke ()) curParams
              |"RuntimePropertyInfo"|"MonoProperty" -> false, quote.QuoteColumn body.Member.Name, None
              |_ as name -> failwithf "unsupported member type name %s" name   
          | _ -> failwithf "unsupported nodetype %A" body   
  
      let leafExpression quote (body:BinaryExpression) sqlOperator curParams =
          let _, lVal, lParam = constantOrMemberAccessValue quote body.Left curParams
          let rNull, rVal, rParam = constantOrMemberAccessValue quote body.Right curParams
  
          let oper = 
              match (rNull, body.NodeType) with
  
negative.code: 
              | None -> 
                  match binExpToSqlOper body with
                  | Some sqlOper -> leafExpression quote nameExtractor body sqlOper curSqlParams
                  | None -> failwithf "unsupported operator %A in leaf" body.NodeType
          | _ -> failwithf "conditions has unexpected type %A" body
  
  