org.ofbiz.core.entity.GenericDataSourceException

SQL Exception while executing the following:SELECT ID FROM public.cwd_membership WHERE directory_id = (select id from cwd_directory where directory_name='Remote Crowd Directory') (ERROR: more than one row returned by a subquery used as an expression)

Samebug tips1

Try downgrading PostgresSQL server to 9.5 or update your PostgresSQL driver to 9.4-1211 with the following command: <postgresql.version>9.4.1211</postgresql.version>

Don't give up yet. Our experts can help. Paste your full stack trace to get a solution.

Solutions on the web95

  • via Atlassian JIRA by Nick Mason [Atlassian], 10 months ago
    SQL Exception while executing the following:SELECT ID FROM public.cwd_membership WHERE directory_id = (select id from cwd_directory where directory_name='Remote Crowd Directory') (ERROR: more than one row returned by a subquery used as an expression)
  • via Atlassian JIRA by David Demner, 11 months ago
    SQL Exception while executing the following:SELECT ID, username, PASSWORD_HASH FROM userbase WHERE username=? (Invalid state, the Connection object is closed.)
  • via Atlassian JIRA by David Demner, 1 year ago
    SQL Exception while executing the following:SELECT ID, username, PASSWORD_HASH FROM userbase WHERE username=? (Invalid state, the Connection object is closed.)
  • Stack trace

    • org.ofbiz.core.entity.GenericDataSourceException: SQL Exception while executing the following:SELECT ID FROM public.cwd_membership WHERE directory_id = (select id from cwd_directory where directory_name='Remote Crowd Directory') (ERROR: more than one row returned by a subquery used as an expression) at org.ofbiz.core.entity.jdbc.SQLProcessor.executeQuery(SQLProcessor.java:641) at org.ofbiz.core.entity.GenericDAO.createEntityListIterator(GenericDAO.java:967) at org.ofbiz.core.entity.GenericDAO.selectListIteratorByCondition(GenericDAO.java:883) at org.ofbiz.core.entity.GenericDAO.selectByCondition(GenericDAO.java:798) at org.ofbiz.core.entity.GenericDAO.selectByCondition(GenericDAO.java:777) at org.ofbiz.core.entity.GenericHelperDAO.findByCondition(GenericHelperDAO.java:178) at org.ofbiz.core.entity.GenericDelegator.findByCondition(GenericDelegator.java:1085) at com.atlassian.ondemand.backupmanager.service.BackupEntityChangesProvider.findEntityIds(BackupEntityChangesProvider.java:215) at com.atlassian.ondemand.backupmanager.service.BackupEntityChangesProvider.parseBackupEntityChange(BackupEntityChangesProvider.java:194) at com.atlassian.ondemand.backupmanager.service.BackupEntityChangesProvider.loadFromXml(BackupEntityChangesProvider.java:153) at com.atlassian.ondemand.backupmanager.service.BackupEntityChangesProvider.<init>(BackupEntityChangesProvider.java:56) at com.atlassian.ondemand.backupmanager.service.JiraBackupService.backup(JiraBackupService.java:125) at com.atlassian.ondemand.backupmanager.rest.OnDemandBackupTask.run(OnDemandBackupTask.java:84) at com.atlassian.ondemand.backupmanager.longrunning.ManagedTask.run(ManagedTask.java:35) at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) at java.lang.Thread.run(Thread.java:745) Caused by: org.postgresql.util.PSQLException: ERROR: more than one row returned by a subquery used as an expression at org.postgresql.core.v3.QueryExecutorImpl.receiveErrorResponse(QueryExecutorImpl.java:2157) at org.postgresql.core.v3.QueryExecutorImpl.processResults(QueryExecutorImpl.java:1886) at org.postgresql.core.v3.QueryExecutorImpl.execute(QueryExecutorImpl.java:255) at org.postgresql.jdbc2.AbstractJdbc2Statement.execute(AbstractJdbc2Statement.java:555) at org.postgresql.jdbc2.AbstractJdbc2Statement.executeWithFlags(AbstractJdbc2Statement.java:417) at org.apache.tomcat.dbcp.dbcp2.DelegatingPreparedStatement.executeQuery(DelegatingPreparedStatement.java:82) at org.apache.tomcat.dbcp.dbcp2.DelegatingPreparedStatement.executeQuery(DelegatingPreparedStatement.java:82) at org.ofbiz.core.entity.jdbc.SQLProcessor.executeQuery(SQLProcessor.java:633) ... 18 more

    Write tip

    You have a different solution? A short tip here would help you and many other users who saw this issue last week.

    Users with the same issue

    Once, 4 weeks ago
    26 times, 1 month ago
    7 times, 1 month ago
    2 times, 1 month ago
    Unknown user
    2 times, 1 month ago
    89 more bugmates