/[openfoncier]/trunk/obj/dossier_autorisation.class.php
ViewVC logotype

Diff of /trunk/obj/dossier_autorisation.class.php

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 4677 by nmeucci, Fri May 27 15:04:00 2016 UTC revision 4678 by softime, Thu Jun 30 11:23:04 2016 UTC
# Line 228  class dossier_autorisation extends dossi Line 228  class dossier_autorisation extends dossi
228                      TRIM(dm_projet_desc)                      TRIM(dm_projet_desc)
229                  END                  END
230              ) as \"description_projet\",              ) as \"description_projet\",
231              REGEXP_REPLACE(CONCAT(              -- Si une valeur est saisie dans la deuxième version du tableau des
232                  CASE              -- surfaces alors on récupère seulement ses valeurs
233                      WHEN donnees_techniques.su_cstr_shon1 IS NULL              CASE WHEN su2_avt_shon1 IS NOT NULL
234                      THEN ''                  OR su2_avt_shon2 IS NOT NULL
235                      ELSE CONCAT('Habitation - ', donnees_techniques.su_cstr_shon1, ' m² <br/>')                  OR su2_avt_shon3 IS NOT NULL
236                  END,                  OR su2_avt_shon4 IS NOT NULL
237                  CASE                  OR su2_avt_shon5 IS NOT NULL
238                      WHEN donnees_techniques.su_cstr_shon2 IS NULL                  OR su2_avt_shon6 IS NOT NULL
239                      THEN ''                  OR su2_avt_shon7 IS NOT NULL
240                      ELSE CONCAT('Hébergement hôtelier - ', donnees_techniques.su_cstr_shon2, ' m² <br/>')                  OR su2_avt_shon8 IS NOT NULL
241                  END,                  OR su2_avt_shon9 IS NOT NULL
242                  CASE                  OR su2_avt_shon10 IS NOT NULL
243                      WHEN donnees_techniques.su_cstr_shon3 IS NULL                  OR su2_avt_shon11 IS NOT NULL
244                      THEN ''                  OR su2_avt_shon12 IS NOT NULL
245                      ELSE CONCAT('Bureaux - ', donnees_techniques.su_cstr_shon3, ' m² <br/>')                  OR su2_avt_shon13 IS NOT NULL
246                  END,                  OR su2_avt_shon14 IS NOT NULL
247                  CASE                  OR su2_avt_shon15 IS NOT NULL
248                      WHEN donnees_techniques.su_cstr_shon4 IS NULL                  OR su2_avt_shon16 IS NOT NULL
249                      THEN ''                  OR su2_avt_shon17 IS NOT NULL
250                      ELSE CONCAT('Commerce - ', donnees_techniques.su_cstr_shon4, ' m² <br/>')                  OR su2_avt_shon18 IS NOT NULL
251                  END,                  OR su2_avt_shon19 IS NOT NULL
252                  CASE                  OR su2_avt_shon20 IS NOT NULL
253                      WHEN donnees_techniques.su_cstr_shon5 IS NULL                  OR su2_cstr_shon1 IS NOT NULL
254                      THEN ''                  OR su2_cstr_shon2 IS NOT NULL
255                      ELSE CONCAT('Artisanat - ', donnees_techniques.su_cstr_shon5, ' m² <br/>')                  OR su2_cstr_shon3 IS NOT NULL
256                  END,                  OR su2_cstr_shon4 IS NOT NULL
257                  CASE                  OR su2_cstr_shon5 IS NOT NULL
258                      WHEN donnees_techniques.su_cstr_shon6 IS NULL                  OR su2_cstr_shon6 IS NOT NULL
259                      THEN ''                  OR su2_cstr_shon7 IS NOT NULL
260                      ELSE CONCAT('Industrie - ', donnees_techniques.su_cstr_shon6, ' m² <br/>')                  OR su2_cstr_shon8 IS NOT NULL
261                  END,                  OR su2_cstr_shon9 IS NOT NULL
262                  CASE                  OR su2_cstr_shon10 IS NOT NULL
263                      WHEN donnees_techniques.su_cstr_shon7 IS NULL                  OR su2_cstr_shon11 IS NOT NULL
264                      THEN ''                  OR su2_cstr_shon12 IS NOT NULL
265                      ELSE CONCAT('Exploitation agricole ou forestière - ', donnees_techniques.su_cstr_shon7, ' m² <br/>')                  OR su2_cstr_shon13 IS NOT NULL
266                  END,                  OR su2_cstr_shon14 IS NOT NULL
267                  CASE                  OR su2_cstr_shon15 IS NOT NULL
268                      WHEN donnees_techniques.su_cstr_shon8 IS NULL                  OR su2_cstr_shon16 IS NOT NULL
269                      THEN ''                  OR su2_cstr_shon17 IS NOT NULL
270                      ELSE CONCAT('Entrepôt - ', donnees_techniques.su_cstr_shon8, ' m² <br/>')                  OR su2_cstr_shon18 IS NOT NULL
271                  END,                  OR su2_cstr_shon19 IS NOT NULL
272                  CASE                  OR su2_cstr_shon20 IS NOT NULL
273                      WHEN donnees_techniques.su_cstr_shon9 IS NULL                  OR su2_chge_shon1 IS NOT NULL
274                      THEN ''                  OR su2_chge_shon2 IS NOT NULL
275                      ELSE CONCAT('Service public ou d''intérêt collectif - ', donnees_techniques.su_cstr_shon9, ' m²')                  OR su2_chge_shon3 IS NOT NULL
276                  END                  OR su2_chge_shon4 IS NOT NULL
277              ), ' <br/>$', '') as \"surface\",                  OR su2_chge_shon5 IS NOT NULL
278                    OR su2_chge_shon6 IS NOT NULL
279                    OR su2_chge_shon7 IS NOT NULL
280                    OR su2_chge_shon8 IS NOT NULL
281                    OR su2_chge_shon9 IS NOT NULL
282                    OR su2_chge_shon10 IS NOT NULL
283                    OR su2_chge_shon11 IS NOT NULL
284                    OR su2_chge_shon12 IS NOT NULL
285                    OR su2_chge_shon13 IS NOT NULL
286                    OR su2_chge_shon14 IS NOT NULL
287                    OR su2_chge_shon15 IS NOT NULL
288                    OR su2_chge_shon16 IS NOT NULL
289                    OR su2_chge_shon17 IS NOT NULL
290                    OR su2_chge_shon18 IS NOT NULL
291                    OR su2_chge_shon19 IS NOT NULL
292                    OR su2_chge_shon20 IS NOT NULL
293                    OR su2_demo_shon1 IS NOT NULL
294                    OR su2_demo_shon2 IS NOT NULL
295                    OR su2_demo_shon3 IS NOT NULL
296                    OR su2_demo_shon4 IS NOT NULL
297                    OR su2_demo_shon5 IS NOT NULL
298                    OR su2_demo_shon6 IS NOT NULL
299                    OR su2_demo_shon7 IS NOT NULL
300                    OR su2_demo_shon8 IS NOT NULL
301                    OR su2_demo_shon9 IS NOT NULL
302                    OR su2_demo_shon10 IS NOT NULL
303                    OR su2_demo_shon11 IS NOT NULL
304                    OR su2_demo_shon12 IS NOT NULL
305                    OR su2_demo_shon13 IS NOT NULL
306                    OR su2_demo_shon14 IS NOT NULL
307                    OR su2_demo_shon15 IS NOT NULL
308                    OR su2_demo_shon16 IS NOT NULL
309                    OR su2_demo_shon17 IS NOT NULL
310                    OR su2_demo_shon18 IS NOT NULL
311                    OR su2_demo_shon19 IS NOT NULL
312                    OR su2_demo_shon20 IS NOT NULL
313                    OR su2_sup_shon1 IS NOT NULL
314                    OR su2_sup_shon2 IS NOT NULL
315                    OR su2_sup_shon3 IS NOT NULL
316                    OR su2_sup_shon4 IS NOT NULL
317                    OR su2_sup_shon5 IS NOT NULL
318                    OR su2_sup_shon6 IS NOT NULL
319                    OR su2_sup_shon7 IS NOT NULL
320                    OR su2_sup_shon8 IS NOT NULL
321                    OR su2_sup_shon9 IS NOT NULL
322                    OR su2_sup_shon10 IS NOT NULL
323                    OR su2_sup_shon11 IS NOT NULL
324                    OR su2_sup_shon12 IS NOT NULL
325                    OR su2_sup_shon13 IS NOT NULL
326                    OR su2_sup_shon14 IS NOT NULL
327                    OR su2_sup_shon15 IS NOT NULL
328                    OR su2_sup_shon16 IS NOT NULL
329                    OR su2_sup_shon17 IS NOT NULL
330                    OR su2_sup_shon18 IS NOT NULL
331                    OR su2_sup_shon19 IS NOT NULL
332                    OR su2_sup_shon20 IS NOT NULL
333                    THEN
334                        REGEXP_REPLACE(CONCAT(
335                            CASE WHEN donnees_techniques.su2_cstr_shon1 IS NULL
336                                THEN ''
337                                ELSE CONCAT ('Exploitation agricole - ', donnees_techniques.su2_cstr_shon1, ' m² <br/>')
338                            END,
339                            CASE WHEN donnees_techniques.su2_cstr_shon2 IS NULL
340                                THEN ''
341                                ELSE CONCAT ('Exploitation forestière - ', donnees_techniques.su2_cstr_shon2, ' m² <br/>')
342                            END,
343                            CASE WHEN donnees_techniques.su2_cstr_shon3 IS NULL
344                                THEN ''
345                                ELSE CONCAT ('Logement - ', donnees_techniques.su2_cstr_shon3, ' m² <br/>')
346                            END,
347                            CASE WHEN donnees_techniques.su2_cstr_shon4 IS NULL
348                                THEN ''
349                                ELSE CONCAT ('Hébergement - ', donnees_techniques.su2_cstr_shon4, ' m² <br/>')
350                            END,
351                            CASE WHEN donnees_techniques.su2_cstr_shon5 IS NULL
352                                THEN ''
353                                ELSE CONCAT ('Artisanat et commerce de détail - ', donnees_techniques.su2_cstr_shon5, ' m² <br/>')
354                            END,
355                            CASE WHEN donnees_techniques.su2_cstr_shon6 IS NULL
356                                THEN ''
357                                ELSE CONCAT ('Restauration - ', donnees_techniques.su2_cstr_shon6, ' m² <br/>')
358                            END,
359                            CASE WHEN donnees_techniques.su2_cstr_shon7 IS NULL
360                                THEN ''
361                                ELSE CONCAT ('Commerce de gros - ', donnees_techniques.su2_cstr_shon7, ' m² <br/>')
362                            END,
363                            CASE WHEN donnees_techniques.su2_cstr_shon8 IS NULL
364                                THEN ''
365                                ELSE CONCAT ('Activités de services où s''effectue l''accueil d''une clientèle - ', donnees_techniques.su2_cstr_shon8, ' m² <br/>')
366                            END,
367                            CASE WHEN donnees_techniques.su2_cstr_shon9 IS NULL
368                                THEN ''
369                                ELSE CONCAT ('Hébergement hôtelier et touristique - ', donnees_techniques.su2_cstr_shon9, ' m² <br/>')
370                            END,
371                            CASE WHEN donnees_techniques.su2_cstr_shon10 IS NULL
372                                THEN ''
373                                ELSE CONCAT ('Cinéma - ', donnees_techniques.su2_cstr_shon10, ' m² <br/>')
374                            END,
375                            CASE WHEN donnees_techniques.su2_cstr_shon11 IS NULL
376                                THEN ''
377                                ELSE CONCAT ('Locaux et bureaux accueillant du public des administrations publiques et assimilés - ', donnees_techniques.su2_cstr_shon11, ' m² <br/>')
378                            END,
379                            CASE WHEN donnees_techniques.su2_cstr_shon12 IS NULL
380                                THEN ''
381                                ELSE CONCAT ('Locaux techniques et industriels des administrations publiques et assimilés - ', donnees_techniques.su2_cstr_shon12, ' m² <br/>')
382                            END,
383                            CASE WHEN donnees_techniques.su2_cstr_shon13 IS NULL
384                                THEN ''
385                                ELSE CONCAT ('Établissements d''enseignement, de santé et d''action sociale - ', donnees_techniques.su2_cstr_shon13, ' m² <br/>')
386                            END,
387                            CASE WHEN donnees_techniques.su2_cstr_shon14 IS NULL
388                                THEN ''
389                                ELSE CONCAT ('Salles d''art et de spectacles - ', donnees_techniques.su2_cstr_shon14, ' m² <br/>')
390                            END,
391                            CASE WHEN donnees_techniques.su2_cstr_shon15 IS NULL
392                                THEN ''
393                                ELSE CONCAT ('Équipements sportifs - ', donnees_techniques.su2_cstr_shon15, ' m² <br/>')
394                            END,
395                            CASE WHEN donnees_techniques.su2_cstr_shon16 IS NULL
396                                THEN ''
397                                ELSE CONCAT ('Autres équipements recevant du public - ', donnees_techniques.su2_cstr_shon16, ' m² <br/>')
398                            END,
399                            CASE WHEN donnees_techniques.su2_cstr_shon17 IS NULL
400                                THEN ''
401                                ELSE CONCAT ('Industrie - ', donnees_techniques.su2_cstr_shon17, ' m² <br/>')
402                            END,
403                            CASE WHEN donnees_techniques.su2_cstr_shon18 IS NULL
404                                THEN ''
405                                ELSE CONCAT ('Entrepôt - ', donnees_techniques.su2_cstr_shon18, ' m² <br/>')
406                            END,
407                            CASE WHEN donnees_techniques.su2_cstr_shon19 IS NULL
408                                THEN ''
409                                ELSE CONCAT ('Bureau - ', donnees_techniques.su2_cstr_shon19, ' m² <br/>')
410                            END,
411                            CASE WHEN donnees_techniques.su2_cstr_shon20 IS NULL
412                                THEN ''
413                                ELSE CONCAT ('Centre de congrès et d''exposition - ', donnees_techniques.su2_cstr_shon20, ' m²')
414                            END
415                        ), ' <br/>$', '')
416                    ELSE
417                        REGEXP_REPLACE(CONCAT(
418                            CASE
419                                WHEN donnees_techniques.su_cstr_shon1 IS NULL
420                                THEN ''
421                                ELSE CONCAT('Habitation - ', donnees_techniques.su_cstr_shon1, ' m² <br/>')
422                            END,
423                            CASE
424                                WHEN donnees_techniques.su_cstr_shon2 IS NULL
425                                THEN ''
426                                ELSE CONCAT('Hébergement hôtelier - ', donnees_techniques.su_cstr_shon2, ' m² <br/>')
427                            END,
428                            CASE
429                                WHEN donnees_techniques.su_cstr_shon3 IS NULL
430                                THEN ''
431                                ELSE CONCAT('Bureaux - ', donnees_techniques.su_cstr_shon3, ' m² <br/>')
432                            END,
433                            CASE
434                                WHEN donnees_techniques.su_cstr_shon4 IS NULL
435                                THEN ''
436                                ELSE CONCAT('Commerce - ', donnees_techniques.su_cstr_shon4, ' m² <br/>')
437                            END,
438                            CASE
439                                WHEN donnees_techniques.su_cstr_shon5 IS NULL
440                                THEN ''
441                                ELSE CONCAT('Artisanat - ', donnees_techniques.su_cstr_shon5, ' m² <br/>')
442                            END,
443                            CASE
444                                WHEN donnees_techniques.su_cstr_shon6 IS NULL
445                                THEN ''
446                                ELSE CONCAT('Industrie - ', donnees_techniques.su_cstr_shon6, ' m² <br/>')
447                            END,
448                            CASE
449                                WHEN donnees_techniques.su_cstr_shon7 IS NULL
450                                THEN ''
451                                ELSE CONCAT('Exploitation agricole ou forestière - ', donnees_techniques.su_cstr_shon7, ' m² <br/>')
452                            END,
453                            CASE
454                                WHEN donnees_techniques.su_cstr_shon8 IS NULL
455                                THEN ''
456                                ELSE CONCAT('Entrepôt - ', donnees_techniques.su_cstr_shon8, ' m² <br/>')
457                            END,
458                            CASE
459                                WHEN donnees_techniques.su_cstr_shon9 IS NULL
460                                THEN ''
461                                ELSE CONCAT('Service public ou d''intérêt collectif - ', donnees_techniques.su_cstr_shon9, ' m²')
462                            END
463                        ), ' <br/>$', '')
464                END as \"surface\",
465              co_tot_ind_nb as \"nombre_logement_crees_individuel\",              co_tot_ind_nb as \"nombre_logement_crees_individuel\",
466              co_tot_coll_nb as \"nombre_logement_crees_collectif\"              co_tot_coll_nb as \"nombre_logement_crees_collectif\"
467              FROM              FROM
# Line 440  class dossier_autorisation extends dossi Line 627  class dossier_autorisation extends dossi
627                          TRIM(dm_projet_desc)                          TRIM(dm_projet_desc)
628                      END                      END
629                  ) as \"description_projet\",                  ) as \"description_projet\",
630                  REGEXP_REPLACE(CONCAT(                  -- Si une valeur est saisie dans la deuxième version du tableau
631                      CASE                  -- des surfaces alors on récupère seulement ses valeurs
632                          WHEN donnees_techniques.su_cstr_shon1 IS NULL                  CASE WHEN su2_avt_shon1 IS NOT NULL
633                          THEN ''                      OR su2_avt_shon2 IS NOT NULL
634                          ELSE CONCAT('Habitation - ', donnees_techniques.su_cstr_shon1, ' m² <br/>')                      OR su2_avt_shon3 IS NOT NULL
635                      END,                      OR su2_avt_shon4 IS NOT NULL
636                      CASE                      OR su2_avt_shon5 IS NOT NULL
637                          WHEN donnees_techniques.su_cstr_shon2 IS NULL                      OR su2_avt_shon6 IS NOT NULL
638                          THEN ''                      OR su2_avt_shon7 IS NOT NULL
639                          ELSE CONCAT('Hébergement hôtelier - ', donnees_techniques.su_cstr_shon2, ' m² <br/>')                      OR su2_avt_shon8 IS NOT NULL
640                      END,                      OR su2_avt_shon9 IS NOT NULL
641                      CASE                      OR su2_avt_shon10 IS NOT NULL
642                          WHEN donnees_techniques.su_cstr_shon3 IS NULL                      OR su2_avt_shon11 IS NOT NULL
643                          THEN ''                      OR su2_avt_shon12 IS NOT NULL
644                          ELSE CONCAT('Bureaux - ', donnees_techniques.su_cstr_shon3, ' m² <br/>')                      OR su2_avt_shon13 IS NOT NULL
645                      END,                      OR su2_avt_shon14 IS NOT NULL
646                      CASE                      OR su2_avt_shon15 IS NOT NULL
647                          WHEN donnees_techniques.su_cstr_shon4 IS NULL                      OR su2_avt_shon16 IS NOT NULL
648                          THEN ''                      OR su2_avt_shon17 IS NOT NULL
649                          ELSE CONCAT('Commerce - ', donnees_techniques.su_cstr_shon4, ' m² <br/>')                      OR su2_avt_shon18 IS NOT NULL
650                      END,                      OR su2_avt_shon19 IS NOT NULL
651                      CASE                      OR su2_avt_shon20 IS NOT NULL
652                          WHEN donnees_techniques.su_cstr_shon5 IS NULL                      OR su2_cstr_shon1 IS NOT NULL
653                          THEN ''                      OR su2_cstr_shon2 IS NOT NULL
654                          ELSE CONCAT('Artisanat - ', donnees_techniques.su_cstr_shon5, ' m² <br/>')                      OR su2_cstr_shon3 IS NOT NULL
655                      END,                      OR su2_cstr_shon4 IS NOT NULL
656                      CASE                      OR su2_cstr_shon5 IS NOT NULL
657                          WHEN donnees_techniques.su_cstr_shon6 IS NULL                      OR su2_cstr_shon6 IS NOT NULL
658                          THEN ''                      OR su2_cstr_shon7 IS NOT NULL
659                          ELSE CONCAT('Industrie - ', donnees_techniques.su_cstr_shon6, ' m² <br/>')                      OR su2_cstr_shon8 IS NOT NULL
660                      END,                      OR su2_cstr_shon9 IS NOT NULL
661                      CASE                      OR su2_cstr_shon10 IS NOT NULL
662                          WHEN donnees_techniques.su_cstr_shon7 IS NULL                      OR su2_cstr_shon11 IS NOT NULL
663                          THEN ''                      OR su2_cstr_shon12 IS NOT NULL
664                          ELSE CONCAT('Exploitation agricole ou forestière - ', donnees_techniques.su_cstr_shon7, ' m² <br/>')                      OR su2_cstr_shon13 IS NOT NULL
665                      END,                      OR su2_cstr_shon14 IS NOT NULL
666                      CASE                      OR su2_cstr_shon15 IS NOT NULL
667                          WHEN donnees_techniques.su_cstr_shon8 IS NULL                      OR su2_cstr_shon16 IS NOT NULL
668                          THEN ''                      OR su2_cstr_shon17 IS NOT NULL
669                          ELSE CONCAT('Entrepôt - ', donnees_techniques.su_cstr_shon8, ' m² <br/>')                      OR su2_cstr_shon18 IS NOT NULL
670                      END,                      OR su2_cstr_shon19 IS NOT NULL
671                      CASE                      OR su2_cstr_shon20 IS NOT NULL
672                          WHEN donnees_techniques.su_cstr_shon9 IS NULL                      OR su2_chge_shon1 IS NOT NULL
673                          THEN ''                      OR su2_chge_shon2 IS NOT NULL
674                          ELSE CONCAT('Service public ou d''intérêt collectif - ', donnees_techniques.su_cstr_shon9, ' m²')                      OR su2_chge_shon3 IS NOT NULL
675                      END                      OR su2_chge_shon4 IS NOT NULL
676                  ), ' <br/>$', '') as \"surface\",                      OR su2_chge_shon5 IS NOT NULL
677                        OR su2_chge_shon6 IS NOT NULL
678                        OR su2_chge_shon7 IS NOT NULL
679                        OR su2_chge_shon8 IS NOT NULL
680                        OR su2_chge_shon9 IS NOT NULL
681                        OR su2_chge_shon10 IS NOT NULL
682                        OR su2_chge_shon11 IS NOT NULL
683                        OR su2_chge_shon12 IS NOT NULL
684                        OR su2_chge_shon13 IS NOT NULL
685                        OR su2_chge_shon14 IS NOT NULL
686                        OR su2_chge_shon15 IS NOT NULL
687                        OR su2_chge_shon16 IS NOT NULL
688                        OR su2_chge_shon17 IS NOT NULL
689                        OR su2_chge_shon18 IS NOT NULL
690                        OR su2_chge_shon19 IS NOT NULL
691                        OR su2_chge_shon20 IS NOT NULL
692                        OR su2_demo_shon1 IS NOT NULL
693                        OR su2_demo_shon2 IS NOT NULL
694                        OR su2_demo_shon3 IS NOT NULL
695                        OR su2_demo_shon4 IS NOT NULL
696                        OR su2_demo_shon5 IS NOT NULL
697                        OR su2_demo_shon6 IS NOT NULL
698                        OR su2_demo_shon7 IS NOT NULL
699                        OR su2_demo_shon8 IS NOT NULL
700                        OR su2_demo_shon9 IS NOT NULL
701                        OR su2_demo_shon10 IS NOT NULL
702                        OR su2_demo_shon11 IS NOT NULL
703                        OR su2_demo_shon12 IS NOT NULL
704                        OR su2_demo_shon13 IS NOT NULL
705                        OR su2_demo_shon14 IS NOT NULL
706                        OR su2_demo_shon15 IS NOT NULL
707                        OR su2_demo_shon16 IS NOT NULL
708                        OR su2_demo_shon17 IS NOT NULL
709                        OR su2_demo_shon18 IS NOT NULL
710                        OR su2_demo_shon19 IS NOT NULL
711                        OR su2_demo_shon20 IS NOT NULL
712                        OR su2_sup_shon1 IS NOT NULL
713                        OR su2_sup_shon2 IS NOT NULL
714                        OR su2_sup_shon3 IS NOT NULL
715                        OR su2_sup_shon4 IS NOT NULL
716                        OR su2_sup_shon5 IS NOT NULL
717                        OR su2_sup_shon6 IS NOT NULL
718                        OR su2_sup_shon7 IS NOT NULL
719                        OR su2_sup_shon8 IS NOT NULL
720                        OR su2_sup_shon9 IS NOT NULL
721                        OR su2_sup_shon10 IS NOT NULL
722                        OR su2_sup_shon11 IS NOT NULL
723                        OR su2_sup_shon12 IS NOT NULL
724                        OR su2_sup_shon13 IS NOT NULL
725                        OR su2_sup_shon14 IS NOT NULL
726                        OR su2_sup_shon15 IS NOT NULL
727                        OR su2_sup_shon16 IS NOT NULL
728                        OR su2_sup_shon17 IS NOT NULL
729                        OR su2_sup_shon18 IS NOT NULL
730                        OR su2_sup_shon19 IS NOT NULL
731                        OR su2_sup_shon20 IS NOT NULL
732                        THEN
733                            REGEXP_REPLACE(CONCAT(
734                                CASE WHEN donnees_techniques.su2_cstr_shon1 IS NULL
735                                    THEN ''
736                                    ELSE CONCAT ('Exploitation agricole - ', donnees_techniques.su2_cstr_shon1, ' m² <br/>')
737                                END,
738                                CASE WHEN donnees_techniques.su2_cstr_shon2 IS NULL
739                                    THEN ''
740                                    ELSE CONCAT ('Exploitation forestière - ', donnees_techniques.su2_cstr_shon2, ' m² <br/>')
741                                END,
742                                CASE WHEN donnees_techniques.su2_cstr_shon3 IS NULL
743                                    THEN ''
744                                    ELSE CONCAT ('Logement - ', donnees_techniques.su2_cstr_shon3, ' m² <br/>')
745                                END,
746                                CASE WHEN donnees_techniques.su2_cstr_shon4 IS NULL
747                                    THEN ''
748                                    ELSE CONCAT ('Hébergement - ', donnees_techniques.su2_cstr_shon4, ' m² <br/>')
749                                END,
750                                CASE WHEN donnees_techniques.su2_cstr_shon5 IS NULL
751                                    THEN ''
752                                    ELSE CONCAT ('Artisanat et commerce de détail - ', donnees_techniques.su2_cstr_shon5, ' m² <br/>')
753                                END,
754                                CASE WHEN donnees_techniques.su2_cstr_shon6 IS NULL
755                                    THEN ''
756                                    ELSE CONCAT ('Restauration - ', donnees_techniques.su2_cstr_shon6, ' m² <br/>')
757                                END,
758                                CASE WHEN donnees_techniques.su2_cstr_shon7 IS NULL
759                                    THEN ''
760                                    ELSE CONCAT ('Commerce de gros - ', donnees_techniques.su2_cstr_shon7, ' m² <br/>')
761                                END,
762                                CASE WHEN donnees_techniques.su2_cstr_shon8 IS NULL
763                                    THEN ''
764                                    ELSE CONCAT ('Activités de services où s''effectue l''accueil d''une clientèle - ', donnees_techniques.su2_cstr_shon8, ' m² <br/>')
765                                END,
766                                CASE WHEN donnees_techniques.su2_cstr_shon9 IS NULL
767                                    THEN ''
768                                    ELSE CONCAT ('Hébergement hôtelier et touristique - ', donnees_techniques.su2_cstr_shon9, ' m² <br/>')
769                                END,
770                                CASE WHEN donnees_techniques.su2_cstr_shon10 IS NULL
771                                    THEN ''
772                                    ELSE CONCAT ('Cinéma - ', donnees_techniques.su2_cstr_shon10, ' m² <br/>')
773                                END,
774                                CASE WHEN donnees_techniques.su2_cstr_shon11 IS NULL
775                                    THEN ''
776                                    ELSE CONCAT ('Locaux et bureaux accueillant du public des administrations publiques et assimilés - ', donnees_techniques.su2_cstr_shon11, ' m² <br/>')
777                                END,
778                                CASE WHEN donnees_techniques.su2_cstr_shon12 IS NULL
779                                    THEN ''
780                                    ELSE CONCAT ('Locaux techniques et industriels des administrations publiques et assimilés - ', donnees_techniques.su2_cstr_shon12, ' m² <br/>')
781                                END,
782                                CASE WHEN donnees_techniques.su2_cstr_shon13 IS NULL
783                                    THEN ''
784                                    ELSE CONCAT ('Établissements d''enseignement, de santé et d''action sociale - ', donnees_techniques.su2_cstr_shon13, ' m² <br/>')
785                                END,
786                                CASE WHEN donnees_techniques.su2_cstr_shon14 IS NULL
787                                    THEN ''
788                                    ELSE CONCAT ('Salles d''art et de spectacles - ', donnees_techniques.su2_cstr_shon14, ' m² <br/>')
789                                END,
790                                CASE WHEN donnees_techniques.su2_cstr_shon15 IS NULL
791                                    THEN ''
792                                    ELSE CONCAT ('Équipements sportifs - ', donnees_techniques.su2_cstr_shon15, ' m² <br/>')
793                                END,
794                                CASE WHEN donnees_techniques.su2_cstr_shon16 IS NULL
795                                    THEN ''
796                                    ELSE CONCAT ('Autres équipements recevant du public - ', donnees_techniques.su2_cstr_shon16, ' m² <br/>')
797                                END,
798                                CASE WHEN donnees_techniques.su2_cstr_shon17 IS NULL
799                                    THEN ''
800                                    ELSE CONCAT ('Industrie - ', donnees_techniques.su2_cstr_shon17, ' m² <br/>')
801                                END,
802                                CASE WHEN donnees_techniques.su2_cstr_shon18 IS NULL
803                                    THEN ''
804                                    ELSE CONCAT ('Entrepôt - ', donnees_techniques.su2_cstr_shon18, ' m² <br/>')
805                                END,
806                                CASE WHEN donnees_techniques.su2_cstr_shon19 IS NULL
807                                    THEN ''
808                                    ELSE CONCAT ('Bureau - ', donnees_techniques.su2_cstr_shon19, ' m² <br/>')
809                                END,
810                                CASE WHEN donnees_techniques.su2_cstr_shon20 IS NULL
811                                    THEN ''
812                                    ELSE CONCAT ('Centre de congrès et d''exposition - ', donnees_techniques.su2_cstr_shon20, ' m²')
813                                END
814                            ), ' <br/>$', '')
815                        ELSE
816                            REGEXP_REPLACE(CONCAT(
817                                CASE
818                                    WHEN donnees_techniques.su_cstr_shon1 IS NULL
819                                    THEN ''
820                                    ELSE CONCAT('Habitation - ', donnees_techniques.su_cstr_shon1, ' m² <br/>')
821                                END,
822                                CASE
823                                    WHEN donnees_techniques.su_cstr_shon2 IS NULL
824                                    THEN ''
825                                    ELSE CONCAT('Hébergement hôtelier - ', donnees_techniques.su_cstr_shon2, ' m² <br/>')
826                                END,
827                                CASE
828                                    WHEN donnees_techniques.su_cstr_shon3 IS NULL
829                                    THEN ''
830                                    ELSE CONCAT('Bureaux - ', donnees_techniques.su_cstr_shon3, ' m² <br/>')
831                                END,
832                                CASE
833                                    WHEN donnees_techniques.su_cstr_shon4 IS NULL
834                                    THEN ''
835                                    ELSE CONCAT('Commerce - ', donnees_techniques.su_cstr_shon4, ' m² <br/>')
836                                END,
837                                CASE
838                                    WHEN donnees_techniques.su_cstr_shon5 IS NULL
839                                    THEN ''
840                                    ELSE CONCAT('Artisanat - ', donnees_techniques.su_cstr_shon5, ' m² <br/>')
841                                END,
842                                CASE
843                                    WHEN donnees_techniques.su_cstr_shon6 IS NULL
844                                    THEN ''
845                                    ELSE CONCAT('Industrie - ', donnees_techniques.su_cstr_shon6, ' m² <br/>')
846                                END,
847                                CASE
848                                    WHEN donnees_techniques.su_cstr_shon7 IS NULL
849                                    THEN ''
850                                    ELSE CONCAT('Exploitation agricole ou forestière - ', donnees_techniques.su_cstr_shon7, ' m² <br/>')
851                                END,
852                                CASE
853                                    WHEN donnees_techniques.su_cstr_shon8 IS NULL
854                                    THEN ''
855                                    ELSE CONCAT('Entrepôt - ', donnees_techniques.su_cstr_shon8, ' m² <br/>')
856                                END,
857                                CASE
858                                    WHEN donnees_techniques.su_cstr_shon9 IS NULL
859                                    THEN ''
860                                    ELSE CONCAT('Service public ou d''intérêt collectif - ', donnees_techniques.su_cstr_shon9, ' m²')
861                                END
862                            ), ' <br/>$', '')
863                    END as \"surface\",
864                  co_tot_ind_nb as \"nombre_logement_crees_individuel\",                  co_tot_ind_nb as \"nombre_logement_crees_individuel\",
865                  co_tot_coll_nb as \"nombre_logement_crees_collectif\"                  co_tot_coll_nb as \"nombre_logement_crees_collectif\"
866                  FROM ".DB_PREFIXE."donnees_techniques                  FROM ".DB_PREFIXE."donnees_techniques

Legend:
Removed from v.4677  
changed lines
  Added in v.4678

[email protected]
ViewVC Help
Powered by ViewVC 1.1.26