コード例 #1
0
        public string GetFilter(string fieldName, string fieldValue)
        {
            fieldValue = new FieldValueEscaper().Escape(fieldValue, false);
            fieldName = new FieldNameEscaper().Escape(fieldName, fieldValue);

            return fieldName + " LIKE '%" + fieldValue + "'";
        }
コード例 #2
0
        public string GetFilter(string fieldName, string fieldValue)
        {
            fieldValue = new FieldValueEscaper().Escape(fieldValue, false);
            fieldName = new FieldNameEscaper().Escape(fieldName, fieldValue);
            string[] parts = fieldValue.Split(',', ';', '-', '.', ':', '_');
            fieldValue = "";
            foreach (string part in parts)
            {
                if (!string.IsNullOrEmpty(part)) fieldValue += "'" + part + "',";
            }
            fieldValue = fieldValue.TrimEnd(',');

            return fieldName + " NOT IN (" + fieldValue + ")";
        }
コード例 #3
0
 public string GetFilter(string fieldName, string fieldValue)
 {
     fieldValue = new FieldValueEscaper().Escape(fieldValue);
     fieldName = new FieldNameEscaper().Escape(fieldName, fieldValue);
     return fieldName + " <> " + fieldValue;
 }