# Getting constraint violation ACT\_FK\_MEMB\_GROUP

**URL:** <https://forum.flowable.org/t/getting-constraint-violation-act-fk-memb-group/5776>\
**Category:** Flowable Engine\
**Created:** [April 6, 2020, 6:20am UTC](https://forum.flowable.org/t/getting-constraint-violation-act-fk-memb-group/5776 "2020-04-06T06:20:14Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![ankit45621](https://avatars.discourse-cdn.com/v4/letter/a/e9bcb4/32.png) [@ankit45621](https://forum.flowable.org/u/ankit45621)\
**Post date:** [April 6, 2020, 6:20am UTC](https://forum.flowable.org/t/getting-constraint-violation-act-fk-memb-group/5776/1 "2020-04-06T06:20:15Z")

</div>

Hi,

org.h2.jdbc.JdbcSQLIntegrityConstraintViolationException: Referential integrity constraint violation: “ACT\_FK\_MEMB\_GROUP: PUBLIC.ACT\_ID\_MEMBERSHIP FOREIGN KEY(GROUP\_ID\_) REFERENCES PUBLIC.ACT\_ID\_GROUP(ID\_) (‘501’)”; SQL statement: insert into ACT\_ID\_MEMBERSHIP (USER\_ID\_, GROUP\_ID\_)

I was using configuration in [https://forum.flowable.org/t/using-ldap-all-users-and-groups-records-not-sync/5744](https://forum.flowable.org/t/using-ldap-all-users-and-groups-records-not-sync/5744) but after response from person i remove db configuration and use only LDAP for data storage(below are configuration currently using) but i got issue [https://forum.flowable.org/t/act-id-priv-mapping-not-adding-user-of-group-record/5755/12?u=ankit45621](https://forum.flowable.org/t/act-id-priv-mapping-not-adding-user-of-group-record/5755/12).

Configuration currently using:

> ```
> flowable-idm-app:
> image: flowable/flowable-idm
> container_name: flowable-idm
> depends_on:
> - flowable-db
> environment:
> - SERVER_PORT=9090
> #Default LDAP Admin User
> - FLOWABLE_IDM_APP_ADMIN_USER_ID=flowLdap
> - FLOWABLE_IDM_APP_ADMIN_PASSWORD=test
> - FLOWABLE_COMMON_APP_IDM_ADMIN_USER=flowLdap
> - FLOWABLE_COMMON_APP_IDM_ADMIN_PASSWORD=test
> #FLowable-Ldap Configuration
> - FLOWABLE_IDM_LDAP_ENABLED=true
> - FLOWABLE_IDM_LDAP_SERVER=ldap://DEV.amazonaws.com
> - FLOWABLE_IDM_LDAP_PORT=389
> - FLOWABLE_IDM_LDAP_USER=cn=admin,dc=test,dc=asia
> - FLOWABLE_IDM_LDAP_PASSWORD=admin
> - FLOWABLE_IDM_LDAP_BASE_DN=dc=test,dc=asia
> #Users
> - FLOWABLE_IDM_LDAP_USER_BASE_DN=ou=country,dc=test,dc=asia
> - FLOWABLE_IDM_LDAP_QUERY_USER_BY_FULL_NAME_LIKE=(&(objectClass=inetOrgPerson)(|({0}=*{1}*)({2}=*{3}*)))
> - FLOWABLE_IDM_LDAP_QUERY_USER_BY_ID=(&(objectClass=inetOrgPerson)(uid={0}))
> - FLOWABLE_IDM_LDAP_QUERY_ALL_USERS=(objectClass=inetOrgPerson)
> - FLOWABLE_IDM_LDAP_ATTRIBUTE_USER_ID=uid
> - FLOWABLE_IDM_LDAP_ATTRIBUTE_FIRST_NAME=cn
> - FLOWABLE_IDM_LDAP_ATTRIBUTE_LAST_NAME=sn
> #Groups
> - FLOWABLE_IDM_LDAP_GROUP_BASE_DN=ou=groups,dc=test,dc=asia
> - FLOWABLE_IDM_LDAP_QUERY_GROUPS_FOR_USER=(&(objectClass=posixGroup)(gidNumber={0}))
> - FLOWABLE_IDM_LDAP_QUERY_ALL_GROUPS=(objectClass=posixGroup)
> - FLOWABLE_IDM_LDAP_QUERY_GROUP_BY_ID=(&(objectClass=posixGroup)(gidNumber={0}))
> - FLOWABLE_IDM_LDAP_ATTRIBUTE_GROUP_ID=gidNumber
> - FLOWABLE_IDM_LDAP_ATTRIBUTE_GROUP_NAME=cn
> - FLOWABLE_IDM_LDAP_CACHE_GROUP_SIZE=10000
> - FLOWABLE_IDM_LDAP_CACHE_GROUP_EXPIRATION=180000
> - LOGGING_LEVEL_ORG_FLOWABLE=DEBUG
> ports:
> - 9090:9090
> entrypoint: ["./wait-for-something.sh", "flowable-db", "5432", "PostgreSQL", "java", "-jar", "app.war"]
> 
> ```

Can anyone help, i am new in flowable and there is no sample LDAP configuration at [flowable-engine/docker/config at main · flowable/flowable-engine · GitHub](https://github.com/flowable/flowable-engine/tree/master/docker/config). Please help me as facing issue from past 1 month.
