THIS IS A TEST INSTANCE. ALL YOUR CHANGES WILL BE LOST!!!!
...
/
for the root realm, e.g. the only row where theparent
column hasNULL
value- {parent row's
fullPath
value}/
{current row'sname
value}
for any other row
For example:
id | name | parent | fullPath |
---|---|---|---|
8915e471-9683-4356-8c92-d2a6e1993de5 | / | NULL | / |
345f0a30-5a32-442c-bd7f-c1bbcdedf293 | child1 | 8915e471-9683-4356-8c92-d2a6e1993de5 | /child1 |
d419af73-fe15-4774-95be-131b6b1f1044 | child2 | 8915e471-9683-4356-8c92-d2a6e1993de5 | /child2 |
28807a32-1314-4a85-8fe2-0d59a1a05479 | nephew1 | 8915e471-9683-4356-8c92-d2a6e1993de5 | /child1/nephew1 |
Cleanup
Code Block | ||
---|---|---|
| ||
DROP TABLE ReportReportlet; -- this statement might be needed and adjusted to the effective constraint name ALTER TABLE Report DROP CONSTRAINT Report_ibfk_1; ALTER TABLE Report DROP COLUMN template_id; DROP TABLE ReportTemplate; |
Indexes
New indexes shall be created to improve overall performance.
PostgreSQL
Code Block | ||
---|---|---|
| ||
CREATE INDEX Realm_parent_id ON Realm(parent_id); |
...
CREATE INDEX Realm_fullPath ON Realm(fullPath); |
...
CREATE INDEX Realm_fullPath_startsWith ON Realm USING GIN (to_tsvector('english', fullPath)); |
Oracle |
...
MySQL | MariaDB
Code Block | ||
---|---|---|
| ||
CREATE INDEX Realm_parent_id ON Realm(parent_id); |
...
CREATE INDEX Realm_fullPath ON Realm(fullPath); |