replace delete cascades with SQL functions
MEMBER-DELETE parameter is "username", not "member_id"