This forum has moved to a new location and is in read-only mode. Please visit talk.octobercms.com to access the new location.

AlexRo72
AlexRo72

Hello. Some fix for PosgreSQL < 9 like this

        if (true) {
            $result = str_replace(array("string_agg(", ", ', ')"), array("array_to_string(array_agg(", "), ', ')"), $result);
        } 

PostgreSQL < 9 dont know "string_agg" Can add this fix?

file /vendor/october/rain/src/Database/Dongle.php 74 row public function parseGroupConcat($sql) { ... }

Thank you

Briddle
Briddle

Unfortunately this continues to give problems.

https://octobercms.com/plugin/support/briddle-crm/install-error-with-postgresql

When joining on multiple fields for many to many relations it adds ", ', '" to the function. This gives an error.

Please add:

$result = str_ireplace(", ', '", "", $result);

to:

if ($this->driver == 'pgsql' || $this->driver == 'postgis') {
    $result = preg_replace("/\\(([]a-zA-Z\\-\\_\\.]+)\\,/i", "($1::VARCHAR,", $result);
    $result = str_ireplace('group_concat(', 'string_agg(', $result);
    $result = str_ireplace(", ', '", "", $result);
}

Last updated

1-2 of 2

You cannot edit posts or make replies: the forum has moved to talk.octobercms.com.