You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: source/usage/database/historylog-optimization.md
+13-3Lines changed: 13 additions & 3 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -61,10 +61,13 @@ and an interface is added to allow code factorization.
61
61
`IHistoryEntityReference`)
62
62
63
63
In you project, you must:
64
-
* Replace `valueService.create(...` by `valueService.createHistoryValue(...`
65
-
or `valueService.createHistoryEventValue(...`
64
+
* Replace `valueService.create(...)` by `valueService.createHistoryValue(...)`
65
+
or `valueService.createHistoryEventValue(...)`
66
66
* Replace `HistoryValue` by `IHistoryValue`
67
67
* Rename `HistoryValueRenderer` to `IHistoryValueRenderer` (as it can render both types)
68
+
* Check that `HistoryValue` is strictly used on `HistoryLog` / `HistoryDifference`
69
+
(search `historyvalue` in `**/model/**/*.java`). It's normal if you have no reference
70
+
(on nominal case, type is declared only in Igloo).
68
71
69
72
### Option 1: switch to enum type
70
73
@@ -94,7 +97,14 @@ ALTER statements. They need to split fully-qualified entity name to keep only th
94
97
* Add your own field to the following update script:
95
98
96
99
```sql
97
-
-- Work in progress...
100
+
altertable historylog
101
+
alter column mainobject_reference_type type historylog_reference_type using substring(mainobject_reference_type from'[^.]+$')::historylog_reference_type,
102
+
alter column subject_reference_type type historylog_reference_type using substring(subject_reference_type from'[^.]+$')::historylog_reference_type,
103
+
alter column object1_reference_type type historylog_reference_type using substring(object1_reference_type from'[^.]+$')::historylog_reference_type,
104
+
alter column object2_reference_type type historylog_reference_type using substring(object2_reference_type from'[^.]+$')::historylog_reference_type,
105
+
alter column object3_reference_type type historylog_reference_type using substring(object3_reference_type from'[^.]+$')::historylog_reference_type,
106
+
alter column object4_reference_type type historylog_reference_type using substring(object4_reference_type from'[^.]+$')::historylog_reference_type
0 commit comments