Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
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 {
$separator = $this->connection->quote($separator);
return new QueryFunction('LISTAGG(' . $this->helper->quoteColumnName($expr) . ', ' . $separator . ')' . $orderByClause);
}
+
+ public function octetLength($field, $alias = ''): IQueryFunction {
+ $alias = $alias ? (' AS ' . $this->helper->quoteColumnName($alias)) : '';
+ $quotedName = $this->helper->quoteColumnName($field);
+ return new QueryFunction('LENGTHB(' . $quotedName . ')' . $alias);
+ }
}