Skip to content

Commit

Permalink
MDL-17491 oracle dml: towards full support
Browse files Browse the repository at this point in the history
  • Loading branch information
skodak committed Dec 9, 2008
1 parent 67da7e6 commit 2c4eb00
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 4 deletions.
2 changes: 1 addition & 1 deletion lib/dml/oci8po_adodb_moodle_database.php
Expand Up @@ -170,7 +170,7 @@ public function sql_bitor($int1, $int2) {
}

public function sql_bitxor($int1, $int2) {
return '((' . $int1 . ') # (' . $int2 . '))';
return '(' . $this->sql_bitor($int1, $int2) . ' - ' . $this->sql_bitand($int1, $int2) . ')';
}

/**
Expand Down
4 changes: 1 addition & 3 deletions lib/dml/oci_native_moodle_database.php
Expand Up @@ -1118,13 +1118,11 @@ public function sql_bitnot($int1) {
}

public function sql_bitor($int1, $int2) {
// TODO: this can not work because the number of params does not match
return '((' . $int1 . ') + (' . $int2 . ') - ' . $this->sql_bitand($int1, $int2) . ')';
}

public function sql_bitxor($int1, $int2) {
// TODO: this can not work because the number of params does not match
return '(' . sql_bitor($int1, $int2) . ' - ' . $this->sql_bitand($int1, $int2) . ')';
return '(' . $this->sql_bitor($int1, $int2) . ' - ' . $this->sql_bitand($int1, $int2) . ')';
}

/**
Expand Down

0 comments on commit 2c4eb00

Please sign in to comment.