Commit 647e536
fix: make ReceivingDate non-nullable with migration initialization
- Change ReceivingDate from nullable to non-nullable DateTime
- Update migration to add column as nullable first
- Initialize existing entries with SamplingDate (or current date if null)
- Alter column to be non-nullable after initialization
Co-authored-by: markusrt <299753+markusrt@users.noreply.github.com>1 parent 40cec57 commit 647e536
File tree
2 files changed
+13
-1
lines changed- NRZMyk.Services/Data
- Entities
- Migrations
2 files changed
+13
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
12 | 12 | | |
13 | 13 | | |
14 | 14 | | |
15 | | - | |
| 15 | + | |
16 | 16 | | |
17 | 17 | | |
18 | 18 | | |
| |||
Lines changed: 12 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
7 | 7 | | |
8 | 8 | | |
9 | 9 | | |
| 10 | + | |
10 | 11 | | |
11 | 12 | | |
12 | 13 | | |
13 | 14 | | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
14 | 26 | | |
15 | 27 | | |
16 | 28 | | |
| |||
0 commit comments