Symantec IGA

 View Only
  • 1.  Connector Xpress MYSQL - Delete all membership without filtering

    Posted 10 days ago
    Hello,

    We have configured a JDBC mysql connector.

    We have 2 classes pointing to 2 different tables:

    -User Acccount
    -User Group



    They are related by User Account (ID) and User Group (User ID):








    The format of the tables is as follows:

    -Uses Account:
    ID: A
    .
    .
    .
    rest of attributes

    -User Group:
    ID: A
    Group: 1
    ID: A
    Group: 2
    ID: A
    Group: 3
    .
    .


    The relationship is 1 to N. That is, user ID=A has groups 1, 2 and 3. The problem occurs when requesting the deletion of group 1, the connector automatically deletes all associated groups from the table without filtering by the group to be deleted. How can we configure that only the selected group is deleted and not all user records in the table?

    Thank you,
    regards.


  • 2.  RE: Connector Xpress MYSQL - Delete all membership without filtering

    Posted 8 days ago

    Any ideas? When an attribute such as password is changed, I can get it through Operation Bindings but this attribute I can't get, the connector removes directly without filtering. How can I set the relationship to be 1 to N?


  • 3.  RE: Connector Xpress MYSQL - Delete all membership without filtering

    Broadcom Employee
    Posted 5 days ago
    Dear Carl,

    I don't think the model you described will work.
    You need to use indirect relationship:
    1) Accounts table, with this design:
    AccountID
    ...
    2) Groups table, with this design:
    GroupID
    ...
    3) Accounts-Groups relationship table, with this design:
    AccountID
    GroupID

    Indirect relationship (relation table is called User Groups):




  • 4.  RE: Connector Xpress MYSQL - Delete all membership without filtering

    Posted 3 days ago
    Hello Dmytro.

    Thanks for your answer, but it continues tofail.

    We have 3 classes:



    1) User Account --> Accounts table, with this design:
    Acoount ID
    ID (this is the attribute that is related to the group relational table)

    ...

    2) Groups --> Groups table, with this design:
    Group_ID

    3) User Groups--> Accounts-Groups relationship table, with this design:
    User_ID
    Group_ID


    User Account:







    Groups:





    Error:

    2022-11-29 09:58:55,417 593775465 [ApacheDS Worker-thread-117] (com.ca.jcs.core:com.ca.jcs.processor.RetryOpProcessorProxy:343) DEBUG - com.ca.jcs.jdbc.JDBCMetaConnector: BBDD_MYSQL_BOTON_ROJO: no retry group found matching exception text 'org.apache.directory.shared.ldap.exception.LdapConfigurationException: JCS@tehwc4185asv: error in addAttrAssocs on objectClass='eTDYNAccount', name='PINDI0131000', containerName='eTDYNAccountContainerName=Accounts' [Root exception is org.springframework.dao.DataIntegrityViolationException: StatementCallback; SQL [INSERT INTO "crearb"."jmltlf_user_usergroup_map" ("user_id","group_id") SELECT obj."id",ref."id" FROM "crearb"."jmltlf_users" obj,"crearb"."jmltlf_usergroups" ref WHERE obj."username"='PINDI0131000' AND ref."id" IN ('{group_id=group_id: 12}')]; Data truncation: Truncated incorrect DOUBLE value: '{group_id=group_id: 12}'; nested exception is com.mysql.jdbc.MysqlDataTruncation: Data truncation: Truncated incorrect DOUBLE value: '{group_id=group_id: 12}'] [CAUSE: org.springframework.dao.DataIntegrityViolationException: StatementCallback; SQL [INSERT INTO "crearb"."jmltlf_user_usergroup_map" ("user_id","group_id") SELECT obj."id",ref."id" FROM "crearb"."jmltlf_users" obj,"crearb"."jmltlf_usergroups" ref WHERE obj."username"='PINDI0131000' AND ref."id" IN ('{group_id=group_id: 12}')]; Data truncation: Truncated incorrect DOUBLE value: '{group_id=group_id: 12}'; nested exception is com.mysql.jdbc.MysqlDataTruncation: Data truncation: Truncated incorrect DOUBLE value: '{group_id=group_id: 12}' [CAUSE: com.mysql.jdbc.MysqlDataTruncation: Data truncation: Truncated incorrect DOUBLE value: '{group_id=group_id: 12}']]'
    2022-11-29 09:58:55,417 593775465 [ApacheDS Worker-thread-117] (com.ca.jcs.core:com.ca.jcs.processor.ConnectorProcessorProxyHandler:218) ERROR - com.ca.jcs.jdbc.JDBCMetaConnector: BBDD_MYSQL_BOTON_ROJO: class com.ca.jcs.processor.RetryOpProcessorProxy: failed call on doModify
    org.apache.directory.shared.ldap.exception.LdapConfigurationException: JCS@tehwc4185asv: error in addAttrAssocs on objectClass='eTDYNAccount', name='PINDI0131000', containerName='eTDYNAccountContainerName=Accounts' [Root exception is org.springframework.dao.DataIntegrityViolationException: StatementCallback; SQL [INSERT INTO "crearb"."jmltlf_user_usergroup_map" ("user_id","group_id") SELECT obj."id",ref."id" FROM "crearb"."jmltlf_users" obj,"crearb"."jmltlf_usergroups" ref WHERE obj."username"='PINDI0131000' AND ref."id" IN ('{group_id=group_id: 12}')]; Data truncation: Truncated incorrect DOUBLE value: '{group_id=group_id: 12}'; nested exception is com.mysql.jdbc.MysqlDataTruncation: Data truncation: Truncated incorrect DOUBLE value: '{group_id=group_id: 12}']


    What could be happening?

    Thank you,
    regards.