File size: 109,654 Bytes
8cb5fe4
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
1001
1002
1003
1004
1005
1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
1016
1017
1018
1019
1020
1021
1022
1023
1024
1025
1026
1027
1028
1029
1030
1031
1032
1033
1034
1035
1036
1037
1038
1039
1040
1041
1042
1043
1044
1045
1046
1047
1048
1049
1050
1051
1052
1053
1054
1055
1056
1057
1058
1059
1060
1061
1062
1063
1064
1065
1066
1067
1068
1069
1070
1071
1072
1073
1074
1075
1076
1077
1078
1079
1080
1081
1082
1083
1084
1085
1086
1087
1088
1089
1090
1091
1092
1093
1094
1095
1096
1097
1098
1099
1100
1101
1102
1103
1104
1105
1106
1107
1108
1109
1110
1111
1112
1113
1114
1115
1116
1117
1118
1119
1120
1121
1122
1123
1124
1125
1126
1127
1128
1129
1130
1131
1132
1133
1134
1135
1136
1137
1138
1139
1140
1141
1142
1143
1144
1145
1146
1147
1148
1149
1150
1151
1152
1153
1154
1155
1156
1157
1158
1159
1160
1161
1162
1163
1164
1165
1166
1167
1168
1169
1170
1171
1172
1173
1174
1175
1176
1177
1178
1179
1180
1181
1182
1183
1184
1185
1186
1187
1188
1189
1190
1191
1192
1193
1194
1195
1196
1197
1198
1199
1200
1201
1202
1203
1204
1205
1206
1207
1208
1209
1210
1211
1212
1213
1214
1215
1216
1217
1218
1219
1220
1221
1222
1223
1224
1225
1226
1227
1228
1229
1230
1231
1232
1233
1234
1235
1236
1237
1238
1239
1240
1241
1242
1243
1244
1245
1246
1247
1248
1249
1250
1251
1252
1253
1254
1255
1256
1257
1258
1259
1260
1261
1262
1263
1264
1265
1266
1267
1268
1269
1270
1271
1272
1273
1274
1275
1276
1277
1278
1279
1280
1281
1282
1283
1284
1285
1286
1287
1288
1289
1290
1291
1292
1293
1294
1295
1296
1297
1298
1299
1300
1301
1302
1303
1304
1305
1306
1307
1308
1309
1310
1311
1312
1313
1314
1315
1316
1317
1318
1319
1320
1321
1322
1323
1324
1325
1326
1327
1328
1329
1330
1331
1332
1333
1334
1335
1336
1337
1338
1339
1340
1341
1342
1343
1344
1345
1346
1347
1348
1349
1350
1351
1352
1353
1354
1355
1356
1357
1358
1359
1360
1361
1362
1363
1364
1365
1366
1367
1368
1369
1370
1371
1372
1373
1374
1375
1376
1377
1378
1379
1380
1381
1382
1383
1384
1385
1386
1387
1388
1389
1390
1391
1392
1393
1394
1395
1396
1397
1398
1399
1400
1401
1402
1403
1404
1405
1406
1407
1408
1409
1410
1411
1412
1413
1414
1415
1416
1417
1418
1419
1420
1421
1422
1423
1424
1425
1426
1427
1428
1429
1430
1431
1432
1433
1434
1435
1436
1437
1438
1439
1440
1441
1442
1443
1444
1445
1446
1447
1448
1449
1450
1451
1452
1453
1454
1455
1456
1457
1458
1459
1460
1461
USE [RMS5SQL]
GO
/****** Object:  Table [dbo].[apparatus]    Script Date: 2/26/2026 10:08:36 PM ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[apparatus](
	[apparatuskey] [char](14) NOT NULL,
	[incidentkey] [char](14) NULL,
	[apsid] [char](14) NULL,
	[apparatusid] [char](8) NULL,
	[priorityresponseflag] [bit] NULL,
	[arrivaldate] [datetime] NULL,
	[scenedate] [datetime] NULL,
	[enroutedate] [datetime] NULL,
	[FACILITYDATE] [datetime] NULL,
	[cleardate] [datetime] NULL,
	[dispatchdate] [datetime] NULL,
	[inservicedate] [datetime] NULL,
	[cancelledenrouteflag] [bit] NULL,
	[numberpeople] [int] NULL,
	[usecode] [char](4) NULL,
	[actiontaken1] [char](4) NULL,
	[actiontaken2] [char](4) NULL,
	[actiontaken3] [char](4) NULL,
	[actiontaken4] [char](4) NULL,
	[apparatustype] [char](4) NULL,
	[amount1] [money] NULL,
	[amount2] [money] NULL,
	[otherinfo] [char](20) NULL,
	[logcomments] [varchar](max) NULL,
	[fdid_no] [dbo].[udtfdid] NULL,
	[paramedicdispatch] [varchar](6) NULL,
	[firstarrivingunit] [dbo].[udtlogical] NULL,
	[inservicetime] [datetime] NULL,
	[respondfromquarters] [dbo].[udtlogical] NULL,
	[changedate] [datetime] NULL,
	[rowguid] [uniqueidentifier] ROWGUIDCOL  NOT NULL,
	[Hydrant_IDNumber] [varchar](20) NULL,
	[Hydrant_Location] [varchar](116) NULL,
	[alarms] [char](10) NULL,
	[lLosap_credit] [bit] NULL,
	[emsrun] [bit] NULL,
	[emsrunnumber] [varchar](14) NULL,
	[lProcessEPCR] [bit] NULL,
	[nEPCRRun] [int] NULL,
	[stagingDate] [datetime] NULL,
	[isepcr] [bit] NULL,
	[unit_exc] [char](10) NULL,
	[aedType] [varchar](10) NULL,
	[OdometerOnScene] [decimal](12, 2) NULL,
	[OdometerDestination] [decimal](12, 2) NULL,
	[MileageTransport] [decimal](12, 2) NULL,
	[AtPatientSideTime] [datetime] NULL,
	[created] [datetime] NOT NULL,
	[AerialDeviceUsed] [tinyint] NULL,
	[GMTOffSet] [varchar](6) NULL,
	[FirstEffectiveUnit] [tinyint] NULL,
	[lNFIRSExported] [bit] NULL,
	[NFIRSExportedDate] [datetime] NULL,
	[iNFIRSSequence] [tinyint] NULL,
	[NFIRSTransactiontype] [char](1) NULL,
	[Hydrant_Used] [tinyint] NULL,
	[defaultdispatchcode] [varchar](25) NULL,
	[responseTime] [varchar](20) NULL,
	[turnTime] [varchar](20) NULL,
 CONSTRAINT [APPARATUSK] PRIMARY KEY CLUSTERED 
(
	[apparatuskey] ASC
)WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON, FILLFACTOR = 90, OPTIMIZE_FOR_SEQUENTIAL_KEY = OFF) ON [PRIMARY]
) ON [PRIMARY] TEXTIMAGE_ON [PRIMARY]
GO
/****** Object:  View [dbo].[auv_incidentapparatus]    Script Date: 2/26/2026 10:08:36 PM ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
 
 CREATE view [dbo].[auv_incidentapparatus]
 AS
 
 SELECT  
 a.incidentkey, 
 a.apparatuskey, 
 a.apparatusid as apparatusid, 
 b.apsexternal as deptunitornotcode,
 deptunitornotdescrip = case when b.apsexternal = '0' then 'DeptUnit' else 'NotDeptUnit' end,
 a.priorityresponseflag as priorityresponsecode,
 priorityresponsedescrip = case when a.priorityresponseflag = '1' then 'Yes' else 'No' end,
 a.cancelledenrouteflag as cancelledenroutecode,
 cancelledenroutedescrip = case when a.cancelledenrouteflag = '1' then 'Yes' else 'No' end,
 a.firstarrivingunit as firstarrivingunitcode,
 firstarrivingunitdescrip = case when a.firstarrivingunit = '1' then 'Yes' else 'No' end,
 a.paramedicdispatch as dispatchtype,
 codesg.descrip as dispatchtypedescrip,
 a.respondfromquarters as respondedfromquarterscode,
 respondedfromquarterdescrip = case when a.respondfromquarters = '1' then 'Yes' else 'No' end,
 usecode as mainapparatususecode,
 mainapparatususedescrip = case when a.usecode = '0' then 'Other' else
 				case when a.usecode = '1' then 'Suppression' else
 				case when a.usecode = '2' then 'EMS' end end end,
 a.apparatustype as apparatustypecode,
 apparatustypedescrip = case when codesa.code = a.apparatustype then codesa.descrip else '' end,
 actiontaken1code = case when a.actiontaken1 is null then '' else a.actiontaken1 end,
 actiontaken1descip = case when a.actiontaken1 is null then '' else codesb.descrip end,
 actiontaken2code = case when a.actiontaken2 is null then '' else a.actiontaken2 end,
 actiontaken2descip = case when a.actiontaken2 is null then '' else codesc.descrip end,
 actiontaken3code = case when a.actiontaken3 is null then '' else a.actiontaken3 end,
 actiontaken3descip = case when a.actiontaken3 is null then '' else codesd.descrip end,
 actiontaken4code = case when a.actiontaken4 is null then '' else a.actiontaken4 end,
 actiontaken4descip = case when a.actiontaken4 is null then '' else codese.descrip end,
 numberpeople as numberofresponders,
 
 dispatchdatetime = case when (a.dispatchdate = '' or a.dispatchdate is null) then '' else a.dispatchdate end,
 dispatchtime = case when a.dispatchdate is null then '' else convert(char(10),a.dispatchdate,108) end,
 dispatchdate = case when a.dispatchdate is null then '' else convert(char(10),a.dispatchdate,101) end,
 dispatchenroutetime = convert(varchar(9), a.scenedate - a.dispatchdate, 8),
 dispatchenroutediffseconds = case when (a.scenedate = '' or a.scenedate is null or a.scenedate < '1950-12-30 00:00:00' or
 				a.dispatchdate = '' or a.dispatchdate is null or a.dispatchdate < '1950-12-30 00:00:00') 
 				then '' else datediff(s, a.dispatchdate, a.scenedate) end,
 
 enroutetoscenedatetime = case when (a.scenedate = '' or a.scenedate is null) then '' else a.scenedate end,
 enroutetoscenetime = case when a.scenedate is null then '' else convert(char(10),a.scenedate,108) end,
 enroutetoscenedate = case when a.scenedate is null then '' else convert(char(10),a.scenedate,101) end,
 enroutearrivalscenetime = convert(varchar(9), a.arrivaldate - a.scenedate, 8),
 enroutearrivalscenediffseconds = case when (a.arrivaldate = '' or a.arrivaldate is null or a.arrivaldate < '1950-12-30 00:00:00' or 
 				a.scenedate = '' or a.scenedate is null or a.scenedate < '1950-12-30 00:00:00') 
 				then '' else datediff(s, a.scenedate, a.arrivaldate) end,
 
 responsetime = convert(varchar(9), a.arrivaldate - a.dispatchdate, 8),
 responsetimeseconds = case when (a.arrivaldate = '' or a.arrivaldate is null or a.arrivaldate < '1950-12-30 00:00:00' or 
 				a.dispatchdate = '' or a.dispatchdate is null or a.dispatchdate < '1950-12-30 00:00:00') 
 				then '' else datediff(s, a.dispatchdate, a.arrivaldate) end,
 
 arrivaldatetime = case when (a.arrivaldate = '' or a.arrivaldate is null) then '' else a.arrivaldate end,
 arrivaltime = case when a.arrivaldate is null then '' else convert(char(10),a.arrivaldate,108) end,
 arrivaldate = case when a.arrivaldate is null then '' else convert(char(10),a.arrivaldate,101) end,
 arrivaltoenroutehospdifftime = convert(varchar(9), a.enroutedate - a.arrivaldate, 8),
 arrivaltoenroutehospdiffseconds = case when (a.arrivaldate = '' or a.arrivaldate is null or a.arrivaldate < '1950-12-30 00:00:00' or
 				a.enroutedate = '' or a.enroutedate is null or a.enroutedate < '1950-12-30 00:00:00') 
 				then '' else datediff(s, a.arrivaldate, a.enroutedate) end,
 
 enroutetohospitaldatetime = case when (a.enroutedate = '' or a.enroutedate is null) then '' else a.enroutedate end,
 enroutetohospitaltime = case when a.enroutedate is null then '' else convert(char(10),a.enroutedate,108) end,
 enroutetohospitaldate = case when a.enroutedate is null then '' else convert(char(10),a.enroutedate,101) end,
 enroutetoarrivalhospdifftime = convert(varchar(9), a.facilitydate - a.enroutedate, 8),
 enroutetoarrivalhospdiffseconds = case when (a.enroutedate = '' or a.enroutedate is null or 
 				a.facilitydate = '' or a.facilitydate is null) 
 				then '' else datediff(s, a.enroutedate, a.facilitydate) end,
 arrivalscenetoarrivalhospdifftime = convert(varchar(9), a.facilitydate - a.arrivaldate, 8),
 arrivalscenetoarrivalhospdiffseconds = case when (a.arrivaldate = '' or a.arrivaldate is null or a.arrivaldate < '1950-12-30 00:00:00' or
 				a.facilitydate = '' or a.facilitydate is null or a.facilitydate < '1950-12-30 00:00:00') 
 				then '' else datediff(s, a.arrivaldate, a.facilitydate) end,
 
 hospitalarrivaldatetime = case when (a.facilitydate = '' or a.facilitydate is null) then '' else a.facilitydate end,
 hospitalarrivaltime = case when a.facilitydate is null then '' else convert(char(10),a.facilitydate,108) end,
 hospitalarrivaldate = case when a.facilitydate is null then '' else convert(char(10),a.facilitydate,101) end,
 arrivalclearhospdifftime = convert(varchar(9), a.cleardate - a.facilitydate, 8),
 arrivalclearhospdiffseconds = case when (a.facilitydate = '' or a.facilitydate is null or a.facilitydate < '1950-12-30 00:00:00' or 
 				a.cleardate = '' or a.cleardate is null or a.cleardate < '1950-12-30 00:00:00') 
 				then '' else datediff(s, a.facilitydate, a.cleardate) end,
 
 cleardatetime = case when (a.cleardate = '' or a.cleardate is null) then '' else a.cleardate end,
 cleartime = case when a.cleardate is null then '' else convert(char(10),a.cleardate,108) end,
 cleardate = case when a.cleardate is null then '' else convert(char(10),a.cleardate,101) end,
 dispatchcleardifftime = convert(varchar(9), a.cleardate - a.dispatchdate, 8),
 dispatchcleardiffseconds = case when (a.cleardate = '' or a.cleardate is null or a.cleardate < '1950-12-30 00:00:00' or 
 				a.dispatchdate = '' or a.dispatchdate is null or a.dispatchdate < '1950-12-30 00:00:00') 
 				then '' else datediff(s, a.dispatchdate, a.cleardate) end,
 
 inservicedatetime = case when (a.inservicedate = '' or a.inservicedate is null) then '' else a.inservicedate end,
 inservicetime = case when a.inservicedate is null then '' else convert(char(10),a.inservicedate,108) end,
 inservicedate = case when a.inservicedate is null then '' else convert(char(10),a.inservicedate,101) end,
 a.emsrun as emsruncode,
 emsrundescrip = case when a.emsrun = '1' then 'EMS Run' else 'Not EMS Run' end,
 a.emsrunnumber,
 a.llosap_credit as losapcode,
 losapdescrip = case when a.llosap_credit = '1' then 'Losap Credit' else 'No Losap Credit' end,
 a.alarms as alarmscode,
 dpt1.descrip as alarmdescrip,
 a.amount1,
 a.amount2,
 a.fdid_no,
 stagingdatetime = case when (a.stagingDate = '' or a.stagingDate is null) then '' else a.stagingDate end,
 stagingtime = case when a.stagingDate is null then '' else convert(char(10),a.stagingDate,108) end,
 stagingdate = case when a.stagingDate is null then '' else convert(char(10),a.stagingDate,101) end,
 
 AtPatientSideDateTime = case when (a.AtPatientSideTime = '' or a.AtPatientSideTime is null) then '' else a.AtPatientSideTime end,
 AtPatientSideTime = case when a.AtPatientSideTime is null then '' else convert(char(10),a.AtPatientSideTime,108) end,
 AtPatientSideDate = case when a.AtPatientSideTime is null then '' else convert(char(10),a.AtPatientSideTime,101) end,
 
 FacilityDateTime = case when (a.FACILITYDATE = '' or a.FACILITYDATE is null) then '' else a.FACILITYDATE end,
 FacilityTime = case when a.FACILITYDATE is null then '' else convert(char(10),a.FACILITYDATE,108) end,
 FacilityDate = case when a.FACILITYDATE is null then '' else convert(char(10),a.FACILITYDATE,101) end,
 
 a.changedate
 
 
 from apparatus (nolock) as a
 left outer join app_bas (nolock) as b on a.apparatusid = b.appcode
 left outer join codes901 (nolock) as codesa on codesa.code = a.apparatustype and codesa.category = 'app_type'
 left outer join codes901 (nolock) as codesb on codesb.code = a.actiontaken1 and codesb.category = 'action'
 left outer join codes901 (nolock) as codesc on codesc.code = a.actiontaken2 and codesc.category = 'action'
 left outer join codes901 (nolock) as codesd on codesd.code = a.actiontaken3 and codesd.category = 'action'
 left outer join codes901 (nolock) as codese on codese.code = a.actiontaken4 and codese.category = 'action'
 left outer join codesems (nolock) as codesg on codesg.code = a.paramedicdispatch and codesg.category = 'paramedic'
 left outer join dptcodes (nolock) as dpt1 on dpt1.code = a.alarms and dpt1.category = 'alarms'
 
GO
/****** Object:  Table [dbo].[incident]    Script Date: 2/26/2026 10:08:36 PM ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[incident](
	[incidentkey] [char](14) NOT NULL,
	[incidentdate] [datetime] NULL,
	[incidentnumber] [char](10) NULL,
	[exposure] [char](3) NULL,
	[incidentstatus] [char](20) NULL,
	[reviewstatusflag] [bit] NOT NULL,
	[publicreleaseflag] [bit] NOT NULL,
	[completed] [bit] NOT NULL,
	[transactiontype] [char](4) NULL,
	[district] [char](10) NULL,
	[station] [char](30) NULL,
	[shift] [char](2) NULL,
	[company] [char](64) NULL,
	[incidenttype] [char](4) NOT NULL,
	[initialdispatchcode] [varchar](25) NULL,
	[mutualaidcode] [char](4) NOT NULL,
	[alarmdate] [datetime] NULL,
	[arrivaldate] [datetime] NULL,
	[didnotarriveflag] [bit] NOT NULL,
	[controlleddate] [datetime] NULL,
	[lastunitcleareddate] [datetime] NULL,
	[includemutualaidflag] [bit] NOT NULL,
	[madepartment] [char](30) NULL,
	[madeptincidentno] [char](9) NULL,
	[alarms] [int] NULL,
	[actiontaken1] [char](4) NULL,
	[actiontaken2] [char](4) NULL,
	[actiontaken3] [char](4) NULL,
	[resourceformusedflag] [bit] NOT NULL,
	[apparatussuppression] [int] NULL,
	[apparatusems] [int] NULL,
	[apparatusother] [int] NULL,
	[personnelsuppression] [int] NULL,
	[personnelems] [int] NULL,
	[personnelother] [int] NULL,
	[lossproperty] [money] NULL,
	[losscontents] [money] NULL,
	[valueproperty] [money] NULL,
	[valuecontents] [money] NULL,
	[fatalfireservice] [int] NULL,
	[fatalother] [int] NULL,
	[nonfatalfireservice] [int] NULL,
	[nonfatalother] [int] NULL,
	[detector] [char](4) NULL,
	[hazardmaterialreleased] [char](4) NULL,
	[mixeduse] [char](4) NULL,
	[propertyuse] [char](4) NULL,
	[emsprovidedflag] [bit] NOT NULL,
	[casualtiesflag] [tinyint] NULL,
	[priorityresponseflag] [bit] NULL,
	[vendorid] [char](20) NULL,
	[locationtype] [float] NULL,
	[censustract] [char](7) NULL,
	[numberormile] [char](8) NULL,
	[streetprefix] [char](2) NULL,
	[streethighway] [char](30) NULL,
	[streettype] [char](4) NULL,
	[streetsuffix] [char](2) NULL,
	[apartment] [char](15) NULL,
	[city] [char](20) NULL,
	[state] [char](2) NULL,
	[postalcode] [char](20) NULL,
	[crossstreetprefix] [char](2) NULL,
	[crossstreethighway] [char](30) NULL,
	[crossstreettype] [char](4) NULL,
	[crossstreetsuffix] [char](2) NULL,
	[directions] [varchar](max) NULL,
	[latitude] [char](20) NULL,
	[longitude] [char](20) NULL,
	[meridian] [char](20) NULL,
	[northsouth] [char](1) NULL,
	[eastwest] [char](1) NULL,
	[subsection] [char](4) NULL,
	[section] [int] NULL,
	[range] [int] NULL,
	[township] [decimal](5, 1) NULL,
	[compositeaddress] [char](50) NOT NULL,
	[MAAPPARATUSSUPPRESSION] [int] NULL,
	[MAAPPARATUSEMS] [int] NULL,
	[MAAPPARATUSOTHER] [int] NULL,
	[MAPERSONNELSUPPRESSION] [int] NULL,
	[MAPERSONNELEMS] [int] NULL,
	[MAPERSONNELOTHER] [int] NULL,
	[useoptionaltabs] [bit] NULL,
	[fdid_no] [char](5) NULL,
	[madeptstate] [char](2) NULL,
	[appversion] [char](10) NULL,
	[county] [varchar](20) NULL,
	[CityOther] [char](15) NULL,
	[occupancykey] [char](14) NULL,
	[occupancynumber] [char](16) NULL,
	[occupancyname] [char](40) NULL,
	[runcard] [char](8) NULL,
	[mappage] [char](20) NULL,
	[descrip] [char](30) NULL,
	[SubstitudeFireForm] [dbo].[udtlogical] NULL,
	[addressvalidated] [tinyint] NULL,
	[CADCompleted] [bit] NULL,
	[changedate] [datetime] NULL,
	[rowguid] [uniqueidentifier] ROWGUIDCOL  NOT NULL,
	[OtherInfo] [varchar](20) NULL,
	[LogComments] [varchar](max) NULL,
	[CO_Flag] [bit] NULL,
	[Alarm_Trans] [char](4) NULL,
	[Incident_ID] [int] NOT NULL,
	[loss_not_known] [bit] NOT NULL,
	[iMobile] [tinyint] NULL,
	[collecteddate] [datetime] NULL,
	[DispatchIncType] [varchar](80) NULL,
	[nfscasualtycnt] [smallint] NULL,
	[ncivcasualtycnt] [smallint] NULL,
	[nEstKMDistance] [smallint] NULL,
	[ofm_nbrrescued] [smallint] NULL,
	[criticalincident] [char](1) NULL,
	[teammobilized] [char](1) NULL,
	[psaptime] [datetime] NULL,
	[circumstance1] [varchar](10) NULL,
	[circumstance2] [varchar](10) NULL,
	[circumstance3] [varchar](10) NULL,
	[lArsonFlag] [bit] NULL,
	[ReportedBy] [varchar](8) NULL,
	[lReExport] [bit] NULL,
	[XCoord] [char](20) NULL,
	[YCoord] [char](20) NULL,
	[lValidated] [bit] NULL,
	[isEPCR] [bit] NULL,
	[ofm_mutualaid] [char](10) NULL,
	[EMSModule] [tinyint] NULL,
	[inc_exc] [char](10) NULL,
	[CensusArea] [char](10) NULL,
	[finaldispatchcode] [varchar](25) NULL,
	[created] [datetime] NOT NULL,
	[ResponseType] [varchar](10) NULL,
	[CADText1] [varchar](50) NULL,
	[CADText2] [varchar](50) NULL,
	[CADText3] [varchar](50) NULL,
	[CADCombo1] [varchar](50) NULL,
	[CADCombo2] [varchar](50) NULL,
	[CADCombo3] [varchar](50) NULL,
	[GMTOffSet] [varchar](6) NULL,
	[CADDate1] [datetime] NULL,
	[CADDate2] [datetime] NULL,
	[CADDate3] [datetime] NULL,
	[WaterOnFireDate] [datetime] NULL,
	[PriSearchCompDate] [datetime] NULL,
	[SecSearchCompDate] [datetime] NULL,
	[AllClearDate] [datetime] NULL,
	[LossStoppedDate] [datetime] NULL,
	[CustStabilizedDate] [datetime] NULL,
	[Investigations_Notified] [tinyint] NULL,
	[Extrication] [bit] NOT NULL,
	[ApparatusImported] [bit] NULL,
	[lHazMatTabFlag] [bit] NULL,
	[responseTime] [varchar](20) NULL,
	[ProQA] [varchar](100) NULL,
	[turnTime] [varchar](20) NULL,
	[Mapset] [varchar](6) NULL,
	[Easting] [varchar](5) NULL,
	[Northing] [varchar](5) NULL,
 CONSTRAINT [INCIDENTKEy] PRIMARY KEY CLUSTERED 
(
	[incidentkey] ASC
)WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON, FILLFACTOR = 90, OPTIMIZE_FOR_SEQUENTIAL_KEY = OFF) ON [PRIMARY]
) ON [PRIMARY] TEXTIMAGE_ON [PRIMARY]
GO
/****** Object:  View [dbo].[auv_incidentbase]    Script Date: 2/26/2026 10:08:36 PM ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
 
 CREATE view [dbo].[auv_incidentbase]
 AS
 
 Select a.incidentkey,
 a.incidentnumber as IncidentNumber,
 a.exposure as IncidentExposureNumber,
 a.completed as CompletedReportCode,
 CompletedReportDescrip = case when a.completed = '1' then 'Completed' else 'Not Completed' end,
 a.reviewstatusflag as ReviewedReportCode,
 ReviewReportDescrip = case when a.reviewstatusflag = '1' then 'Reviewed' else 'Not Reviewed' end,
 a.publicreleaseflag as PublicReleaseReportCode,
 PublicReleaseReportDEscrip = case when a.publicreleaseflag = '1' then 'Released' else 'Not Released' end,
 a.didnotarriveflag as DidNotArriveCode,
 DidNotArriveDescrip = case when a.didnotarriveflag = '1' then 'Did Not Arrive' else 'Did Arrive' end,
 AlarmDateTime = case when (a.alarmdate = '' or a.alarmdate is null) then '' else a.alarmdate end,
 Alarmtime = case when a.alarmdate is null then '' else convert(char(10),a.alarmdate,108) end,
 Alarmdate = case when a.alarmdate is null then '' else convert(char(10),a.alarmdate,101) end,
 
 ArrivalDateTime = case when (a.arrivaldate = '' or a.arrivaldate is null) then '' else a.arrivaldate end,
 Arrivaltime = case when a.arrivaldate is null then '' else convert(char(10),a.arrivaldate,108) end,
 Arrivaldate = case when a.arrivaldate is null then '' else convert(char(10),a.arrivaldate,101) end,
 
 ControlledDateTime = case when (a.controlleddate = '' or a.controlleddate is null) then '' else a.controlleddate end,
 Controlledtime = case when a.controlleddate is null then '' else convert(char(10),a.controlleddate,108) end,
 Controlleddate = case when a.controlleddate is null then '' else convert(char(10),a.controlleddate,101) end,
 
 ClearedDateTime = case when (a.lastunitcleareddate = '' or a.lastunitcleareddate is null) then '' else a.lastunitcleareddate end,
 Clearedtime = case when a.lastunitcleareddate is null then '' else convert(char(10),a.lastunitcleareddate,108) end,
 Cleareddate = case when a.lastunitcleareddate is null then '' else convert(char(10),a.lastunitcleareddate,101) end,
 
 ResponseTime = case when (a.alarmdate = '' or a.alarmdate is null or a.alarmdate < '1950-12-30 00:00:00' or
 		a.arrivaldate = '' or a.arrivaldate is null or a.arrivaldate < '1950-12-30 00:00:00') 
 		then '' else str(DATEDIFF(ss,a.alarmdate,a.arrivaldate)/60,2)+':'+
 		replace(STR(DATEDIFF(ss,a.alarmdate,a.arrivaldate)%60,2),' ','0') end,
 
 ResponseTimediffseconds = case when (a.alarmdate = '' or a.alarmdate is null or a.alarmdate < '1950-12-30 00:00:00' or
 			a.arrivaldate = '' or a.arrivaldate is null or a.arrivaldate < '1950-12-30 00:00:00') 
 			then '' else datediff(s, a.alarmdate, a.arrivaldate) end,
 
 /* IncidentTotalTime = convert(varchar(9), a.lastunitcleareddate - a.alarmdate, 8),*/
 
 IncidentTotalTime1 = case when (a.alarmdate = '' or a.alarmdate is null or a.alarmdate < '1950-12-30 00:00:00' or
 		a.lastunitcleareddate = '' or a.lastunitcleareddate is null or a.lastunitcleareddate < '1950-12-30 00:00:00') 
 		then '' else replace((DATEDIFF(mi,a.alarmdate,a.lastunitcleareddate)/60) ,' ','0') + ':' + 
 		replace(str(DATEDIFF(ss,a.alarmdate,a.lastunitcleareddate)/60%60,2) ,' ','0') + ':' + 
 		replace(STR(DATEDIFF(ss,a.alarmdate,a.lastunitcleareddate)%60,2),' ','0') end,
 
 IncidentTotalTimediffseconds = case when (a.alarmdate = '' or a.alarmdate is null or a.alarmdate < '1950-12-30 00:00:00' or
 			a.lastunitcleareddate = '' or a.lastunitcleareddate is null or a.lastunitcleareddate < '1950-12-30 00:00:00') 
 			then '' else datediff(s, a.alarmdate, a.lastunitcleareddate) end,
 
 District = case when (a.district is null or a.district = '') then ''  else a.district end,
 Station = case when (a.station is null or a.station = '') then ''  else a.station end,
 Shift = case when (a.shift is null or a.shift = '') then ''  else a.shift end,
 Alarms = case when (a.alarms is null or a.alarms = '') then '' else a.alarms end,
 
 IncidentTypeCode = case when (a.incidenttype is null or a.incidenttype = '') then '' else a.incidenttype end,
 IncidentTypeDescrip = case when (a.incidenttype is null or a.incidenttype = '') then '' else nfirsa.descrip end,
 InitialDispatchCode = case when a.initialdispatchcode is null then '' else a.initialdispatchcode end,
 
 a.includemutualaidflag as MutualAidFlagCode,
 MutualAidTypeCode = case when a.mutualaidcode is null then '' else a.mutualaidcode end,
 MutualAidTypeDescrip = case when a.mutualaidcode is null then '' else nfirsb.descrip end,
 MutalAidIncidentNo = case when a.madeptincidentno is null then '' else a.madeptincidentno end,
 
 actiontaken1code = case when a.actiontaken1 is null then '' else a.actiontaken1 end,
 actiontaken1descip = case when a.actiontaken1 is null then '' else codesb.descrip end,
 actiontaken2code = case when a.actiontaken2 is null then '' else a.actiontaken2 end,
 actiontaken2descip = case when a.actiontaken2 is null then '' else codesc.descrip end,
 actiontaken3code = case when a.actiontaken3 is null then '' else a.actiontaken3 end,
 actiontaken3descip = case when a.actiontaken3 is null then '' else codesd.descrip end,
 
 ApparatusSuppressionCount = case when a.apparatussuppression is null then '' else a.apparatussuppression end,
 ApparatusEMSCount = case when a.apparatusems is null then '' else a.apparatusems end,
 ApparatusOtherCount = case when a.apparatusother is null then '' else a.apparatusother end,
 ApparatusTotalCount = a.apparatussuppression + a.apparatusems + a.apparatusother,
 
 PersonnelSuppressionCount = case when a.personnelsuppression is null then '' else a.personnelsuppression end,
 PersonnelEMSCount = case when a.personnelems is null then '' else a.personnelems end,
 PersonnelOtherCount = case when a.personnelother is null then '' else a.personnelother end,
 PersonnelTotalCount = a.personnelsuppression + a.personnelems + a.personnelother,
 
 MAidApparatusSuppressionCount = case when a.maapparatussuppression is null then '' else a.maapparatussuppression end,
 MAidApparatusEMSCount = case when a.maapparatusems is null then '' else a.maapparatusems end,
 MAidApparatusOtherCount = case when a.maapparatusother is null then '' else a.maapparatusother end,
 MAidApparatusTotalCount = case when (a.maapparatussuppression + a.maapparatusems + a.maapparatusother) is null then ''
 				else (a.maapparatussuppression + a.maapparatusems + a.maapparatusother) end,
 
 MAidPersonnelSuppressionCount = case when a.mapersonnelsuppression is null then '' else a.mapersonnelsuppression end,
 MaidPersonnelEMSCount = case when a.mapersonnelems is null then '' else a.mapersonnelems end,
 MAidPersonnelOtherCount = case when a.mapersonnelother is null then '' else a.mapersonnelother end,
 MaidPersonnelTotalCount = case when (a.mapersonnelsuppression + a.mapersonnelems + a.mapersonnelother) is null then '' 
 				else (a.mapersonnelsuppression + a.mapersonnelems + a.mapersonnelother) end,
 
 a.lossproperty as LossProperty,
 a.losscontents as LossContents,
 a.valueproperty as ValueProperty,
 a.valuecontents as ValueContents,
 LossTotal = a.lossproperty + a.losscontents,
 ValueTotal = a.valueproperty + a.valuecontents,
 ValueSaved = (a.valueproperty + a.valuecontents) - (a.lossproperty + a.losscontents),
 
 DetectorAlertedCode = case when a.detector is null then '' else a.detector end,
 DetectorAlertedDescrip = case when a.detector is null then '' else nfirsc.descrip end,
 
 HazardMaterialReleasedCode = case when a.hazardmaterialreleased is null then '' else a.hazardmaterialreleased end,
 HazardMaterialReleasedDescrip = case when a.hazardmaterialreleased is null then '' else nfirsd.descrip end,
 
 PropertyUseCode = case when a.propertyuse is null then '' else a.propertyuse end,
 PropertyUseDescrip = case when a.propertyuse is null then '' else nfirse.descrip end,
 
 MixedUseCode = case when a.mixeduse is null then '' else a.mixeduse end,
 MixedUseDescrip = case when a.mixeduse is null then '' else nfirsf.descrip end,
 
 a.numberormile as StreetNumber,
 a.streetprefix as StreetPrefix,
 a.streethighway as StreetName,
 a.streettype as StreetType,
 a.streetsuffix as StreetSuffix,
 a.apartment as Apartment,
 a.city as City,
 a.state as State,
 a.postalcode as ZipCode,
 
 AddressComposite = case when a.numberormile = '' then '' else (rtrim(a.numberormile) + ' ') end +
 	case when a.streetprefix = '' then '' else (rtrim(a.streetprefix) + ' ') end +
 	case when a.streethighway = '' then '' else (rtrim(a.streethighway) + ' ') end +
 	case when a.streettype = '' then '' else (rtrim(a.streettype) + ' ') end +
 	case when a.streetsuffix = '' then '' else (rtrim(a.streetsuffix)+ ' ') end +
 	case when a.apartment = '' then '' else rtrim(a.apartment) end, 
 
 CityStateZipComposite = rtrim(a.city) + ', ' + a.state + ' ' + a.postalcode,
 
 a.censustract as CensusTract,
 a.emsprovidedflag as EmsProvidedCode,
 EMSProvidedDescrip = case when a.emsprovidedflag = '1' then 'EMS Provided' else 'No EMS Provided' end,
 a.locationtype as LocationTypeCode,
 LocationTypeDescrip = case when a.locationtype = '1' then 'Address' else 
 			case when a.locationtype = '2' then 'Intersection' else
 			case when a.locationtype = '3' then 'In Front of' else
 			case when a.locationtype = '4' then 'In Rear of' else
 			case when a.locationtype = '5' then 'Adjacent to' else
 			case when a.locationtype = '6' then 'Directions' else
 			case when a.locationtype = '7' then 'U.S. National Grid' else
 			case when a.locationtype = '8' then 'Latitude/Longitude' else
 			case when a.locationtype = '9' then 'Township'
 			end end end end end end end end end,
 a.fatalfireservice as fatalfireservicecode,
 fatalfireservicedescrip = case when a.fatalfireservice = '1' then 'Fire Service Fatality' else '' end,
 a.fatalother as fatalciviliancode,
 fatalciviliandescrip = case when a.fatalother = '1' then 'Non Fire Service Fatality' else '' end, 
 a.nonfatalfireservice as injuredfireservicecode,
 injuredfireservicedescrip = case when a.nonfatalfireservice = '1' then 'Fire Service Injury' else '' end,
 a.nonfatalother as injuredciviliancode,
 injuredciviliandescrip = case when a.nonfatalother = '1' then 'Non Fire Service Injury' else '' end,
 a.casualtiesflag as casualtiescode,
 casualtiesdescrip = case when a.casualtiesflag = '1' then 'Casualties Incident' else '' end,
 a.priorityresponseflag as priorityrespcode,
 priorityrespdescrip = case when a.priorityresponseflag = '1' then 'Priority Response' else '' end,
 a.crossstreetprefix,
 a.crossstreethighway as crossstreetname,
 a.crossstreettype,
 a.crossstreetsuffix,
 CrossStreetComposite = case when a.crossstreetprefix = '' then '' else (rtrim(a.crossstreetprefix) + ' ') end +
 	case when a.crossstreethighway = '' then '' else (rtrim(a.crossstreethighway) + ' ') end +
 	case when a.crossstreettype = '' then '' else (rtrim(a.crossstreettype) + ' ') end +
 	case when a.crossstreetsuffix = '' then '' else (rtrim(a.crossstreetsuffix)+ ' ') end, 
 
 a.directions,
 a.county,
 a.mappage,
 a.collecteddate,
 a.imobile as imobilecode,
 imobiledescrip = case when a.imobile = '1' then 'Mobile Record' else 'Not Mobile Record' end,
 a.loss_not_known as lossnotknowncode,
 lossnotknowndescrip = case when a.loss_not_known = '1' then 'Loss Not Known' else '' end,
 a.addressvalidated as addressvalidatedcode,
 addressvalidateddescrip = case when a.addressvalidated = '1' then 'Address Validated' else 'Address Not Validated' end,
 b.call_out_requested_by as hwycalloutrequestby,
 b.investigating_police as hwyinvestpolicecode,
 dptb.descrip as hwyinvetpolicedescrip,
 b.officer as hwyofficer,
 b.badge_number as hwybadgenumber,
 b.police_report_number as hwyreportnumber,
 b.cause_of_emergency as hwycauseemergcode,
 dptc.descrip as hwycauseemergdescrip,
 b.coe_other as hwycauseotherdescrip,
 b.location_of_emergency as hwyloecode,
 dptd.descrip as hwyloedescrip,
 b.loe_other as hwyloeotherdescrip,
 b.obstruction as hwyobstrcutioncode,
 dpte.descrip as hwyobstructiondescrip,
 b.obstruction_other as hwyobstructionotherdescrip,
 b.no_services_performed as hwynoservicecode,
 hwynoservicedescrip = case when b.no_services_performed = '1' then 'No Sercices Performed' else '' end,
 b.extinguish_performed as hwyextinguishcode,
 hwyextinguishdescrip = case when b.extinguish_performed= '1' then 'Extinguish Performed' else '' end,
 b.cleanup_performed as hwycleanupcode,
 hwycleanupdescrip = case when b.cleanup_performed = '1' then 'Cleanup Performed' else '' end,
 b.extraction_performed as hwyextractioncode,
 hwyextractiodescrip = case when b.extraction_performed = '1' then 'Extraction Performed' else '' end,
 b.first_aid_performed as hwyfirstaidcode,
 hwyfirstaidedescrip = case when b.first_aid_performed = '1' then 'First Aid Performed' else '' end,
 b.highway_damage as hwydamagecode,
 hwydamagedescrip = case when b.highway_damage = '1' then 'Highway Property Damage' else '' end,
 b.private_damage as hwyprivatedamcode,
 hwyprivatedescrip = case when b.private_damage = '1' then 'Private Property Damage' else '' end,
 b.city_damage as hwycitycode,
 hwycitydescrip = case when b.city_damage = '1' then 'City Property Damage' else '' end,
 b.other_damage as hwyothercode,
 hwynotherdescrip = case when b.other_damage = '1' then 'Other Property Damage' else '' end,
 b.other_damage_other as hwyothertext,
 b.water_used,
 b.water_used_quantity,
 b.foam_used,
 b.foam_used_quantity,
 b.oilzorb_used,
 b.oilzorb_used_quantity,
 b.other_used,
 b.other_used_quantity,
 
 c.det_present as codetectpresentcode,
 codetectpresentdescrip = case when c.det_present = '1' then 'CO Detector Present' else 'No CO Dectector Present' end,
 c.det_type as cotypecode,
 nfirsg.descrip as cotypedescrip,
 c.det_pwrsply as copowersupplycode,
 nfirsh.descrip as copowersupplydescrip,
 c.det_operation as cooperationcode,
 nfirsi.descrip as cooperationdescrip,
 c.det_effective as coeffectivecode,
 nfirsj.descrip as coeffectivedescrip,
 c.det_failure as cofailurecode,
 nfirsk.descrip as cofailuredescrip,
 c.det_mfg as codetectormfg,
 c.det_model as codetectormodel,
 c.co_children as cochildrencount,
 c.co_youths as coyouthscount,
 c.co_adults as coadultscount,
 c.co_seniors as coseniorscount,
 
 auth1.sequence as membersequence,
 memberdescrip = case when auth1.sequence = '1' then 'Member Making Report' else '' end,
 auth1.personnelid as memberidnumber,
 auth1.lastname as membernamelast,
 auth1.firstname as membernamefirst,
 auth1.middleinitial as membermi,
 membernamefirstlast = rtrim(auth1.firstname) + ' ' + rtrim(auth1.lastname),	
 membernamelastfirst = rtrim(auth1.lastname) + ', ' + rtrim(auth1.firstname),
 membernamefull = rtrim(auth1.firstname) + ' ' +
 	case when auth1.middleinitial is null then '' else rtrim(auth1.middleinitial) + ' ' end +
 	rtrim(auth1.lastname),
 auth1.rank as memberpositioncode,
 dptf.descrip as memberpositiondescrip,
 auth1.assignment as memberassignmentcode,
 dptg.descrip as memberassignmentdescrip,
 auth1.authoritydate as memberdatetime,
 membertime = case when auth1.authoritydate is null then '' else convert(char(10),auth1.authoritydate,108) end,
 memberdate = case when auth1.authoritydate is null then '' else convert(char(10),auth1.authoritydate,101) end,
 
 auth2.sequence as officersequence,
 officerdescrip = case when auth2.sequence = '2' then 'Officer in Charge' else '' end,
 auth2.personnelid as officeridnumber,
 auth2.lastname as officernamelast,
 auth2.firstname as officernamefirst,
 auth2.middleinitial as officermi,
 officernamefirstlast = rtrim(auth2.firstname) + ' ' + rtrim(auth2.lastname),	
 officernamelastfirst = rtrim(auth2.lastname) + ', ' + rtrim(auth2.firstname),
 officernamefull = rtrim(auth2.firstname) + ' ' +
 	case when auth2.middleinitial is null then '' else rtrim(auth2.middleinitial) + ' ' end +
 	rtrim(auth2.lastname),
 auth2.rank as officerpositioncode,
 dpth.descrip as officerpositiondescrip,
 auth2.assignment as officerassignmentcode,
 dpti.descrip as officerassignmentdescrip,
 auth2.authoritydate as officerdatetime,
 officertime = case when auth2.authoritydate is null then '' else convert(char(10),auth2.authoritydate,108) end,
 officerdate = case when auth2.authoritydate is null then '' else convert(char(10),auth2.authoritydate,101) end,
 
 auth3.sequence as reviewersequence,
 reviewerdescrip = case when auth3.sequence = '3' then 'Reviewer' else '' end,
 auth3.personnelid as revieweridnumber,
 auth3.lastname as reviewernamelast,
 auth3.firstname as reviewernamefirst,
 auth3.middleinitial as reviewermi,
 reviewernamefirstlast = rtrim(auth3.firstname) + ' ' + rtrim(auth3.lastname),	
 reviewernamelastfirst = rtrim(auth3.lastname) + ', ' + rtrim(auth3.firstname),
 reviewernamefull = rtrim(auth3.firstname) + ' ' +
 	case when auth3.middleinitial is null then '' else rtrim(auth3.middleinitial) + ' ' end +
 	rtrim(auth3.lastname),
 auth3.rank as reviewerpositioncode,
 dptj.descrip as reviewerpositiondescrip,
 auth3.assignment as reviewerassignmentcode,
 dptk.descrip as reviewerassignmentdescrip,
 auth3.authoritydate as reviewerdatetime,
 reviewertime = case when auth3.authoritydate is null then '' else convert(char(10),auth3.authoritydate,108) end,
 reviewerdate = case when auth3.authoritydate is null then '' else convert(char(10),auth3.authoritydate,101) end,
 
 finaldispatchcode = case when a.finaldispatchcode is null then '' else a.finaldispatchcode end,
 PSAPDateTime = case when (a.psaptime = '' or a.psaptime is null) then '' else a.psaptime end,
 PSAPtime = case when a.psaptime is null then '' else convert(char(10),a.psaptime,108) end,
 PSAPdate = case when a.psaptime is null then '' else convert(char(10),a.psaptime,101) end,
 
 a.latitude,
 a.longitude,
 a.changedate,
 
 IncidentDateTime = case when (a.incidentdate = '' or a.incidentdate is null) then '' else a.incidentdate end,
 Incidenttime = case when a.incidentdate is null then '' else convert(char(10),a.incidentdate,108) end,
 Incidentdate = case when a.incidentdate is null then '' else convert(char(10),a.incidentdate,101) end
 
 
 from incident (nolock) as a
 
 left outer join incidentsupplemental (nolock) as b on b.incidentkey = a.incidentkey
 left outer join carbonmonoxide (nolock) as c on c.incidentkey = a.incidentkey
 
 left outer join authority (nolock) as auth1 on auth1.incidentkey = a.incidentkey and auth1.sequence = '1'
 left outer join authority (nolock) as auth2 on auth2.incidentkey = a.incidentkey and auth2.sequence = '2'
 left outer join authority (nolock) as auth3 on auth3.incidentkey = a.incidentkey and auth3.sequence = '3'
 
 left outer join codes901 (nolock) as nfirsa on nfirsa.code = a.incidenttype and nfirsa.category = 'incident'
 left outer join codes901 (nolock) as nfirsb on nfirsb.code = a.mutualaidcode and nfirsb.category = 'aid'
 left outer join codes901 (nolock) as nfirsc on nfirsc.code = a.detector and nfirsc.category = 'det_alrt'
 left outer join codes901 (nolock)  as nfirsd on nfirsd.code = a.hazardmaterialreleased and nfirsd.category = 'haz_rel'
 left outer join codes901 (nolock) as nfirse on nfirse.code = a.propertyuse and nfirse.category = 'prop_use'
 left outer join codes901 (nolock) as nfirsf on nfirsf.code = a.mixeduse and nfirsf.category = 'mixeduse'
 left outer join codes901 (nolock) as nfirsg on nfirsg.code = c.det_type and nfirsg.category = 'det_type'
 left outer join codes901 (nolock) as nfirsh on nfirsh.code = c.det_pwrsply and nfirsh.category = 'det_pow'
 left outer join codes901 (nolock) as nfirsi on nfirsi.code = c.det_operation and nfirsi.category = 'det_oper'
 left outer join codes901 (nolock) as nfirsj on nfirsj.code = c.det_effective and nfirsj.category = 'det_eff'
 left outer join codes901 (nolock) as nfirsk on nfirsk.code = c.det_failure and nfirsk.category = 'det_fail'
 
 left outer join codes901 (nolock) as codesb on codesb.code = a.actiontaken1 and codesb.category = 'action'
 left outer join codes901 (nolock) as codesc on codesc.code = a.actiontaken2 and codesc.category = 'action'
 left outer join codes901 (nolock) as codesd on codesd.code = a.actiontaken3 and codesd.category = 'action'
 
 left outer join dptcodes (nolock) as dpta on dpta.code = a.madepartment and dpta.category = 'agency'
 left outer join dptcodes (nolock) as dptb on dptb.code = b.investigating_police and dptb.category = 'npolice'
 left outer join dptcodes (nolock) as dptc on dptc.code = b.cause_of_emergency and dptc.category = 'ncoe'
 left outer join dptcodes (nolock) as dptd on dptd.code = b.location_of_emergency and dptd.category = 'nloe'
 left outer join dptcodes (nolock) as dpte on dpte.code = b.obstruction and dpte.category = 'nobstruc'
 left outer join dptcodes (nolock) as dptf on dptf.code = auth1.rank and dptf.category = 'position'
 left outer join codes901 (nolock) as dptg on dptg.code = auth1.assignment and dptg.category = 'assign'
 left outer join dptcodes (nolock) as dpth on dpth.code = auth2.rank and dpth.category = 'position'
 left outer join codes901 (nolock) as dpti on dpti.code = auth2.assignment and dpti.category = 'assign'
 left outer join dptcodes (nolock) as dptj on dptj.code = auth3.rank and dptj.category = 'position'
 left outer join codes901 (nolock) as dptk on dptk.code = auth3.assignment and dptk.category = 'assign'
 
