mirror of
https://github.com/nextcloud/server.git
synced 2026-06-09 00:32:29 -04:00
Use OCTET_LENGTH which is more common than LENGTHB
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
This commit is contained in:
parent
3a61963980
commit
6e3cd43903
2 changed files with 7 additions and 1 deletions
|
|
@ -82,7 +82,7 @@ class FunctionBuilder implements IFunctionBuilder {
|
|||
public function octetLength($field, $alias = ''): IQueryFunction {
|
||||
$alias = $alias ? (' AS ' . $this->helper->quoteColumnName($alias)) : '';
|
||||
$quotedName = $this->helper->quoteColumnName($field);
|
||||
return new QueryFunction('LENGTHB(' . $quotedName . ')' . $alias);
|
||||
return new QueryFunction('OCTET_LENGTH(' . $quotedName . ')' . $alias);
|
||||
}
|
||||
|
||||
public function charLength($field, $alias = ''): IQueryFunction {
|
||||
|
|
|
|||
|
|
@ -72,4 +72,10 @@ class OCIFunctionBuilder extends FunctionBuilder {
|
|||
|
||||
return parent::least($x, $y);
|
||||
}
|
||||
|
||||
public function octetLength($field, $alias = ''): IQueryFunction {
|
||||
$alias = $alias ? (' AS ' . $this->helper->quoteColumnName($alias)) : '';
|
||||
$quotedName = $this->helper->quoteColumnName($field);
|
||||
return new QueryFunction('LENGTHB(' . $quotedName . ')' . $alias);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue