title: Error in starting wso2 server : org.wso2.carbon.user.core.UserStoreException: Error! Subquery returns more than 1 row at
body: <p>Error in WSO2 api manger while trying to connect an external database in a system acessing while vpn.</p>
  
  <pre><code>    Caused by: org.wso2.carbon.user.core.UserStoreException: Error! Subquery returns more than 1 row
      at org.wso2.carbon.user.core.authorization.JDBCAuthorizationManager.addAuthorizationForRole(JDBCAuthorizationManager.java:1079)
      at org.wso2.carbon.user.core.authorization.JDBCAuthorizationManager.authorizeRole(JDBCAuthorizationManager.java:527)
      ... 37 more
  Caused by: java.sql.SQLException: Subquery returns more than 1 row
      at com.mysql.cj.jdbc.exceptions.SQLError.createSQLException(SQLError.java:129)
      at com.mysql.cj.jdbc.exceptions.SQLError.createSQLException(SQLError.java:97)
      at com.mysql.cj.jdbc.exceptions.SQLExceptionsMapping.translateException(SQLExceptionsMapping.java:122)
      at com.mysql.cj.jdbc.ClientPreparedStatement.executeInternal(ClientPreparedStatement.java:970)
      at com.mysql.cj.jdbc.ClientPreparedStatement.executeQuery(ClientPreparedStatement.java:1020)
      at sun.reflect.GeneratedMethodAccessor33.invoke(Unknown Source)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
      at java.lang.reflect.Method.invoke(Method.java:498)
      at org.apache.tomcat.jdbc.pool.StatementFacade$StatementProxy.invoke(StatementFacade.java:114)
      at com.sun.proxy.$Proxy19.executeQuery(Unknown Source)
      at org.wso2.carbon.user.core.authorization.JDBCAuthorizationManager.addAuthorizationForRole(JDBCAuthorizationManager.java:1025)
      ... 38 more
  </code></pre>