Issue 2064: XML Query - added support for not_in

git-svn-id: http://xe-core.googlecode.com/svn/branches/1.5.0@10776 201d5d3c-b55e-5fd7-737f-ddc643e51545
This commit is contained in:
ucorina 2012-06-18 12:04:38 +00:00
parent 7fd8f55141
commit 40a2d4a6ed
6 changed files with 77 additions and 3 deletions

View file

@ -13,7 +13,7 @@
var $argument;
/**
* operation can use 'equal', 'more', 'excess', 'less', 'below', 'like_tail', 'like_prefix', 'like', 'notlike_tail',
* 'notlike_prefix', 'notlike', 'in', 'notin', 'and', 'or', 'xor', 'not', 'notequal', 'between'
* 'notlike_prefix', 'notlike', 'in', 'notin', 'not_in', 'and', 'or', 'xor', 'not', 'notequal', 'between'
* @var string
*/
var $operation;
@ -115,6 +115,7 @@
case 'notlike' :
case 'in' :
case 'notin' :
case 'not_in' :
case 'and':
case 'or':
case 'xor':
@ -177,6 +178,7 @@
return $name.' in '.$value;
break;
case 'notin' :
case 'not_in' :
return $name.' not in '.$value;
break;
case 'notequal' :

View file

@ -15,7 +15,7 @@
*/
function ConditionWithoutArgument($column_name, $argument, $operation, $pipe = ""){
parent::Condition($column_name, $argument, $operation, $pipe);
if(in_array($operation, array('in', 'notin'))){
if(in_array($operation, array('in', 'notin', 'not_in'))){
if(is_array($argument)) $argument = implode($argument, ',');
$this->_value = '('. $argument .')';
}