GO
/****** Object:  Table [dbo].[personnel]    Script Date: 2/26/2026 10:08:36 PM ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[personnel](
	[personnelkey] [char](14) NOT NULL,
	[incidentkey] [char](14) NOT NULL,
	[apparatuskey] [char](14) NULL,
	[pslid] [char](14) NULL,
	[rosid] [char](14) NULL,
	[personnelid] [char](9) NULL,
	[lastname] [char](25) NULL,
	[firstname] [char](25) NULL,
	[middleinitial] [char](1) NULL,
	[namesuffix] [char](4) NULL,
	[rank] [char](10) NULL,
	[actiontaken1] [char](4) NULL,
	[actiontaken2] [char](4) NULL,
	[actiontaken3] [char](4) NULL,
	[actiontaken4] [char](4) NULL,
	[amount1] [money] NULL,
	[amount2] [money] NULL,
	[changedate] [datetime] NULL,
	[rowguid] [uniqueidentifier] ROWGUIDCOL  NOT NULL,
	[crole] [char](4) NULL,
	[lLosap_credit] [bit] NULL,
	[MedCert] [char](4) NULL,
	[cAdditionalRole] [varchar](8) NULL,
	[AgencyID] [varchar](14) NULL,
	[AgencyDesc] [varchar](40) NULL,
	[AgencyCode] [varchar](8) NULL,
	[lNFIRSExported] [bit] NULL,
	[NFIRSExportedDate] [datetime] NULL,
	[iNFIRSSequence] [tinyint] NULL,
	[NFIRSTransactiontype] [char](1) NULL,
 CONSTRAINT [personnelk] PRIMARY KEY CLUSTERED 
(
	[personnelkey] ASC
)WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON, FILLFACTOR = 90, OPTIMIZE_FOR_SEQUENTIAL_KEY = OFF) ON [PRIMARY]
) ON [PRIMARY]
GO
/****** Object:  View [dbo].[auv_incidentpersonnel]    Script Date: 2/26/2026 10:08:36 PM ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
 
 CREATE view [dbo].[auv_incidentpersonnel]
 AS
 
 SELECT a.incidentkey,
 a.apparatuskey,
 a.pslid,
 a.personnelid,
 a.firstname as namefirst,
 a.middleinitial as namemi,
 a.lastname as namelast,
 a.namesuffix,
 namefirstlast = rtrim(a.firstname) + ' ' + rtrim(a.lastname),	
 namelastfirst = rtrim(a.lastname) + ', ' + rtrim(a.firstname),
 namefull = rtrim(a.firstname) + ' ' +
 	case when a.middleinitial = '' then '' else rtrim(a.middleinitial) + ' ' end +
 	rtrim(a.lastname) + ' ' + case when a.namesuffix is null then '' else  rtrim(a.namesuffix) end,
 
 a.rank, 
 actiontaken1code = case when a.actiontaken1 is null then '' else a.actiontaken1 end,
 actiontaken1descip = case when a.actiontaken1 is null then '' else codesb.descrip end,
 actiontaken2code = case when a.actiontaken2 is null then '' else a.actiontaken2 end,
 actiontaken2descip = case when a.actiontaken2 is null then '' else codesc.descrip end,
 actiontaken3code = case when a.actiontaken3 is null then '' else a.actiontaken3 end,
 actiontaken3descip = case when a.actiontaken3 is null then '' else codesd.descrip end,
 actiontaken4code = case when a.actiontaken4 is null then '' else a.actiontaken4 end,
 actiontaken4descip = case when a.actiontaken4 is null then '' else codese.descrip end,
 a.amount1,
 a.amount2,
 a.crole,
 a.llosap_credit as losapcreditcode,
 losapcreditdescrip = case when a.llosap_credit = '1' then 'Losap Credit' else 'No Losap Credit' end
 
 from personnel as a
 
 left outer join codes901 as codesb on codesb.code = a.actiontaken1 and codesb.category = 'action'
 left outer join codes901 as codesc on codesc.code = a.actiontaken2 and codesc.category = 'action'
 left outer join codes901 as codesd on codesd.code = a.actiontaken3 and codesd.category = 'action'
 left outer join codes901 as codese on codese.code = a.actiontaken4 and codese.category = 'action'
 
GO
ALTER TABLE [dbo].[apparatus] ADD  DEFAULT ((0)) FOR [priorityresponseflag]
GO
ALTER TABLE [dbo].[apparatus] ADD  DEFAULT ((0)) FOR [cancelledenrouteflag]
GO
ALTER TABLE [dbo].[apparatus] ADD  DEFAULT ((0)) FOR [numberpeople]
GO
ALTER TABLE [dbo].[apparatus] ADD  DEFAULT ((0)) FOR [firstarrivingunit]
GO
ALTER TABLE [dbo].[apparatus] ADD  DEFAULT ((0)) FOR [respondfromquarters]
GO
ALTER TABLE [dbo].[apparatus] ADD  CONSTRAINT [DF_apparatus_rowguid]  DEFAULT (newsequentialid()) FOR [rowguid]
GO
ALTER TABLE [dbo].[apparatus] ADD  DEFAULT ((1)) FOR [lLosap_credit]
GO
ALTER TABLE [dbo].[apparatus] ADD  DEFAULT (getdate()) FOR [created]
GO
ALTER TABLE [dbo].[apparatus] ADD  DEFAULT ((0)) FOR [lNFIRSExported]
GO
ALTER TABLE [dbo].[apparatus] ADD  DEFAULT ('') FOR [NFIRSTransactiontype]
GO
ALTER TABLE [dbo].[apparatus] ADD  DEFAULT ((0)) FOR [Hydrant_Used]
GO
ALTER TABLE [dbo].[incident] ADD  DEFAULT ((0)) FOR [reviewstatusflag]
GO
ALTER TABLE [dbo].[incident] ADD  DEFAULT ((0)) FOR [publicreleaseflag]
GO
ALTER TABLE [dbo].[incident] ADD  DEFAULT ((0)) FOR [completed]
GO
ALTER TABLE [dbo].[incident] ADD  DEFAULT ('') FOR [station]
GO
ALTER TABLE [dbo].[incident] ADD  DEFAULT ('') FOR [incidenttype]
GO
ALTER TABLE [dbo].[incident] ADD  DEFAULT ('') FOR [mutualaidcode]
GO
ALTER TABLE [dbo].[incident] ADD  DEFAULT ('') FOR [alarmdate]
GO
ALTER TABLE [dbo].[incident] ADD  DEFAULT ((0)) FOR [didnotarriveflag]
GO
ALTER TABLE [dbo].[incident] ADD  DEFAULT ((0)) FOR [includemutualaidflag]
GO
ALTER TABLE [dbo].[incident] ADD  DEFAULT ((0)) FOR [resourceformusedflag]
GO
ALTER TABLE [dbo].[incident] ADD  DEFAULT ((0)) FOR [apparatussuppression]
GO
ALTER TABLE [dbo].[incident] ADD  DEFAULT ((0)) FOR [apparatusems]
GO
ALTER TABLE [dbo].[incident] ADD  DEFAULT ((0)) FOR [apparatusother]
GO
ALTER TABLE [dbo].[incident] ADD  DEFAULT ((0)) FOR [personnelsuppression]
GO
ALTER TABLE [dbo].[incident] ADD  DEFAULT ((0)) FOR [personnelems]
GO
ALTER TABLE [dbo].[incident] ADD  DEFAULT ((0)) FOR [personnelother]
GO
ALTER TABLE [dbo].[incident] ADD  DEFAULT ((0)) FOR [fatalfireservice]
GO
ALTER TABLE [dbo].[incident] ADD  DEFAULT ((0)) FOR [fatalother]
GO
ALTER TABLE [dbo].[incident] ADD  DEFAULT ((0)) FOR [nonfatalfireservice]
GO
ALTER TABLE [dbo].[incident] ADD  DEFAULT ((0)) FOR [nonfatalother]
GO
ALTER TABLE [dbo].[incident] ADD  DEFAULT ((0)) FOR [emsprovidedflag]
GO
ALTER TABLE [dbo].[incident] ADD  DEFAULT ((1)) FOR [locationtype]
GO
ALTER TABLE [dbo].[incident] ADD  DEFAULT ('') FOR [censustract]
GO
ALTER TABLE [dbo].[incident] ADD  DEFAULT ('') FOR [numberormile]
GO
ALTER TABLE [dbo].[incident] ADD  DEFAULT ('') FOR [streetprefix]
GO
ALTER TABLE [dbo].[incident] ADD  DEFAULT ('') FOR [streettype]
GO
ALTER TABLE [dbo].[incident] ADD  DEFAULT ('') FOR [streetsuffix]
GO
ALTER TABLE [dbo].[incident] ADD  DEFAULT ('') FOR [apartment]
GO
ALTER TABLE [dbo].[incident] ADD  DEFAULT ('') FOR [city]
GO
ALTER TABLE [dbo].[incident] ADD  DEFAULT ('') FOR [state]
GO
ALTER TABLE [dbo].[incident] ADD  DEFAULT ('') FOR [postalcode]
GO
ALTER TABLE [dbo].[incident] ADD  DEFAULT ('') FOR [crossstreetprefix]
GO
ALTER TABLE [dbo].[incident] ADD  DEFAULT ('') FOR [crossstreethighway]
GO
ALTER TABLE [dbo].[incident] ADD  DEFAULT ('') FOR [crossstreettype]
GO
ALTER TABLE [dbo].[incident] ADD  DEFAULT ('') FOR [crossstreetsuffix]
GO
ALTER TABLE [dbo].[incident] ADD  CONSTRAINT [DF_Directions]  DEFAULT ('') FOR [directions]
GO
ALTER TABLE [dbo].[incident] ADD  DEFAULT ('') FOR [latitude]
GO
ALTER TABLE [dbo].[incident] ADD  DEFAULT ('') FOR [longitude]
GO
ALTER TABLE [dbo].[incident] ADD  DEFAULT ('') FOR [meridian]
GO
ALTER TABLE [dbo].[incident] ADD  DEFAULT ('') FOR [northsouth]
GO
ALTER TABLE [dbo].[incident] ADD  DEFAULT ('') FOR [eastwest]
GO
ALTER TABLE [dbo].[incident] ADD  DEFAULT ('') FOR [compositeaddress]
GO
ALTER TABLE [dbo].[incident] ADD  DEFAULT ((0)) FOR [useoptionaltabs]
GO
ALTER TABLE [dbo].[incident] ADD  DEFAULT ((0)) FOR [SubstitudeFireForm]
GO
ALTER TABLE [dbo].[incident] ADD  DEFAULT ((0)) FOR [CADCompleted]
GO
ALTER TABLE [dbo].[incident] ADD  CONSTRAINT [DF_incident_rowguid]  DEFAULT (newsequentialid()) FOR [rowguid]
GO
ALTER TABLE [dbo].[incident] ADD  CONSTRAINT [DF_incident_Incident_ID]  DEFAULT ((0)) FOR [Incident_ID]
GO
ALTER TABLE [dbo].[incident] ADD  DEFAULT ((0)) FOR [loss_not_known]
GO
ALTER TABLE [dbo].[incident] ADD  DEFAULT ((0)) FOR [iMobile]
GO
ALTER TABLE [dbo].[incident] ADD  DEFAULT ((0)) FOR [lReExport]
GO
ALTER TABLE [dbo].[incident] ADD  DEFAULT (getdate()) FOR [created]
GO
ALTER TABLE [dbo].[incident] ADD  DEFAULT ((0)) FOR [Investigations_Notified]
GO
ALTER TABLE [dbo].[incident] ADD  DEFAULT ((0)) FOR [Extrication]
GO
ALTER TABLE [dbo].[incident] ADD  DEFAULT ((0)) FOR [ApparatusImported]
GO
ALTER TABLE [dbo].[incident] ADD  DEFAULT ((0)) FOR [lHazMatTabFlag]
GO
ALTER TABLE [dbo].[personnel] ADD  CONSTRAINT [DF_personnel_rowguid]  DEFAULT (newsequentialid()) FOR [rowguid]
GO
ALTER TABLE [dbo].[personnel] ADD  DEFAULT ((1)) FOR [lLosap_credit]
GO
ALTER TABLE [dbo].[personnel] ADD  DEFAULT ((0)) FOR [lNFIRSExported]
GO
ALTER TABLE [dbo].[personnel] ADD  DEFAULT ('') FOR [NFIRSTransactiontype]
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Unique Key Value for this Table' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'apparatus', @level2type=N'COLUMN',@level2name=N'apparatuskey'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Same as incident.incidentkey' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'apparatus', @level2type=N'COLUMN',@level2name=N'incidentkey'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Same as app_bas.apsid' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'apparatus', @level2type=N'COLUMN',@level2name=N'apsid'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Same as app_bas.appcode' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'apparatus', @level2type=N'COLUMN',@level2name=N'apparatusid'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Priority Response? (0-No/1-Yes)' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'apparatus', @level2type=N'COLUMN',@level2name=N'priorityresponseflag'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Arrival Date/Time' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'apparatus', @level2type=N'COLUMN',@level2name=N'arrivaldate'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Enroute to Scene Date/Time' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'apparatus', @level2type=N'COLUMN',@level2name=N'scenedate'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Enroute to Facility Date/Time' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'apparatus', @level2type=N'COLUMN',@level2name=N'enroutedate'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Arrived at Facility Date/Time' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'apparatus', @level2type=N'COLUMN',@level2name=N'FACILITYDATE'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Clear Date/Time' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'apparatus', @level2type=N'COLUMN',@level2name=N'cleardate'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Dispatch Date/Time' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'apparatus', @level2type=N'COLUMN',@level2name=N'dispatchdate'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Not Used' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'apparatus', @level2type=N'COLUMN',@level2name=N'inservicedate'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Cancelled Enroute? (0-No/1-Yes)' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'apparatus', @level2type=N'COLUMN',@level2name=N'cancelledenrouteflag'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Number of Personnel Assigned to the Apparatus' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'apparatus', @level2type=N'COLUMN',@level2name=N'numberpeople'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'1-Suppression/2-EMS/3-Other' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'apparatus', @level2type=N'COLUMN',@level2name=N'usecode'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Codes can be found in the codes901 table where category = ''ACTION''' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'apparatus', @level2type=N'COLUMN',@level2name=N'actiontaken1'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Codes can be found in the codes901 table where category = ''ACTION''' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'apparatus', @level2type=N'COLUMN',@level2name=N'actiontaken2'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Codes can be found in the codes901 table where category = ''ACTION''' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'apparatus', @level2type=N'COLUMN',@level2name=N'actiontaken3'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Codes can be found in the codes901 table where category = ''ACTION''' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'apparatus', @level2type=N'COLUMN',@level2name=N'actiontaken4'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Codes can be found in the codes901 table where category = ''APP_TYPE''' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'apparatus', @level2type=N'COLUMN',@level2name=N'apparatustype'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'User Defined Amount 1' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'apparatus', @level2type=N'COLUMN',@level2name=N'amount1'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'User Defined Amount 2' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'apparatus', @level2type=N'COLUMN',@level2name=N'amount2'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Not Used' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'apparatus', @level2type=N'COLUMN',@level2name=N'otherinfo'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Not Used' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'apparatus', @level2type=N'COLUMN',@level2name=N'logcomments'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Fire Department ID' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'apparatus', @level2type=N'COLUMN',@level2name=N'fdid_no'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Codes can be found in the codesEMS table where category = ''PARAMEDIC''' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'apparatus', @level2type=N'COLUMN',@level2name=N'paramedicdispatch'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'First Arriving Unit? (0-No/1-Yes)' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'apparatus', @level2type=N'COLUMN',@level2name=N'firstarrivingunit'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'In-service Date/Time' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'apparatus', @level2type=N'COLUMN',@level2name=N'inservicetime'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'This is the column description' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'apparatus', @level2type=N'COLUMN',@level2name=N'respondfromquarters'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Date/Time the Record was Last Changed' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'apparatus', @level2type=N'COLUMN',@level2name=N'changedate'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Used for replication.  It allows the replication engine to merge correctly.' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'apparatus', @level2type=N'COLUMN',@level2name=N'rowguid'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Same as Hydr_bas.idnumber' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'apparatus', @level2type=N'COLUMN',@level2name=N'Hydrant_IDNumber'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Same as Hydr_bas.location' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'apparatus', @level2type=N'COLUMN',@level2name=N'Hydrant_Location'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Number of Alarms (1 through 5)' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'apparatus', @level2type=N'COLUMN',@level2name=N'alarms'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'LOSAP Credit? (0-No/1-Yes)' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'apparatus', @level2type=N'COLUMN',@level2name=N'lLosap_credit'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'EMS Run? (0-No/1-Yes)' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'apparatus', @level2type=N'COLUMN',@level2name=N'emsrun'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'EMS Run Number' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'apparatus', @level2type=N'COLUMN',@level2name=N'emsrunnumber'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Gets Set to 1 by an insert/update trigger.  Will send apparatus data over to ePCR when 1' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'apparatus', @level2type=N'COLUMN',@level2name=N'lProcessEPCR'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Run Number from ePCR' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'apparatus', @level2type=N'COLUMN',@level2name=N'nEPCRRun'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'This is the column description' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'apparatus', @level2type=N'COLUMN',@level2name=N'stagingDate'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Record came from ePCR (0-No/1-Yes)' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'apparatus', @level2type=N'COLUMN',@level2name=N'isepcr'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Codes can be found in the dbtCodes table where category = ''UNITEXCP''' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'apparatus', @level2type=N'COLUMN',@level2name=N'unit_exc'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Codes can be found in the dbtCodes table where category = ''AEDTYPES''' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'apparatus', @level2type=N'COLUMN',@level2name=N'aedType'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'On Scene Mileage' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'apparatus', @level2type=N'COLUMN',@level2name=N'OdometerOnScene'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Destination Mileage' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'apparatus', @level2type=N'COLUMN',@level2name=N'OdometerDestination'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Total Mileage' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'apparatus', @level2type=N'COLUMN',@level2name=N'MileageTransport'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'At Patient Side Date/Time' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'apparatus', @level2type=N'COLUMN',@level2name=N'AtPatientSideTime'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Date/Time the Record was Created' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'apparatus', @level2type=N'COLUMN',@level2name=N'created'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Aerial Device Used? (0-Blank/1-No/2-Yes)' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'apparatus', @level2type=N'COLUMN',@level2name=N'AerialDeviceUsed'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Stores UDT Time Offset' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'apparatus', @level2type=N'COLUMN',@level2name=N'GMTOffSet'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'First Effective Unit (1-No/2-Yes)' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'apparatus', @level2type=N'COLUMN',@level2name=N'FirstEffectiveUnit'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'0-Not Exported to NFIRS/1-Exported to NFIRS' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'apparatus', @level2type=N'COLUMN',@level2name=N'lNFIRSExported'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Date/Time Exported to NFIRS' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'apparatus', @level2type=N'COLUMN',@level2name=N'NFIRSExportedDate'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'NFIRS Export Sequence' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'apparatus', @level2type=N'COLUMN',@level2name=N'iNFIRSSequence'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'NFIRS Transaction Type Blank=New, 1=Change, 2=Delete' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'apparatus', @level2type=N'COLUMN',@level2name=N'NFIRSTransactiontype'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'0-Not Selected/1-Hydrant Not Used/2-Hydrant Used' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'apparatus', @level2type=N'COLUMN',@level2name=N'Hydrant_Used'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Default Dispatch Code Used for Manual Fire to ePCR' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'apparatus', @level2type=N'COLUMN',@level2name=N'defaultdispatchcode'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Response Time for the Apparatus' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'apparatus', @level2type=N'COLUMN',@level2name=N'responseTime'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Turnout Time for the Apparatus' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'apparatus', @level2type=N'COLUMN',@level2name=N'turnTime'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Unique Key Value for this Table' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'incidentkey'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Populated by ZMS' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'incidentdate'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Number for the Incident' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'incidentnumber'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Exposure Number' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'exposure'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Incident Number + the Number of this Supplemental Record Number' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'incidentstatus'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Incident Reviewed? (0-No/1-Yes)' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'reviewstatusflag'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Released to Public? (0-No/1-Yes)' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'publicreleaseflag'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Incident Completed? (0-No/1-Yes)' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'completed'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Blank - Add/1-Edit/2-Delete/3-None' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'transactiontype'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'District Code that the Station is Assigned To' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'district'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Station from the Dept_Sta Table' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'station'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Shift from the Shft_Pat Table' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'shift'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Not Used' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'company'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Incident Type - - Codes can be found in the codes901 table where category = ''INCIDENT%''' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'incidenttype'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Initial Dispatch Code' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'initialdispatchcode'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Mutual Aid Code - Codes can be found in the codes901 table where category = ''AID%''' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'mutualaidcode'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Alarm Date/Time' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'alarmdate'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Arrival Date/Time' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'arrivaldate'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'No Arrival? (0-No/1-Yes)' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'didnotarriveflag'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Controlled Date/Time' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'controlleddate'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Last Unit Cleared Date/Time' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'lastunitcleareddate'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Mutual Aid None? (0-No/1-Yes)' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'includemutualaidflag'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Mutual Aid Department' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'madepartment'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Mutual Aid Incident Number' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'madeptincidentno'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Number of Alarms' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'alarms'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Action Taken 1 - Codes can be found in the codes901 table where category = ''ACTION%''' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'actiontaken1'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Action Taken 2 - Codes can be found in the codes901 table where category = ''ACTION%''' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'actiontaken2'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Action Taken 3 - Codes can be found in the codes901 table where category = ''ACTION%''' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'actiontaken3'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Not Used' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'resourceformusedflag'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Apparatus Summary - Department Suppression Number' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'apparatussuppression'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Apparatus Summary - Department EMS Number' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'apparatusems'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Apparatus Summary - Department Other Number' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'apparatusother'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Personnel Summary - Department Suppression Number' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'personnelsuppression'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Personnel Summary - Department EMS Number' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'personnelems'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Personnel Summary - Department Other Number' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'personnelother'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Estimated Dollar Property Loss' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'lossproperty'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Estimated Dollar Contents Loss' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'losscontents'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Estimated Pre-Incident Property Value' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'valueproperty'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Estimated Pre-Incident Contents Value' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'valuecontents'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Number of Fatal Fire Service Casualties' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'fatalfireservice'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Number of Fatal Other' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'fatalother'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Number of Non-Fatal Fire Service Casualties' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'nonfatalfireservice'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Number of Non-Fatal Other' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'nonfatalother'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Detector - Codes can be found in the codes901 table where category = ''DET_ALRT%''' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'detector'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Hazardous Materials Release - Codes can be found in the codes901 table where category = ''HAZ_REL%''' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'hazardmaterialreleased'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Mixed Use - Codes can be found in the codes901 table where category = ''MIXEDUSE%''' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'mixeduse'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Property Use - Codes can be found in the codes901 table where category = ''PROP_USE%''' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'propertyuse'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'EMS Provided? (0-No/1-Yes)' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'emsprovidedflag'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Casualties? (0-Blank/1-No/2-Yes)' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'casualtiesflag'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Priority Response? (0-No/1-Yes)' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'priorityresponseflag'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Not Used' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'vendorid'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Location Type - (1-Address/2-Intersection/3-In Front Of/4-In Rear Of/5-AdjacentTo/6-Directions/7- US National Grid/8-Lat/Long/9-Township or Range)' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'locationtype'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Census Tract' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'censustract'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Street Number or Mile' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'numberormile'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Street Prefix - Codes can be found in the codes901 table where category = ''DIR%''' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'streetprefix'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Street or Highway Name' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'streethighway'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Street Type - Codes can be found in the dptCodes	 table where category = ''TYPE%''' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'streettype'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Street Suffix - Codes can be found in the codes901 table where category = ''DIR%''' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'streetsuffix'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Apartment, Suite, or Building Number' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'apartment'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'City' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'city'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'State' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'state'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Postal (Zip) Code' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'postalcode'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Cross Street Prefix - Codes can be found in the codes901 table where category = ''DIR%''' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'crossstreetprefix'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Cross Street or Highway Name' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'crossstreethighway'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Cross Street Type - Codes can be found in the dptCodes	 table where category = ''TYPE%''' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'crossstreettype'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Cross Street Suffix - Codes can be found in the codes901 table where category = ''DIR%''' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'crossstreetsuffix'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Directions' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'directions'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Latitude' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'latitude'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Longitude' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'longitude'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Meridian - Codes can be found in the codes901 table where category = ''MERIDIAN%''' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'meridian'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'North South Direction - Codes can be found in the dptCodes	 table where category = ''DIR%''' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'northsouth'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'East West Direction - Codes can be found in the dptCodes	 table where category = ''DIR%''' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'eastwest'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Subsection - Codes can be found in the codes901 table where category = ''SUBSECTN%''' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'subsection'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Section' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'section'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Range' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'range'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Township' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'township'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Composite Address' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'compositeaddress'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Apparatus Summary - Mutual Aid Suppression Count' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'MAAPPARATUSSUPPRESSION'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Apparatus Summary - EMS Count' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'MAAPPARATUSEMS'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Apparatus Summary - Other Count' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'MAAPPARATUSOTHER'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Personnel Summary - Mutual Aid Suppression Count' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'MAPERSONNELSUPPRESSION'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Personnel Summary - EMS Count' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'MAPERSONNELEMS'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Personnel Summary - Other Count' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'MAPERSONNELOTHER'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Use Optional Tabs? (0-No/1-Yes)' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'useoptionaltabs'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'FDID - - Codes can be found in the dptCodes table where category = ''AGENCY%''' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'fdid_no'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Mutual Aid Department State' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'madeptstate'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'FireRMS version in use when the incident was created' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'appversion'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'County' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'county'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Other City' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'CityOther'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Same as occ_bas.occid' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'occupancykey'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Same as occ_bas.number' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'occupancynumber'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Same as occ_bas.name' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'occupancyname'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Not Used' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'runcard'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Map Page' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'mappage'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Not Used' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'descrip'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Alt Form? (0-No/1-Yes)' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'SubstitudeFireForm'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Address Validated (0-No/1-Yes)' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'addressvalidated'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'CAD Completed (0-No/1-Yes)' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'CADCompleted'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Date/Time the Record was Last Changed' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'changedate'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Used for replication.  It allows the replication engine to merge correctly.' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'rowguid'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Included in the incident table for use with the Day Book To Do Items - Not populated in the incident table' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'OtherInfo'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Comments Entered via the Daybook Log' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'LogComments'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'CO? (0-No/1-Yes)' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'CO_Flag'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Not Used' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'Alarm_Trans'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Not Used' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'Incident_ID'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Cannot Estimate Losses? (0-No/1-Yes)' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'loss_not_known'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Is a Mobile Incident? (0-No/1-Yes)' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'iMobile'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Used when auto-exports to Collector are enabled.  Date/time exported to Collector' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'collecteddate'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Incident Type When Dispatched' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'DispatchIncType'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Fire Service Casualty Count' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'nfscasualtycnt'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Civilian Casualty Count' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'ncivcasualtycnt'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Ontario Province Only - Estimated KM Distance' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'nEstKMDistance'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Ontario Province Only - Number of Rescues' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'ofm_nbrrescued'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Critical Incident - (1-No/2-Yes)' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'criticalincident'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Team Mobilized - (1-No/2-Yes)' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'teammobilized'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'PSAP Date/Time' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'psaptime'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Circumstances 1 - Codes can be found in the dptCodes table where category = ''CSTANCE%''' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'circumstance1'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Circumstances 2 - Codes can be found in the dptCodes table where category = ''CSTANCE%''' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'circumstance2'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Circumstances 3 - Codes can be found in the dptCodes table where category = ''CSTANCE%''' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'circumstance3'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Wildland Arson? (0-No/1-Yes)' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'lArsonFlag'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Reported By - Codes can be found in the dptCodes table where category = ''INREPTBY%''' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'ReportedBy'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Corrected Record for Re-Export? (0-No/1-Yes)' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'lReExport'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Geo Mapping X-Coordinates' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'XCoord'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Geo Mapping Y-Coordinates' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'YCoord'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Incident Validated? (0-No/1-Yes)' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'lValidated'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Is an ePCR Record - (0-No/1-Yes)' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'isEPCR'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Ontario Province Only - Mutual Aid - Codes can be found in the dptCodes table where category = ''MUTL_AID%''' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'ofm_mutualaid'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'EMS Module (1-Basic EMS/2-Advanced EMS/3-NEMSIS)' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'EMSModule'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Incident Delay - Codes can be found in the dptCodes table where category = ''INCEXCEP%''' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'inc_exc'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Census Area - Codes can be found in the dptCodes table where category = ''CENSARA%''' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'CensusArea'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Final Dispatch Code' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'finaldispatchcode'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Date/Time Record was Created' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'created'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Response Type - Codes can be found in the dptCodes table where category = ''RESPTYPE%''' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'ResponseType'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'CAD User Defined Textbox 1' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'CADText1'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'CAD User Defined Textbox 2' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'CADText2'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'CAD User Defined Textbox 3' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'CADText3'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'CAD User Defined Combo 1 - Codes can be found in the dptCodes table where category = ''CADCOMB1%''' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'CADCombo1'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'CAD User Defined Combo 2 - Codes can be found in the dptCodes table where category = ''CADCOMB2%''' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'CADCombo2'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'CAD User Defined Combo 3 - Codes can be found in the dptCodes table where category = ''CADCOMB3%''' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'CADCombo3'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Stores UDT Time Offset' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'GMTOffSet'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'CAD User Defined Datetime 1' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'CADDate1'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'CAD User Defined Datetime 2' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'CADDate2'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'CAD User Defined Datetime 3' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'CADDate3'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Moved to Fire Table' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'WaterOnFireDate'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Incoming Benchmark Field from CAD.  Movied to Fire Table via Trigger and then deleted from Incident Table.' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'PriSearchCompDate'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Secondary Search Completion Date' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'SecSearchCompDate'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'All Clear Date' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'AllClearDate'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Loss Stopped Date' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'LossStoppedDate'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Customer Stabilized Date' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'CustStabilizedDate'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Investigations Contacted (1-No/2-Yes)' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'Investigations_Notified'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Extricatin (0-No/1-Yes)' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'Extrication'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Used for Exposures: 0-Apparatus Not Imported/1-Apparatus Imported' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'ApparatusImported'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'0-No HazMat Tab for Selected Hazardous Material Released/1-Include HazMat Tab for Selected Hazardous Material Released' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'lHazMatTabFlag'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Maximum Response Time for the Selected Incident Type' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'responseTime'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Pro QA Code' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'ProQA'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Turnout Time' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'turnTime'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'AGIS Mapset' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'Mapset'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'AGIS Easting' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'Easting'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'AGIS Northing' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'incident', @level2type=N'COLUMN',@level2name=N'Northing'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Unique Key Value for this Table' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'personnel', @level2type=N'COLUMN',@level2name=N'personnelkey'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Same as incident.incidentkey' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'personnel', @level2type=N'COLUMN',@level2name=N'incidentkey'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Same as apparatus.apparatuskey' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'personnel', @level2type=N'COLUMN',@level2name=N'apparatuskey'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Same as per_bas.pslid' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'personnel', @level2type=N'COLUMN',@level2name=N'pslid'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Not Used' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'personnel', @level2type=N'COLUMN',@level2name=N'rosid'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Same as per_bas.code' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'personnel', @level2type=N'COLUMN',@level2name=N'personnelid'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Last Name' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'personnel', @level2type=N'COLUMN',@level2name=N'lastname'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'First Name' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'personnel', @level2type=N'COLUMN',@level2name=N'firstname'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Middle Initial' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'personnel', @level2type=N'COLUMN',@level2name=N'middleinitial'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Name Suffix' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'personnel', @level2type=N'COLUMN',@level2name=N'namesuffix'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Position - Codes can be found in the dptCodes table where category = ''POSITION%''' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'personnel', @level2type=N'COLUMN',@level2name=N'rank'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Action Taken 1 - Codes can be found in the codes901 table where category = ''ACTION%''' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'personnel', @level2type=N'COLUMN',@level2name=N'actiontaken1'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Action Taken 2 - Codes can be found in the codes901 table where category = ''ACTION%''' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'personnel', @level2type=N'COLUMN',@level2name=N'actiontaken2'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Action Taken 3 - Codes can be found in the codes901 table where category = ''ACTION%''' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'personnel', @level2type=N'COLUMN',@level2name=N'actiontaken3'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Action Taken 4 - Codes can be found in the codes901 table where category = ''ACTION%''' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'personnel', @level2type=N'COLUMN',@level2name=N'actiontaken4'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'User Defined Amount 1' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'personnel', @level2type=N'COLUMN',@level2name=N'amount1'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'User Defined Amount 2' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'personnel', @level2type=N'COLUMN',@level2name=N'amount2'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Date/Time the Record was Last Changed' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'personnel', @level2type=N'COLUMN',@level2name=N'changedate'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Used for replication.  It allows the replication engine to merge correctly.' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'personnel', @level2type=N'COLUMN',@level2name=N'rowguid'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Role - Codes can be found in the codes901 table where category = ''ASSIGN%''' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'personnel', @level2type=N'COLUMN',@level2name=N'crole'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'LOSAP Credit? (0-No/1-Yes)' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'personnel', @level2type=N'COLUMN',@level2name=N'lLosap_credit'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Not Used' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'personnel', @level2type=N'COLUMN',@level2name=N'MedCert'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Position in Vehicle - Codes can be found in the dptCodes table where category = ''ADDROLE%''' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'personnel', @level2type=N'COLUMN',@level2name=N'cAdditionalRole'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'External Agency ID - Codes can be found in the dptCodes table where category = ''AGENCY%''' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'personnel', @level2type=N'COLUMN',@level2name=N'AgencyID'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Agency Description When External Personnel are Added' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'personnel', @level2type=N'COLUMN',@level2name=N'AgencyDesc'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Agency Code When External Personnel are Added' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'personnel', @level2type=N'COLUMN',@level2name=N'AgencyCode'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'0-Not Exported to NFIRS/1-Exported to NFIRS' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'personnel', @level2type=N'COLUMN',@level2name=N'lNFIRSExported'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Date/Time Exported to NFIRS' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'personnel', @level2type=N'COLUMN',@level2name=N'NFIRSExportedDate'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'NFIRS Export Sequence' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'personnel', @level2type=N'COLUMN',@level2name=N'iNFIRSSequence'
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'NFIRS Transaction Type Blank=New, 1=Change, 2=Delete' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'personnel', @level2type=N'COLUMN',@level2name=N'NFIRSTransactiontype'
GO