McsbExcelDataMapper.xml
33.6 KB
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
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.chinagas.modules.mcsb.mapper.McsbExcelDataMapper">
<resultMap type="McsbExcelData" id="McsbExcelDataResult">
<result property="id" column="id" />
<result property="year" column="year" />
<result property="month" column="month" />
<result property="entity" column="entity" />
<result property="colCv" column="col_cv" />
<result property="colA" column="col_a" />
<result property="colB" column="col_b" />
<result property="colC" column="col_c" />
<result property="colD" column="col_d" />
<result property="colE" column="col_e" />
<result property="colF" column="col_f" />
<result property="colG" column="col_g" />
<result property="colH" column="col_h" />
<result property="colI" column="col_i" />
<result property="colJ" column="col_j" />
<result property="colK" column="col_k" />
<result property="colL" column="col_l" />
<result property="colM" column="col_m" />
<result property="colN" column="col_n" />
<result property="colO" column="col_o" />
<result property="colP" column="col_p" />
<result property="colQ" column="col_q" />
<result property="colR" column="col_r" />
<result property="colS" column="col_s" />
<result property="colT" column="col_t" />
<result property="colU" column="col_u" />
<result property="colV" column="col_v" />
<result property="colW" column="col_w" />
<result property="colX" column="col_x" />
<result property="colY" column="col_y" />
<result property="colZ" column="col_z" />
<result property="colAa" column="col_aa" />
<result property="colAb" column="col_ab" />
<result property="colAc" column="col_ac" />
<result property="colAd" column="col_ad" />
<result property="colAe" column="col_ae" />
<result property="colAf" column="col_af" />
<result property="colAg" column="col_ag" />
<result property="colAh" column="col_ah" />
<result property="colAi" column="col_ai" />
<result property="colAj" column="col_aj" />
<result property="colAk" column="col_ak" />
<result property="colAl" column="col_al" />
<result property="colAm" column="col_am" />
<result property="colAn" column="col_an" />
<result property="colAo" column="col_ao" />
<result property="colAp" column="col_ap" />
<result property="colAq" column="col_aq" />
<result property="colAr" column="col_ar" />
<result property="colAs" column="col_as" />
<result property="colAt" column="col_at" />
<result property="colAu" column="col_au" />
<result property="colAv" column="col_av" />
<result property="colAw" column="col_aw" />
<result property="colAx" column="col_ax" />
<result property="colAy" column="col_ay" />
<result property="colAz" column="col_az" />
<result property="colBa" column="col_ba" />
<result property="colBb" column="col_bb" />
<result property="colBc" column="col_bc" />
<result property="colBd" column="col_bd" />
<result property="colBe" column="col_be" />
<result property="colBf" column="col_bf" />
<result property="colBg" column="col_bg" />
<result property="colBh" column="col_bh" />
<result property="colBi" column="col_bi" />
<result property="colBj" column="col_bj" />
<result property="colBk" column="col_bk" />
<result property="colBl" column="col_bl" />
<result property="colBm" column="col_bm" />
<result property="colBn" column="col_bn" />
<result property="colBo" column="col_bo" />
<result property="colBp" column="col_bp" />
<result property="colBq" column="col_bq" />
<result property="colBr" column="col_br" />
<result property="colBs" column="col_bs" />
<result property="colBt" column="col_bt" />
<result property="colBu" column="col_bu" />
<result property="colBv" column="col_bv" />
<result property="colBw" column="col_bw" />
<result property="colBx" column="col_bx" />
<result property="colBy" column="col_by" />
<result property="colBz" column="col_bz" />
<result property="createTime" column="create_time" />
<result property="createBy" column="create_by" />
<result property="updateTime" column="update_time" />
<result property="updateBy" column="update_by" />
<result property="recordId" column="record_id" />
<result property="rowN" column="row_n" />
</resultMap>
<sql id="selectMcsbExcelDataVo">
select id, year, month, entity, col_cv, col_a, col_b, col_c, col_d, col_e, col_f, col_bo, col_bp, col_bq, col_br, col_bs, create_time, create_by, update_time, update_by,record_id,row_n from mcsb_excel_data
</sql>
<select id="selectMcsbExcelDataList" parameterType="McsbExcelData" resultMap="McsbExcelDataResult">
<include refid="selectMcsbExcelDataVo"/>
<where>
<if test="year != null "> and year = #{year}</if>
<if test="month != null "> and month = #{month}</if>
<if test="entity != null and entity != ''"> and entity = #{entity}</if>
<if test="colCv != null "> and col_cv = #{colCv}</if>
<if test="colA != null and colA != ''"> and col_a = #{colA }</if>
<if test="colB != null and colB != ''"> and col_b = #{colB }</if>
<if test="colC != null and colC != ''"> and col_c = #{colC }</if>
<if test="colD != null and colD != ''"> and col_d = #{colD }</if>
<if test="colE != null and colE != ''"> and col_e = #{colE }</if>
<if test="colF != null and colF != ''"> and col_f = #{colF }</if>
<if test="colG != null and colG != ''"> and col_g = #{colG }</if>
<if test="colH != null and colH != ''"> and col_h = #{colH }</if>
<if test="colI != null and colI != ''"> and col_i = #{colI }</if>
<if test="colJ != null and colJ != ''"> and col_j = #{colJ }</if>
<if test="colK != null and colK != ''"> and col_k = #{colK }</if>
<if test="colL != null and colL != ''"> and col_l = #{colL }</if>
<if test="colM != null and colM != ''"> and col_m = #{colM }</if>
<if test="colN != null and colN != ''"> and col_n = #{colN }</if>
<if test="colO != null and colO != ''"> and col_o = #{colO }</if>
<if test="colP != null and colP != ''"> and col_p = #{colP }</if>
<if test="colQ != null and colQ != ''"> and col_q = #{colQ }</if>
<if test="colR != null and colR != ''"> and col_r = #{colR }</if>
<if test="colS != null and colS != ''"> and col_s = #{colS }</if>
<if test="colT != null and colT != ''"> and col_t = #{colT }</if>
<if test="colU != null and colU != ''"> and col_u = #{colU }</if>
<if test="colV != null and colV != ''"> and col_v = #{colV }</if>
<if test="colW != null and colW != ''"> and col_w = #{colW }</if>
<if test="colX != null and colX != ''"> and col_x = #{colX }</if>
<if test="colY != null and colY != ''"> and col_y = #{colY }</if>
<if test="colZ != null and colZ != ''"> and col_z = #{colZ }</if>
<if test="colAa != null and colAa != ''"> and col_aa = #{colAa }</if>
<if test="colAb != null and colAb != ''"> and col_ab = #{colAb }</if>
<if test="colAc != null and colAc != ''"> and col_ac = #{colAc }</if>
<if test="colAd != null and colAd != ''"> and col_ad = #{colAd }</if>
<if test="colAe != null and colAe != ''"> and col_ae = #{colAe }</if>
<if test="colAf != null and colAf != ''"> and col_af = #{colAf }</if>
<if test="colAg != null and colAg != ''"> and col_ag = #{colAg }</if>
<if test="colAh != null and colAh != ''"> and col_ah = #{colAh }</if>
<if test="colAi != null and colAi != ''"> and col_ai = #{colAi }</if>
<if test="colAj != null and colAj != ''"> and col_aj = #{colAj }</if>
<if test="colAk != null and colAk != ''"> and col_ak = #{colAk }</if>
<if test="colAl != null and colAl != ''"> and col_al = #{colAl }</if>
<if test="colAm != null and colAm != ''"> and col_am = #{colAm }</if>
<if test="colAn != null and colAn != ''"> and col_an = #{colAn }</if>
<if test="colAo != null and colAo != ''"> and col_ao = #{colAo }</if>
<if test="colAp != null and colAp != ''"> and col_ap = #{colAp }</if>
<if test="colAq != null and colAq != ''"> and col_aq = #{colAq }</if>
<if test="colAr != null and colAr != ''"> and col_ar = #{colAr }</if>
<if test="colAs != null and colAs != ''"> and col_as = #{colAs }</if>
<if test="colAt != null and colAt != ''"> and col_at = #{colAt }</if>
<if test="colAu != null and colAu != ''"> and col_au = #{colAu }</if>
<if test="colAv != null and colAv != ''"> and col_av = #{colAv }</if>
<if test="colAw != null and colAw != ''"> and col_aw = #{colAw }</if>
<if test="colAx != null and colAx != ''"> and col_ax = #{colAx }</if>
<if test="colAy != null and colAy != ''"> and col_ay = #{colAy }</if>
<if test="colAz != null and colAz != ''"> and col_az = #{colAz }</if>
<if test="colBa != null and colBa != ''"> and col_ba = #{colBa }</if>
<if test="colBb != null and colBb != ''"> and col_bb = #{colBb }</if>
<if test="colBc != null and colBc != ''"> and col_bc = #{colBc }</if>
<if test="colBd != null and colBd != ''"> and col_bd = #{colBd }</if>
<if test="colBe != null and colBe != ''"> and col_be = #{colBe }</if>
<if test="colBf != null and colBf != ''"> and col_bf = #{colBf }</if>
<if test="colBg != null and colBg != ''"> and col_bg = #{colBg }</if>
<if test="colBh != null and colBh != ''"> and col_bh = #{colBh }</if>
<if test="colBi != null and colBi != ''"> and col_bi = #{colBi }</if>
<if test="colBj != null and colBj != ''"> and col_bj = #{colBj }</if>
<if test="colBk != null and colBk != ''"> and col_bk = #{colBk }</if>
<if test="colBl != null and colBl != ''"> and col_bl = #{colBl }</if>
<if test="colBm != null and colBm != ''"> and col_bm = #{colBm }</if>
<if test="colBn != null and colBn != ''"> and col_bn = #{colBn }</if>
<if test="colBo != null and colBo != ''"> and col_bo = #{colBo }</if>
<if test="colBp != null and colBp != ''"> and col_bp = #{colBp }</if>
<if test="colBq != null and colBq != ''"> and col_bq = #{colBq }</if>
<if test="colBr != null and colBr != ''"> and col_br = #{colBr }</if>
<if test="colBs != null and colBs != ''"> and col_bs = #{colBs }</if>
<if test="colBt != null and colBt != ''"> and col_bt = #{colBt }</if>
<if test="colBu != null and colBu != ''"> and col_bu = #{colBu }</if>
<if test="colBv != null and colBv != ''"> and col_bv = #{colBv }</if>
<if test="colBw != null and colBw != ''"> and col_bw = #{colBw }</if>
<if test="colBx != null and colBx != ''"> and col_bx = #{colBx }</if>
<if test="colBy != null and colBy != ''"> and col_by = #{colBy }</if>
<if test="colBz != null and colBz != ''"> and col_bz = #{colBz }</if>
<if test="recordId != null and recordId != ''"> and record_id = #{recordId}</if>
</where>
</select>
<select id="selectMcsbExcelDataById" parameterType="Long" resultMap="McsbExcelDataResult">
<include refid="selectMcsbExcelDataVo"/>
where id = #{id}
</select>
<insert id="insertMcsbExcelData" parameterType="McsbExcelData">
insert into mcsb_excel_data
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="id != null">id,</if>
<if test="year != null">year,</if>
<if test="month != null">month,</if>
<if test="entity != null">entity,</if>
<if test="colCv != null">col_cv,</if>
<if test="colA != null">col_a ,</if>
<if test="colB != null">col_b ,</if>
<if test="colC != null">col_c ,</if>
<if test="colD != null">col_d ,</if>
<if test="colE != null">col_e ,</if>
<if test="colF != null">col_f ,</if>
<if test="colG != null">col_g ,</if>
<if test="colH != null">col_h ,</if>
<if test="colI != null">col_i ,</if>
<if test="colJ != null">col_j ,</if>
<if test="colK != null">col_k ,</if>
<if test="colL != null">col_l ,</if>
<if test="colM != null">col_m ,</if>
<if test="colN != null">col_n ,</if>
<if test="colO != null">col_o ,</if>
<if test="colP != null">col_p ,</if>
<if test="colQ != null">col_q ,</if>
<if test="colR != null">col_r ,</if>
<if test="colS != null">col_s ,</if>
<if test="colT != null">col_t ,</if>
<if test="colU != null">col_u ,</if>
<if test="colV != null">col_v ,</if>
<if test="colW != null">col_w ,</if>
<if test="colX != null">col_x ,</if>
<if test="colY != null">col_y ,</if>
<if test="colZ != null">col_z ,</if>
<if test="colAa != null">col_aa ,</if>
<if test="colAb != null">col_ab ,</if>
<if test="colAc != null">col_ac ,</if>
<if test="colAd != null">col_ad ,</if>
<if test="colAe != null">col_ae ,</if>
<if test="colAf != null">col_af ,</if>
<if test="colAg != null">col_ag ,</if>
<if test="colAh != null">col_ah ,</if>
<if test="colAi != null">col_ai ,</if>
<if test="colAj != null">col_aj ,</if>
<if test="colAk != null">col_ak ,</if>
<if test="colAl != null">col_al ,</if>
<if test="colAm != null">col_am ,</if>
<if test="colAn != null">col_an ,</if>
<if test="colAo != null">col_ao ,</if>
<if test="colAp != null">col_ap ,</if>
<if test="colAq != null">col_aq ,</if>
<if test="colAr != null">col_ar ,</if>
<if test="colAs != null">col_as ,</if>
<if test="colAt != null">col_at ,</if>
<if test="colAu != null">col_au ,</if>
<if test="colAv != null">col_av ,</if>
<if test="colAw != null">col_aw ,</if>
<if test="colAx != null">col_ax ,</if>
<if test="colAy != null">col_ay ,</if>
<if test="colAz != null">col_az ,</if>
<if test="colBa != null">col_ba ,</if>
<if test="colBb != null">col_bb ,</if>
<if test="colBc != null">col_bc ,</if>
<if test="colBd != null">col_bd ,</if>
<if test="colBe != null">col_be ,</if>
<if test="colBf != null">col_bf ,</if>
<if test="colBg != null">col_bg ,</if>
<if test="colBh != null">col_bh ,</if>
<if test="colBi != null">col_bi ,</if>
<if test="colBj != null">col_bj ,</if>
<if test="colBk != null">col_bk ,</if>
<if test="colBl != null">col_bl ,</if>
<if test="colBm != null">col_bm ,</if>
<if test="colBn != null">col_bn ,</if>
<if test="colBo != null">col_bo ,</if>
<if test="colBp != null">col_bp ,</if>
<if test="colBq != null">col_bq ,</if>
<if test="colBr != null">col_br ,</if>
<if test="colBs != null">col_bs ,</if>
<if test="colBt != null">col_bt ,</if>
<if test="colBu != null">col_bu ,</if>
<if test="colBv != null">col_bv ,</if>
<if test="colBw != null">col_bw ,</if>
<if test="colBx != null">col_bx ,</if>
<if test="colBy != null">col_by ,</if>
<if test="colBz != null">col_bz ,</if>
<if test="createTime != null">create_time,</if>
<if test="createBy != null">create_by,</if>
<if test="updateTime != null">update_time,</if>
<if test="updateBy != null">update_by,</if>
<if test="recordId != null">record_id,</if>
<if test="rowN != null">row_n,</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="id != null">#{id},</if>
<if test="year != null">#{year},</if>
<if test="month != null">#{month},</if>
<if test="entity != null">#{entity},</if>
<if test="colCv != null">#{colCv},</if>
<if test="colA != null">#{col_a },</if>
<if test="colB != null">#{col_b },</if>
<if test="colC != null">#{col_c },</if>
<if test="colD != null">#{col_d },</if>
<if test="colE != null">#{col_e },</if>
<if test="colF != null">#{col_f },</if>
<if test="colG != null">#{col_g },</if>
<if test="colH != null">#{col_h },</if>
<if test="colI != null">#{col_i },</if>
<if test="colJ != null">#{col_j },</if>
<if test="colK != null">#{col_k },</if>
<if test="colL != null">#{col_l },</if>
<if test="colM != null">#{col_m },</if>
<if test="colN != null">#{col_n },</if>
<if test="colO != null">#{col_o },</if>
<if test="colP != null">#{col_p },</if>
<if test="colQ != null">#{col_q },</if>
<if test="colR != null">#{col_r },</if>
<if test="colS != null">#{col_s },</if>
<if test="colT != null">#{col_t },</if>
<if test="colU != null">#{col_u },</if>
<if test="colV != null">#{col_v },</if>
<if test="colW != null">#{col_w },</if>
<if test="colX != null">#{col_x },</if>
<if test="colY != null">#{col_y },</if>
<if test="colZ != null">#{col_z },</if>
<if test="colAa != null">#{col_aa} ,</if>
<if test="colAb != null">#{col_ab} ,</if>
<if test="colAc != null">#{col_ac} ,</if>
<if test="colAd != null">#{col_ad} ,</if>
<if test="colAe != null">#{col_ae} ,</if>
<if test="colAf != null">#{col_af} ,</if>
<if test="colAg != null">#{col_ag} ,</if>
<if test="colAh != null">#{col_ah} ,</if>
<if test="colAi != null">#{col_ai} ,</if>
<if test="colAj != null">#{col_aj} ,</if>
<if test="colAk != null">#{col_ak} ,</if>
<if test="colAl != null">#{col_al} ,</if>
<if test="colAm != null">#{col_am} ,</if>
<if test="colAn != null">#{col_an} ,</if>
<if test="colAo != null">#{col_ao} ,</if>
<if test="colAp != null">#{col_ap} ,</if>
<if test="colAq != null">#{col_aq} ,</if>
<if test="colAr != null">#{col_ar} ,</if>
<if test="colAs != null">#{col_as} ,</if>
<if test="colAt != null">#{col_at} ,</if>
<if test="colAu != null">#{col_au} ,</if>
<if test="colAv != null">#{col_av} ,</if>
<if test="colAw != null">#{col_aw} ,</if>
<if test="colAx != null">#{col_ax} ,</if>
<if test="colAy != null">#{col_ay} ,</if>
<if test="colAz != null">#{col_az} ,</if>
<if test="colBa != null">#{col_ba} ,</if>
<if test="colBb != null">#{col_bb} ,</if>
<if test="colBc != null">#{col_bc} ,</if>
<if test="colBd != null">#{col_bd} ,</if>
<if test="colBe != null">#{col_be} ,</if>
<if test="colBf != null">#{col_bf} ,</if>
<if test="colBg != null">#{col_bg} ,</if>
<if test="colBh != null">#{col_bh} ,</if>
<if test="colBi != null">#{col_bi} ,</if>
<if test="colBj != null">#{col_bj} ,</if>
<if test="colBk != null">#{col_bk} ,</if>
<if test="colBl != null">#{col_bl} ,</if>
<if test="colBm != null">#{col_bm} ,</if>
<if test="colBn != null">#{col_bn} ,</if>
<if test="colBo != null">#{col_bo} ,</if>
<if test="colBp != null">#{col_bp} ,</if>
<if test="colBq != null">#{col_bq} ,</if>
<if test="colBr != null">#{col_br} ,</if>
<if test="colBs != null">#{col_bs} ,</if>
<if test="colBt != null">#{col_bt} ,</if>
<if test="colBu != null">#{col_bu} ,</if>
<if test="colBv != null">#{col_bv} ,</if>
<if test="colBw != null">#{col_bw} ,</if>
<if test="colBx != null">#{col_bx} ,</if>
<if test="colBy != null">#{col_by} ,</if>
<if test="colBz != null">#{col_bz} ,</if>
<if test="createTime != null">#{createTime},</if>
<if test="createBy != null">#{createBy},</if>
<if test="updateTime != null">#{updateTime},</if>
<if test="updateBy != null">#{updateBy},</if>
<if test="recordId != null">#{recordId},</if>
<if test="rowN != null">#{rowN},</if>
</trim>
</insert>
<update id="updateMcsbExcelData" parameterType="McsbExcelData">
update mcsb_excel_data
<trim prefix="SET" suffixOverrides=",">
<if test="year != null">year = #{year},</if>
<if test="month != null">month = #{month},</if>
<if test="entity != null">entity = #{entity},</if>
<if test="colCv != null">col_cv = #{colCv},</if>
<if test="colA != null">col_a = #{colA },</if>
<if test="colB != null">col_b = #{colB },</if>
<if test="colC != null">col_c = #{colC },</if>
<if test="colD != null">col_d = #{colD },</if>
<if test="colE != null">col_e = #{colE },</if>
<if test="colF != null">col_f = #{colF },</if>
<if test="colG != null">col_g = #{colG },</if>
<if test="colH != null">col_h = #{colH },</if>
<if test="colI != null">col_i = #{colI },</if>
<if test="colJ != null">col_j = #{colJ },</if>
<if test="colK != null">col_k = #{colK },</if>
<if test="colL != null">col_l = #{colL },</if>
<if test="colM != null">col_m = #{colM },</if>
<if test="colN != null">col_n = #{colN },</if>
<if test="colO != null">col_o = #{colO },</if>
<if test="colP != null">col_p = #{colP },</if>
<if test="colQ != null">col_q = #{colQ },</if>
<if test="colR != null">col_r = #{colR },</if>
<if test="colS != null">col_s = #{colS },</if>
<if test="colT != null">col_t = #{colT },</if>
<if test="colU != null">col_u = #{colU },</if>
<if test="colV != null">col_v = #{colV },</if>
<if test="colW != null">col_w = #{colW },</if>
<if test="colX != null">col_x = #{colX },</if>
<if test="colY != null">col_y = #{colY },</if>
<if test="colZ != null">col_z = #{colZ },</if>
<if test="colAa != null">col_aa = #{colAa} ,</if>
<if test="colAb != null">col_ab = #{colAb} ,</if>
<if test="colAc != null">col_ac = #{colAc} ,</if>
<if test="colAd != null">col_ad = #{colAd} ,</if>
<if test="colAe != null">col_ae = #{colAe} ,</if>
<if test="colAf != null">col_af = #{colAf} ,</if>
<if test="colAg != null">col_ag = #{colAg} ,</if>
<if test="colAh != null">col_ah = #{colAh} ,</if>
<if test="colAi != null">col_ai = #{colAi} ,</if>
<if test="colAj != null">col_aj = #{colAj} ,</if>
<if test="colAk != null">col_ak = #{colAk} ,</if>
<if test="colAl != null">col_al = #{colAl} ,</if>
<if test="colAm != null">col_am = #{colAm} ,</if>
<if test="colAn != null">col_an = #{colAn} ,</if>
<if test="colAo != null">col_ao = #{colAo} ,</if>
<if test="colAp != null">col_ap = #{colAp} ,</if>
<if test="colAq != null">col_aq = #{colAq} ,</if>
<if test="colAr != null">col_ar = #{colAr} ,</if>
<if test="colAs != null">col_as = #{colAs} ,</if>
<if test="colAt != null">col_at = #{colAt} ,</if>
<if test="colAu != null">col_au = #{colAu} ,</if>
<if test="colAv != null">col_av = #{colAv} ,</if>
<if test="colAw != null">col_aw = #{colAw} ,</if>
<if test="colAx != null">col_ax = #{colAx} ,</if>
<if test="colAy != null">col_ay = #{colAy} ,</if>
<if test="colAz != null">col_az = #{colAz} ,</if>
<if test="colBa != null">col_ba = #{colBa} ,</if>
<if test="colBb != null">col_bb = #{colBb} ,</if>
<if test="colBc != null">col_bc = #{colBc} ,</if>
<if test="colBd != null">col_bd = #{colBd} ,</if>
<if test="colBe != null">col_be = #{colBe} ,</if>
<if test="colBf != null">col_bf = #{colBf} ,</if>
<if test="colBg != null">col_bg = #{colBg} ,</if>
<if test="colBh != null">col_bh = #{colBh} ,</if>
<if test="colBi != null">col_bi = #{colBi} ,</if>
<if test="colBj != null">col_bj = #{colBj} ,</if>
<if test="colBk != null">col_bk = #{colBk} ,</if>
<if test="colBl != null">col_bl = #{colBl} ,</if>
<if test="colBm != null">col_bm = #{colBm} ,</if>
<if test="colBn != null">col_bn = #{colBn} ,</if>
<if test="colBo != null">col_bo = #{colBo} ,</if>
<if test="colBp != null">col_bp = #{colBp} ,</if>
<if test="colBq != null">col_bq = #{colBq} ,</if>
<if test="colBr != null">col_br = #{colBr} ,</if>
<if test="colBs != null">col_bs = #{colBs} ,</if>
<if test="colBt != null">col_bt = #{colBt} ,</if>
<if test="colBu != null">col_bu = #{colBu} ,</if>
<if test="colBv != null">col_bv = #{colBv} ,</if>
<if test="colBw != null">col_bw = #{colBw} ,</if>
<if test="colBx != null">col_bx = #{colBx} ,</if>
<if test="colBy != null">col_by = #{colBy} ,</if>
<if test="colBz != null">col_bz = #{colBz} ,</if>
<if test="createTime != null">create_time = #{createTime},</if>
<if test="createBy != null">create_by = #{createBy},</if>
<if test="updateBy != null">update_by = #{updateBy},</if>
update_time = sysdate()
</trim>
where id = #{id}
</update>
<delete id="deleteMcsbExcelDataById" parameterType="Long">
delete from mcsb_excel_data where id = #{id}
</delete>
<delete id="deleteMcsbExcelDataByIds" parameterType="String">
delete from mcsb_excel_data where id in
<foreach item="id" collection="array" open="(" separator="," close=")">
#{id}
</foreach>
</delete>
<insert id="insertMcsbExcelDatabatch" parameterType="List">
insert into mcsb_excel_data(year,month,entity,col_cv,
col_a
, col_b
, col_c
, col_d
, col_e
, col_f
, col_g
, col_h
, col_i
, col_j
, col_k
, col_l
, col_m
, col_n
, col_o
, col_p
, col_q
, col_r
, col_s
, col_t
, col_u
, col_v
, col_w
, col_x
, col_y
, col_z
, col_aa,
col_ab,
col_ac,
col_ad,
col_ae,
col_af,
col_ag,
col_ah,
col_ai,
col_aj,
col_ak,
col_al,
col_am,
col_an,
col_ao,
col_ap,
col_aq,
col_ar,
col_as,
col_at,
col_au,
col_av,
col_aw,
col_ax,
col_ay,
col_az,
col_ba,
col_bb,
col_bc,
col_bd,
col_be,
col_bf,
col_bg,
col_bh,
col_bi,
col_bj,
col_bk,
col_bl,
col_bm,
col_bn,
col_bo,
col_bp,
col_bq,
col_br,
col_bs,
col_bt,
col_bu,
col_bv,
col_bw,
col_bx,
col_by,
col_bz,
record_id,create_time,row_n) values
<foreach collection="list" item="item" separator=",">
(#{item.year},
#{item.month},
#{item.entity},
#{item.colCv},
#{item.colA},
#{item.colB},
#{item.colC},
#{item.colD},
#{item.colE},
#{item.colF},
#{item.colG},
#{item.colH},
#{item.colI},
#{item.colJ},
#{item.colK},
#{item.colL},
#{item.colM},
#{item.colN},
#{item.colO},
#{item.colP},
#{item.colQ},
#{item.colR},
#{item.colS},
#{item.colT},
#{item.colU},
#{item.colV},
#{item.colW},
#{item.colX},
#{item.colY},
#{item.colZ},
#{item.colAa},
#{item.colAb},
#{item.colAc},
#{item.colAd},
#{item.colAe},
#{item.colAf},
#{item.colAg},
#{item.colAh},
#{item.colAi},
#{item.colAj},
#{item.colAk},
#{item.colAl},
#{item.colAm},
#{item.colAn},
#{item.colAo},
#{item.colAp},
#{item.colAq},
#{item.colAr},
#{item.colAs},
#{item.colAt},
#{item.colAu},
#{item.colAv},
#{item.colAw},
#{item.colAx},
#{item.colAy},
#{item.colAz},
#{item.colBa},
#{item.colBb},
#{item.colBc},
#{item.colBd},
#{item.colBe},
#{item.colBf},
#{item.colBg},
#{item.colBh},
#{item.colBi},
#{item.colBj},
#{item.colBk},
#{item.colBl},
#{item.colBm},
#{item.colBn},
#{item.colBo},
#{item.colBp},
#{item.colBq},
#{item.colBr},
#{item.colBs},
#{item.colBt},
#{item.colBu},
#{item.colBv},
#{item.colBw},
#{item.colBx},
#{item.colBy},
#{item.colBz},
#{item.recordId},
sysdate(),#{item.rowN})
</foreach>
</insert>
<delete id="deleteByRecordId" parameterType="Long">
delete from mcsb_excel_data where record_id = #{recordId}
</delete>
<select id="filterAndSum" resultMap="McsbExcelDataResult" parameterType="com.chinagas.modules.mcsb.domain.queryObject.McsbExcelDataQO">
SELECT row_n,sum(col_b) as col_b,sum(col_f) as col_f,sum(col_g) as col_g,sum(col_k) as col_k,sum(col_l) as col_l,sum(col_p) as col_p,sum(col_q) as col_q,sum(col_u) as col_u,sum(col_v) as col_v,sum(col_z) as col_z,sum(col_aa) as col_aa,sum(col_ae) as col_ae,sum(col_af) as col_af,sum(col_aj) as col_aj,sum(col_ak) as col_ak,sum(col_ao) as col_ao,sum(col_ap) as col_ap,sum(col_at) as col_at,sum(col_au) as col_au,sum(col_ay) as col_ay,sum(col_az) as col_az,sum(col_bd) as col_bd,sum(col_be) as col_be,sum(col_bi) as col_bi,sum(col_bj) as col_bj,sum(col_bn) as col_bn,sum(col_bo) as col_bo,sum(col_bs) as col_bs
FROM `mcsb_excel_data`
<where>
<if test="year != null and year != ''"> and year = #{year}</if>
<if test="month != null and month != ''"> and month = #{month}</if>
<if test="entity != null and entity != ''"> and entity in
<foreach collection="entity" open="(" separator="," close=")" item="item">
#{item}
</foreach>
</if>
</where>
GROUP BY row_n ORDER BY row_n
</select>
<select id="getDataByRowNs" resultMap="McsbExcelDataResult" parameterType="java.util.List">
SELECT * from `mcsb_excel_data` WHERE row_n in
<foreach collection="list" open="(" separator="," close=")" item="item">
#{item}
</foreach>
GROUP BY col_cv ORDER BY row_n
</select>
</mapper>