change
Member
Role
@Modifying(clearAutomatically = true
)
@Query(value = ""UPDATE " + GROUP_MEMBERS_TABLE + " SET " + MEMBER_ROLE_KEY + "="
+ ":#{#" + MEMBER_ROLE_KEY + ".name()}"
+ " WHERE " + GROUP_MEMBER_KEY + "=:" + GROUP_MEMBER_KEY
+ " AND " + IDENTIFIER_KEY + "=:" + IDENTIFIER_KEY",
nativeQuery = true
)
Method to execute the query to change the role of a group member
Parameters
memberId
: the member identifier
groupId
: the group identifier
role
: the role of the member