CREATE TABLE CoreManagement.TempSubscription ( billingAccountId binary(16) NULL, networkCount int NOT NULL, endpointCount int NOT NULL ); select hex(s.billingAccountId),s.* from CoreManagement.TempSubscription s; select hex(i.id),i.* from UserIdentity i order by i.createdAt desc;--C68DEBE23D8C441EAA69394AA1F82C81 select hex(i.id),i.* from ServiceIdentity i select hex(ng.createdBy) from NetWorkGroup ng where hex(ng.id)='9EEB8438BCE64979A375004A856695AB'; select hex(nl.createdBy), nl.* from NetWorkGroupLimit nl where hex(nl.networkGroupId)='9EEB8438BCE64979A375004A856695AB'; insert into NetWorkGroupLimit () select * from Network n where hex(n.ownerIdentityId)='C68DEBE23D8C441EAA69394AA1F82C81'; select * from Endpoint e where hex(e.ownerIdentityId)='C68DEBE23D8C441EAA69394AA1F82C81'; select * from Network order by createdAt desc; select * from NetworkLimit order by createdAt desc; select * from Execution order by createdAt desc; select * from EdgeRouter order by createdAt desc; select * from EdgeRouter where zitiId='NwTrNY8WbS'; update NetworkLimit set endpointCount=2 where hex(id)='85BD07951A144191A6E28BBEDA99F92C'; --85BD07951A144191A6E28BBEDA99F92C --Tenant-->UserIdentity-->MOP Resources delete from Execution ; select * from flyway_schema_history ; update flyway_schema_history set success=true where installed_rank in (109); delete from flyway_schema_history where installed_rank in (40); create database permissions; --26690eb4-92e9-4ed0-acbe-6e26564eae99" --e018b279-38e0-4ccc-b260-9d135f530c87 select aa.code as actionOnResource,rt.name as resourceName from IdentityResourceAction ra , ResourceAction aa , ResourceType rt where hex(ra.identityId)='26690EB492E94ED0ACBE6E26564EAE99' and aa.id=ra.resourceActionId and aa.resourceTypeId=rt.id; SELECT aa.code AS actionOnResource, rt.NAME AS resourceName, hex(aa.id) FROM identityresourceaction ra, resourceaction aa, resourcetype rt WHERE Hex(ra.identityid) = '26690EB492E94ED0ACBE6E26564EAE99' AND aa.id = ra.resourceactionid AND aa.resourcetypeid = rt.id; select hex(u.id),u.* from identity.UserIdentity u order by u.createdAt desc; select hex(rt.id),rt.*,hex(ga.id) from ResourceType rt where hex(rt.id) in ( select hex(ga.resourceTypeId) from ResourceAction ga where hex(ga.id) in (select hex(a.resourceActionId) from ActionInclusion a where hex(a.resourceActionId) in ( select hex(ra.resourceActionId) from IdentityResourceAction ra where hex(ra.identityId)='26690EB492E94ED0ACBE6E26564EAE99' ) ) ); drop table NetworkGroupLimit; drop table NetworkLimit; select hex(id) from ResourceType where code='network-group-limit'; select * from ResourceAction; delete from ActionInclusion ac where hex(ac.resourceActionId) in (select hex(id) from ResourceAction a where hex(a.resourceTypeId) in ( select HEX(id) from ResourceType where name='Network Limit')); delete from CustomRoleAction ac where hex(ac.resourceActionId) in (select hex(id) from ResourceAction a where hex(a.resourceTypeId) in ( select HEX(id) from ResourceType where name='Network Limit')); delete from ResourceAction a where hex(a.resourceTypeId) in ( select HEX(id) from ResourceType where name='Network Limit'); delete from ResourceType where code='network-limit'; delete from ResourceAction a where hex(a.resourceTypeId) in ( select HEX(id) from ResourceType where name='Network Limit'); select * from ActionInclusion ac where hex(ac.resourceActionId) in (select hex(id) from ResourceAction a where hex(a.resourceTypeId) in ( select HEX(id) from ResourceType where name='Network Limit')); select * from CustomRoleAction ac where hex(ac.resourceActionId) in (select hex(id) from ResourceAction a where hex(a.resourceTypeId) in ( select HEX(id) from ResourceType where name='Network Limit')); select hex(n.ownerIdentityId),n.* from NetworkGroup n where hex(n.id)='71E5C92AFF3E42719EABD9E0417CDA1F'; select hex(gg.billingAccountId),gg.* from NetworkGroup gg where gg.billingAccountId is not null;