- πΊπΈUnited States bluegeek9
The solution is to use a use two different services. This is an example from core.
entity.query.sql: class: Drupal\Core\Entity\Query\Sql\QueryFactory arguments: ['@database'] tags: - { name: backend_overridable } pgsql.entity.query.sql: class: Drupal\Core\Entity\Query\Sql\pgsql\QueryFactory arguments: ['@database']
- Assigned to bluegeek9
- πΊπΈUnited States bluegeek9
This should solve the problem for PostgreSQL and SQLite
$formula = $this->getDateFormat($this->format_string);
Drupal\views\Plugin\HandlerBase
/** * Creates cross-database SQL date formatting. * * @param string $format * A format string for the result, like 'Y-m-d H:i:s'. * * @return string * An appropriate SQL string for the DB type and field type. */ public function getDateFormat($format) { return $this->query->getDateFormat($this->getDateField(), $format); }
-
bluegeek9 β
committed 51f74caa on 8.x-3.x
Issue #2922088: PostgreSQL SQL Error: Undefined function FROM_UNIXTIME
-
bluegeek9 β
committed 51f74caa on 8.x-3.x