I have several Drupal 8 installations running on an Ubuntu 18.04.1, using PostgreSQL 10.7.

I have been trying to install Open Social using composer and drush. composer seems to have installed goalgorilla/open_social 4.7.0. I set up the database parameters in settings.php and issued the following drush command:

drush -y site-install social

After a while I got the following crash report (I have abbreviated the stack dumps):

PDOException: SQLSTATE[22P02]: Invalid text representation: 7 ERROR:  invalid input syntax for integer: "user.full" [error]
LINE 5: ...activity_entity.field_activity_entity_target_id = 'user.full...
                                                             ^ in /home/drupal8/drupal/social/html/core/lib/Drupal/Core/Database/Statement.php:59
Stack trace:
#0 /home/drupal8/drupal/social/html/core/lib/Drupal/Core/Database/Statement.php(59): PDOStatement->execute(Array)
#1 /home/drupal8/drupal/social/html/core/lib/Drupal/Core/Database/Connection.php(625): Drupal\Core\Database\Statement->execute(Array, Array)
#2 /home/drupal8/drupal/social/html/core/lib/Drupal/Core/Database/Driver/pgsql/Connection.php(201): Drupal\Core\Database\Connection->query('SELECT base_tab...', Array, Array)
#3 /home/drupal8/drupal/social/html/core/lib/Drupal/Core/Database/Query/Select.php(510): Drupal\Core\Database\Driver\pgsql\Connection->query('SELECT base_tab...', Array, Array)
#4 /home/drupal8/drupal/social/html/core/lib/Drupal/Core/Database/Driver/pgsql/Select.php(145): Drupal\Core\Database\Query\Select->execute()
#5 /home/drupal8/drupal/social/html/core/lib/Drupal/Core/Entity/Query/Sql/Query.php(257): Drupal\Core\Database\Driver\pgsql\Select->execute()
#6 /home/drupal8/drupal/social/html/core/lib/Drupal/Core/Entity/Query/Sql/Query.php(76): Drupal\Core\Entity\Query\Sql\Query->result()
#7 /home/drupal8/drupal/social/html/profiles/contrib/social/modules/custom/activity_creator/activity_creator.module(263): Drupal\Core\Entity\Query\Sql\Query->execute()
#8 /home/drupal8/drupal/social/html/profiles/contrib/social/modules/custom/activity_creator/activity_creator.module(230):
_activity_creator_activity_for_entity_updater('update', Object(Drupal\Core\Entity\Entity\EntityViewMode))
#9 [internal function]: activity_creator_entity_update(Object(Drupal\Core\Entity\Entity\EntityViewMode), 'entity_view_mod...')
#10 /home/drupal8/drupal/social/html/core/lib/Drupal/Core/Extension/ModuleHandler.php(403): call_user_func_array('activity_creato...', Array)
...

Next Drupal\Core\Database\DatabaseExceptionWrapper: SQLSTATE[22P02]: Invalid text representation: 7 ERROR:  invalid input syntax for integer: "user.full"
LINE 5: ...activity_entity.field_activity_entity_target_id = 'user.full...
                                                             ^: SELECT base_table.id AS id, base_table.id AS base_table_id
FROM
{activity} base_table
INNER JOIN {activity__field_activity_entity} activity__field_activity_entity ON activity__field_activity_entity.entity_id = base_table.id
WHERE (activity__field_activity_entity.field_activity_entity_target_id = :db_condition_placeholder_0) AND
(activity__field_activity_entity.field_activity_entity_target_type = :db_condition_placeholder_1); Array
(
    [:db_condition_placeholder_0] => user.full
    [:db_condition_placeholder_1] => entity_view_mode
)
 in /home/drupal8/drupal/social/html/core/lib/Drupal/Core/Database/Connection.php:686
Stack trace:
#0 /home/drupal8/drupal/social/html/core/lib/Drupal/Core/Database/Connection.php(650): Drupal\Core\Database\Connection->handleQueryException(Object(PDOException), 'SELECT base_tab...', Array, Array)
#1 /home/drupal8/drupal/social/html/core/lib/Drupal/Core/Database/Driver/pgsql/Connection.php(201): Drupal\Core\Database\Connection->query('SELECT base_tab...', Array, Array)
#2 /home/drupal8/drupal/social/html/core/lib/Drupal/Core/Database/Query/Select.php(510): Drupal\Core\Database\Driver\pgsql\Connection->query('SELECT base_tab...', Array, Array)
#3 /home/drupal8/drupal/social/html/core/lib/Drupal/Core/Database/Driver/pgsql/Select.php(145): Drupal\Core\Database\Query\Select->execute()
#4 /home/drupal8/drupal/social/html/core/lib/Drupal/Core/Entity/Query/Sql/Query.php(257): Drupal\Core\Database\Driver\pgsql\Select->execute()
#5 /home/drupal8/drupal/social/html/core/lib/Drupal/Core/Entity/Query/Sql/Query.php(76): Drupal\Core\Entity\Query\Sql\Query->result()
#6 /home/drupal8/drupal/social/html/profiles/contrib/social/modules/custom/activity_creator/activity_creator.module(263): Drupal\Core\Entity\Query\Sql\Query->execute()
#7 /home/drupal8/drupal/social/html/profiles/contrib/social/modules/custom/activity_creator/activity_creator.module(230):
_activity_creator_activity_for_entity_updater('update', Object(Drupal\Core\Entity\Entity\EntityViewMode))
#8 [internal function]: activity_creator_entity_update(Object(Drupal\Core\Entity\Entity\EntityViewMode), 'entity_view_mod...')
#9 /home/drupal8/drupal/social/html/core/lib/Drupal/Core/Extension/ModuleHandler.php(403): call_user_func_array('activity_creato...', Array)
#10 /home/drupal8/drupal/social/html/core/lib/Drupal/Core/Config/Entity/ConfigEntityStorage.php(349): Drupal\Core\Extension\ModuleHandler->invokeAll('entity_update',Array)
...

Something tells me that this is a problem with incorrect SQL (presumably something MySQL-specific). Does anyone have a work-around?

Steve

Comments

winnall created an issue. See original summary.

winnall’s picture

Title: Cannot install 4.7.0 » Cannot install 4.7.0 or 4.8.0

The problem is still there in 4.8.0, even though 4.8.0 is not available in the 'Version' dropdown.

winnall’s picture

Title: Cannot install 4.7.0 or 4.8.0 » Cannot install 4.7.0 or 4.8.0 or 3.15.0

Since neither 4.7.0 or 4.8.0 worked, I have downgraded to 3.15.0.

The same error occurs.

winnall’s picture

Category: Support request » Bug report

Just to confirm the obvious: after installing MySQL, I have been able to get Open Social up and running. So it would appear that there is a bug in the support for PostgreSQL.

jaapjan’s picture

Title: Cannot install 4.7.0 or 4.8.0 or 3.15.0 » Cannot install with PostgreSQL
ronaldtebrake’s picture

Category: Bug report » Support request
Status: Active » Postponed

There are still quite some issues with PostgreSQL, we advice to work with MySQL for now. See: https://www.drupal.org/node/2564307
Feel free to file separate issues if you can single out issues with Open Social and PostgreSQL

tbsiqueira’s picture

Assigned: Unassigned » tbsiqueira

Hi! Thank you for your comments, please let us know if this is still an issue!

tbsiqueira’s picture

Status: Postponed » Closed (works as designed)

So far we don't have plans to support Open Social on PostgreSQL, We advice to work with MySQL for now.