comparison flys-artifacts/doc/conf/meta-data.xml @ 5631:ca4b6263996c

Added old calculations to datacage 'M-INFO Sedimentfracht'. * Added facets to artifact config. * Added macros to datacage config. * Create subfolders for old calculations in datacage. * New outputs in sediment load generator.
author Raimund Renkert <rrenkert@intevation.de>
date Wed, 10 Apr 2013 15:04:56 +0200
parents 2d9eb188fa51
children dc731d2937f9
comparison
equal deleted inserted replaced
5630:619da3fa7a8b 5631:ca4b6263996c
607 ids="bedheight-singlevalues-{$bedh_id}-{$bedh_year}" 607 ids="bedheight-singlevalues-{$bedh_id}-{$bedh_year}"
608 description="{$bedh_descr}"/> 608 description="{$bedh_descr}"/>
609 </dc:for-each> 609 </dc:for-each>
610 </dc:context> 610 </dc:context>
611 </soundings_width> 611 </soundings_width>
612 </dc:macro>
613
614 <dc:macro name="morph_width">
615 <morph-width>
616 <dc:context>
617 <dc:statement>
618 SELECT id AS width_id
619 FROM morphologic_width
620 WHERE river_id = ${river_id}
621 </dc:statement>
622 <dc:for-each>
623 <dc:context>
624 <dc:statement>
625 SELECT min(station) AS from,
626 max(station) AS to
627 FROM morphologic_width_values
628 WHERE morphologic_width_id = ${width_id}
629 </dc:statement>
630 <dc:for-each>
631 <morphologic-width name="{$from} - {$to}"
632 ids="{$width_id}"
633 factory="morph-width"/>
634 </dc:for-each>
635 </dc:context>
636 </dc:for-each>
637 </dc:context>
638 </morph-width>
612 </dc:macro> 639 </dc:macro>
613 640
614 <dc:macro name="longitudinal-section-prototype"> 641 <dc:macro name="longitudinal-section-prototype">
615 <dc:call-macro name="basedata_0"/> 642 <dc:call-macro name="basedata_0"/>
616 <dc:call-macro name="basedata_1_additionals"/> 643 <dc:call-macro name="basedata_1_additionals"/>
729 <dc:call-macro name="annotations_per_type"/> 756 <dc:call-macro name="annotations_per_type"/>
730 <dc:call-macro name="flow_velocity_measurements"/> 757 <dc:call-macro name="flow_velocity_measurements"/>
731 </dc:if> 758 </dc:if>
732 <dc:if test="dc:contains($artifact-outs, 'bed_longitudinal_section')"> 759 <dc:if test="dc:contains($artifact-outs, 'bed_longitudinal_section')">
733 <dc:call-macro name="annotations_per_type"/> 760 <dc:call-macro name="annotations_per_type"/>
761 </dc:if>
762 <dc:if test="dc:contains($artifact-outs, 'sedimentload_ls')">
763 <dc:call-macro name="annotations_per_type"/>
764 <dc:call-macro name="morph_width"/>
734 </dc:if> 765 </dc:if>
735 <dc:comment> 766 <dc:comment>
736 MINFO bedheight middle 767 MINFO bedheight middle
737 </dc:comment> 768 </dc:comment>
738 <dc:if test="dc:contains($artifact-outs, 'bedheight_middle')"> 769 <dc:if test="dc:contains($artifact-outs, 'bedheight_middle')">
2510 <dc:for-each> 2541 <dc:for-each>
2511 <dc:context> 2542 <dc:context>
2512 <dc:call-macro name="range-filter"> 2543 <dc:call-macro name="range-filter">
2513 <dc:context> 2544 <dc:context>
2514 <dc:statement> 2545 <dc:statement>
2515 SELECT a.gid AS aid, 2546 SELECT id AS oid
2516 f.id AS fid, 2547 FROM outs AS o
2517 f.name AS facet_name,
2518 f.num AS facet_num,
2519 f.description AS facet_description
2520 FROM outs AS o, facets AS f, artifacts AS a
2521 WHERE 2548 WHERE
2522 (f.name = 'bed_longitudinal_section.bed_diameter_toplayer' 2549 o.artifact_id = ${a_id} AND
2523 OR f.name = 'bed_longitudinal_section.bed_diameter_sublayer') AND 2550 o.name='bed_longitudinal_section'
2524 f.out_id = o.id AND
2525 o.artifact_id = ${a_id} AND
2526 a.id = ${a_id}
2527 </dc:statement> 2551 </dc:statement>
2528 <dc:for-each> 2552 <dc:for-each>
2529 <dc:element name="${facet_name}"> 2553 <quality-bed description="{$river} {$a_creation} {$collection_name}">
2530 <dc:attribute name="factory" value="minfo"/> 2554 <dc:context>
2531 <dc:attribute name="description" value="${facet_description}"/> 2555 <dc:statement>
2532 <dc:attribute name="ids" value="${facet_num}-${facet_name}"/> 2556 SELECT a.gid AS aid,
2533 <dc:attribute name="artifact-id" value="${aid}"/> 2557 f.id AS fid,
2534 <dc:attribute name="out" value="bed_longitudinal_section"/> 2558 f.name AS facet_name,
2535 </dc:element> 2559 f.num AS facet_num,
2560 f.description AS facet_description
2561 FROM outs AS o, facets AS f, artifacts AS a
2562 WHERE
2563 (f.name = 'bed_longitudinal_section.bed_diameter_toplayer'
2564 OR f.name = 'bed_longitudinal_section.bed_diameter_sublayer') AND
2565 f.out_id = o.id AND
2566 o.artifact_id = ${a_id} AND
2567 a.id = ${a_id}
2568 </dc:statement>
2569 <dc:for-each>
2570 <dc:element name="${facet_name}">
2571 <dc:attribute name="factory" value="minfo"/>
2572 <dc:attribute name="description" value="${facet_description}"/>
2573 <dc:attribute name="ids" value="${facet_num}-${facet_name}"/>
2574 <dc:attribute name="artifact-id" value="${aid}"/>
2575 <dc:attribute name="out" value="bed_longitudinal_section"/>
2576 </dc:element>
2577 </dc:for-each>
2578 </dc:context>
2579 </quality-bed>
2536 </dc:for-each> 2580 </dc:for-each>
2537 </dc:context> 2581 </dc:context>
2538 </dc:call-macro> 2582 </dc:call-macro>
2539 </dc:context> 2583 </dc:context>
2540 </dc:for-each> 2584 </dc:for-each>
2546 <dc:for-each> 2590 <dc:for-each>
2547 <dc:context> 2591 <dc:context>
2548 <dc:call-macro name="range-filter"> 2592 <dc:call-macro name="range-filter">
2549 <dc:context> 2593 <dc:context>
2550 <dc:statement> 2594 <dc:statement>
2551 SELECT a.gid AS aid, 2595 SELECT id AS oid
2552 f.id AS fid, 2596 FROM outs AS o
2553 f.name AS facet_name,
2554 f.num AS facet_num,
2555 f.description AS facet_description
2556 FROM outs AS o, facets AS f, artifacts AS a
2557 WHERE 2597 WHERE
2558 f.name = 'bed_longitudinal_section.bedload_diameter' AND 2598 o.artifact_id = ${a_id} AND
2559 f.out_id = o.id AND 2599 o.name='bed_longitudinal_section'
2560 o.artifact_id = ${a_id} AND
2561 a.id = ${a_id}
2562 </dc:statement> 2600 </dc:statement>
2563 <dc:for-each> 2601 <dc:for-each>
2564 <dc:element name="${facet_name}"> 2602 <quality-load description="{$river} {$a_creation} {$collection_name}">
2565 <dc:attribute name="factory" value="minfo"/> 2603 <dc:context>
2566 <dc:attribute name="description" value="${facet_description}"/> 2604 <dc:statement>
2567 <dc:attribute name="ids" value="${facet_num}-${facet_name}"/> 2605 SELECT a.gid AS aid,
2568 <dc:attribute name="artifact-id" value="${aid}"/> 2606 f.id AS fid,
2569 <dc:attribute name="out" value="bed_longitudinal_section"/> 2607 f.name AS facet_name,
2570 </dc:element> 2608 f.num AS facet_num,
2609 f.description AS facet_description
2610 FROM outs AS o, facets AS f, artifacts AS a
2611 WHERE
2612 f.name = 'bed_longitudinal_section.bedload_diameter' AND
2613 f.out_id = o.id AND
2614 o.artifact_id = ${a_id} AND
2615 a.id = ${a_id}
2616 </dc:statement>
2617 <dc:for-each>
2618 <dc:element name="${facet_name}">
2619 <dc:attribute name="factory" value="minfo"/>
2620 <dc:attribute name="description" value="${facet_description}"/>
2621 <dc:attribute name="ids" value="${facet_num}-${facet_name}"/>
2622 <dc:attribute name="artifact-id" value="${aid}"/>
2623 <dc:attribute name="out" value="bed_longitudinal_section"/>
2624 </dc:element>
2625 </dc:for-each>
2626 </dc:context>
2627 </quality-load>
2571 </dc:for-each> 2628 </dc:for-each>
2572 </dc:context> 2629 </dc:context>
2573 </dc:call-macro> 2630 </dc:call-macro>
2574 </dc:context> 2631 </dc:context>
2575 </dc:for-each> 2632 </dc:for-each>
2579 <dc:macro name="bedquality-density"> 2636 <dc:macro name="bedquality-density">
2580 <bed_quality_density> 2637 <bed_quality_density>
2581 <dc:for-each> 2638 <dc:for-each>
2582 <dc:context> 2639 <dc:context>
2583 <dc:call-macro name="range-filter"> 2640 <dc:call-macro name="range-filter">
2584 <dc:context> 2641 <dc:context>
2585 <dc:statement> 2642 <dc:statement>
2586 SELECT a.gid AS aid, 2643 SELECT id AS oid
2587 f.id AS fid, 2644 FROM outs AS o
2588 f.name AS facet_name, 2645 WHERE
2589 f.num AS facet_num, 2646 o.artifact_id = ${a_id} AND
2590 f.description AS facet_description 2647 o.name='bed_longitudinal_section'
2591 FROM outs AS o, facets AS f, artifacts AS a 2648 </dc:statement>
2592 WHERE 2649 <dc:for-each>
2593 (f.name = 'bed_longitudinal_section.sediment_density_toplayer' OR 2650 <density description="{$river} {$a_creation} {$collection_name}">
2594 f.name = 'bed_longitudinal_section.sediment_density_sublayer') AND 2651 <dc:context>
2595 f.out_id = o.id AND 2652 <dc:statement>
2596 o.artifact_id = ${a_id} AND 2653 SELECT a.gid AS aid,
2597 a.id = ${a_id} 2654 f.id AS fid,
2598 </dc:statement> 2655 f.name AS facet_name,
2599 <dc:for-each> 2656 f.num AS facet_num,
2600 <dc:element name="${facet_name}"> 2657 f.description AS facet_description
2601 <dc:attribute name="factory" value="minfo"/> 2658 FROM outs AS o, facets AS f, artifacts AS a
2602 <dc:attribute name="description" value="${facet_description}"/> 2659 WHERE
2603 <dc:attribute name="ids" value="${facet_num}-${facet_name}"/> 2660 (f.name = 'bed_longitudinal_section.sediment_density_toplayer' OR
2604 <dc:attribute name="artifact-id" value="${aid}"/> 2661 f.name = 'bed_longitudinal_section.sediment_density_sublayer') AND
2605 <dc:attribute name="out" value="bed_longitudinal_section"/> 2662 f.out_id = o.id AND
2606 </dc:element> 2663 o.artifact_id = ${a_id} AND
2664 a.id = ${a_id}
2665 </dc:statement>
2666 <dc:for-each>
2667 <dc:element name="${facet_name}">
2668 <dc:attribute name="factory" value="minfo"/>
2669 <dc:attribute name="description" value="${facet_description}"/>
2670 <dc:attribute name="ids" value="${facet_num}-${facet_name}"/>
2671 <dc:attribute name="artifact-id" value="${aid}"/>
2672 <dc:attribute name="out" value="bed_longitudinal_section"/>
2673 </dc:element>
2674 </dc:for-each>
2675 </dc:context>
2676 </density>
2607 </dc:for-each> 2677 </dc:for-each>
2608 </dc:context> 2678 </dc:context>
2609 </dc:call-macro> 2679 </dc:call-macro>
2610 </dc:context> 2680 </dc:context>
2611 </dc:for-each> 2681 </dc:for-each>
2617 <dc:for-each> 2687 <dc:for-each>
2618 <dc:context> 2688 <dc:context>
2619 <dc:call-macro name="range-filter"> 2689 <dc:call-macro name="range-filter">
2620 <dc:context> 2690 <dc:context>
2621 <dc:statement> 2691 <dc:statement>
2622 SELECT a.gid AS aid, 2692 SELECT id AS oid
2623 f.id AS fid, 2693 FROM outs AS o
2624 f.name AS facet_name,
2625 f.num AS facet_num,
2626 f.description AS facet_description
2627 FROM outs AS o, facets AS f, artifacts AS a
2628 WHERE 2694 WHERE
2629 (f.name = 'bed_longitudinal_section.porosity_toplayer' OR 2695 o.artifact_id = ${a_id} AND
2630 f.name = 'bed_longitudinal_section.porosity_sublayer') AND 2696 o.name='bed_longitudinal_section'
2631 f.out_id = o.id AND
2632 o.artifact_id = ${a_id} AND
2633 a.id = ${a_id}
2634 </dc:statement> 2697 </dc:statement>
2635 <dc:for-each> 2698 <dc:for-each>
2636 <dc:element name="${facet_name}"> 2699 <porosity description="{$river} {$a_creation} {$collection_name}">
2637 <dc:attribute name="factory" value="minfo"/> 2700 <dc:context>
2638 <dc:attribute name="description" value="${facet_description}"/> 2701 <dc:statement>
2639 <dc:attribute name="ids" value="${facet_num}-${facet_name}"/> 2702 SELECT a.gid AS aid,
2640 <dc:attribute name="artifact-id" value="${aid}"/> 2703 f.id AS fid,
2641 <dc:attribute name="out" value="bed_longitudinal_section"/> 2704 f.name AS facet_name,
2642 </dc:element> 2705 f.num AS facet_num,
2706 f.description AS facet_description
2707 FROM outs AS o, facets AS f, artifacts AS a
2708 WHERE
2709 (f.name = 'bed_longitudinal_section.porosity_toplayer' OR
2710 f.name = 'bed_longitudinal_section.porosity_sublayer') AND
2711 f.out_id = o.id AND
2712 o.artifact_id = ${a_id} AND
2713 a.id = ${a_id}
2714 </dc:statement>
2715 <dc:for-each>
2716 <dc:element name="${facet_name}">
2717 <dc:attribute name="factory" value="minfo"/>
2718 <dc:attribute name="description" value="${facet_description}"/>
2719 <dc:attribute name="ids" value="${facet_num}-${facet_name}"/>
2720 <dc:attribute name="artifact-id" value="${aid}"/>
2721 <dc:attribute name="out" value="bed_longitudinal_section"/>
2722 </dc:element>
2723 </dc:for-each>
2724 </dc:context>
2725 </porosity>
2643 </dc:for-each> 2726 </dc:for-each>
2644 </dc:context> 2727 </dc:context>
2645 </dc:call-macro> 2728 </dc:call-macro>
2646 </dc:context> 2729 </dc:context>
2647 </dc:for-each> 2730 </dc:for-each>
2653 <dc:for-each> 2736 <dc:for-each>
2654 <dc:context> 2737 <dc:context>
2655 <dc:call-macro name="range-filter"> 2738 <dc:call-macro name="range-filter">
2656 <dc:context> 2739 <dc:context>
2657 <dc:statement> 2740 <dc:statement>
2658 SELECT a.gid AS aid, 2741 SELECT id AS oid
2659 f.id AS fid, 2742 FROM outs AS o
2660 f.name AS facet_name,
2661 f.num AS facet_num,
2662 f.description AS facet_description
2663 FROM outs AS o, facets AS f, artifacts AS a
2664 WHERE 2743 WHERE
2665 (f.name = 'flow_velocity.totalchannel' OR 2744 o.artifact_id = ${a_id} and o.name='flow_velocity'
2666 f.name = 'flow_velocity.mainchannel' OR
2667 f.name = 'flow_velocity.totalchannel.filtered' OR
2668 f.name = 'flow_velocity.mainchannel.filtered') AND
2669 f.out_id = o.id AND
2670 o.artifact_id = ${a_id} AND
2671 a.id = ${a_id}
2672 </dc:statement> 2745 </dc:statement>
2673 <dc:for-each> 2746 <dc:for-each>
2674 <dc:element name="${facet_name}"> 2747 <flow description="{$river} {$a_creation} {$collection_name}">
2675 <dc:attribute name="factory" value="minfo"/> 2748 <dc:context>
2676 <dc:attribute name="description" value="${facet_description}"/> 2749 <dc:statement>
2677 <dc:attribute name="ids" value="${facet_num}-${facet_name}"/> 2750 SELECT a.gid AS aid,
2678 <dc:attribute name="artifact-id" value="${aid}"/> 2751 f.id AS fid,
2679 <dc:attribute name="out" value="bed_longitudinal_section"/> 2752 f.name AS facet_name,
2680 </dc:element> 2753 f.num AS facet_num,
2754 f.description AS facet_description
2755 FROM outs AS o, facets AS f, artifacts AS a
2756 WHERE
2757 (f.name = 'flow_velocity.totalchannel' OR
2758 f.name = 'flow_velocity.mainchannel' OR
2759 f.name = 'flow_velocity.totalchannel.filtered' OR
2760 f.name = 'flow_velocity.mainchannel.filtered') AND
2761 f.out_id = o.id AND
2762 o.artifact_id = ${a_id} AND
2763 a.id = ${a_id}
2764 </dc:statement>
2765 <dc:for-each>
2766 <dc:element name="${facet_name}">
2767 <dc:attribute name="factory" value="minfo"/>
2768 <dc:attribute name="description" value="${facet_description}"/>
2769 <dc:attribute name="ids" value="${facet_num}-${facet_name}"/>
2770 <dc:attribute name="artifact-id" value="${aid}"/>
2771 <dc:attribute name="out" value="flow_velocity"/>
2772 </dc:element>
2773 </dc:for-each>
2774 </dc:context>
2775 </flow>
2681 </dc:for-each> 2776 </dc:for-each>
2682 </dc:context> 2777 </dc:context>
2683 </dc:call-macro> 2778 </dc:call-macro>
2684 </dc:context> 2779 </dc:context>
2685 </dc:for-each> 2780 </dc:for-each>
2686 </flow-velocity> 2781 </flow-velocity>
2782 </dc:macro>
2783
2784 <dc:macro name="sediment-load">
2785 <sediment-load>
2786 <dc:for-each>
2787 <dc:context>
2788 <dc:call-macro name="range-filter">
2789 <dc:context>
2790 <dc:statement>
2791 SELECT id AS oid
2792 FROM outs AS o
2793 WHERE
2794 o.artifact_id = ${a_id} and o.name='sedimentload_ls'
2795 </dc:statement>
2796 <dc:for-each>
2797 <load description="{$river} {$a_creation} {$collection_name}">
2798 <dc:context>
2799 <dc:statement>
2800 SELECT a.gid AS aid,
2801 f.id AS fid,
2802 f.name AS facet_name,
2803 f.num AS facet_num,
2804 f.description AS facet_description
2805 FROM outs AS o, facets AS f, artifacts AS a
2806 WHERE f.name LIKE 'sedimentload%' AND
2807 f.out_id = o.id AND
2808 o.artifact_id = ${a_id} AND
2809 a.id = ${a_id}
2810 </dc:statement>
2811 <dc:for-each>
2812 <dc:element name="${facet_name}">
2813 <dc:attribute name="factory" value="minfo"/>
2814 <dc:attribute name="description" value="${facet_description}"/>
2815 <dc:attribute name="ids" value="${facet_num}-${facet_name}"/>
2816 <dc:attribute name="artifact-id" value="${aid}"/>
2817 <dc:attribute name="out" value="sedimentload_ls"/>
2818 </dc:element>
2819 </dc:for-each>
2820 </dc:context>
2821 </load>
2822 </dc:for-each>
2823 </dc:context>
2824 </dc:call-macro>
2825 </dc:context>
2826 </dc:for-each>
2827 </sediment-load>
2828 </dc:macro>
2829
2830 <dc:macro name="bedheight-differences">
2831 <bedheight-differences>
2832 <dc:for-each>
2833 <dc:context>
2834 <dc:call-macro name="range-filter">
2835 <dc:context>
2836 <dc:statement>
2837 SELECT id AS oid,
2838 name AS o_name
2839 FROM outs AS o
2840 WHERE
2841 o.artifact_id = ${a_id} AND
2842 (o.name = 'bed_difference_year' OR
2843 o.name = 'bed_differnece_epoch')
2844 </dc:statement>
2845 <dc:for-each>
2846 <difference description="{$river} {$a_creation} {$collection_name}">
2847 <dc:context>
2848 <dc:statement>
2849 SELECT a.gid AS aid,
2850 f.id AS fid,
2851 f.name AS facet_name,
2852 f.num AS facet_num,
2853 f.description AS facet_description
2854 FROM outs AS o, facets AS f, artifacts AS a
2855 WHERE (f.name LIKE 'bedheight_difference.year%' OR
2856 f.name LIKE 'bedheight_difference.epoch%') AND
2857 f.out_id = o.id AND
2858 o.artifact_id = ${a_id} AND
2859 a.id = ${a_id}
2860 </dc:statement>
2861 <dc:for-each>
2862 <dc:element name="${facet_name}">
2863 <dc:attribute name="factory" value="minfo"/>
2864 <dc:attribute name="description" value="${facet_description}"/>
2865 <dc:attribute name="ids" value="${facet_num}-${facet_name}"/>
2866 <dc:attribute name="artifact-id" value="${aid}"/>
2867 <dc:choose>
2868 <dc:when test="dc:contains($o_name, 'bed_difference_year')">
2869 <dc:attribute name="out" value="bed_difference_year"/>
2870 </dc:when>
2871 <dc:otherwise>
2872 <dc:attribute name="out" value="bed_difference_epoch"/>
2873 </dc:otherwise>
2874 </dc:choose>
2875 </dc:element>
2876 </dc:for-each>
2877 </dc:context>
2878 </difference>
2879 </dc:for-each>
2880 </dc:context>
2881 </dc:call-macro>
2882 </dc:context>
2883 </dc:for-each>
2884 </bedheight-differences>
2687 </dc:macro> 2885 </dc:macro>
2688 2886
2689 2887
2690 <dc:if test="dc:contains($artifact-outs, 'longitudinal_section') or (dc:contains($artifact-outs, 'discharge_longitudinal_section') or (dc:contains($artifact-outs, 'w_differences')))"> 2888 <dc:if test="dc:contains($artifact-outs, 'longitudinal_section') or (dc:contains($artifact-outs, 'discharge_longitudinal_section') or (dc:contains($artifact-outs, 'w_differences')))">
2691 <dc:call-macro name="longitudinal"/> 2889 <dc:call-macro name="longitudinal"/>
2739 <dc:if test="dc:contains($artifact-outs, 'bed_longitudinal_section')"> 2937 <dc:if test="dc:contains($artifact-outs, 'bed_longitudinal_section')">
2740 <dc:call-macro name="bedquality-bed"/> 2938 <dc:call-macro name="bedquality-bed"/>
2741 <dc:call-macro name="bedquality-load"/> 2939 <dc:call-macro name="bedquality-load"/>
2742 <dc:call-macro name="bedquality-density"/> 2940 <dc:call-macro name="bedquality-density"/>
2743 <dc:call-macro name="bedquality-porosity"/> 2941 <dc:call-macro name="bedquality-porosity"/>
2942 </dc:if>
2943 <dc:if test="dc:contains($artifact-outs, 'sedimentload_ls')">
2944 <dc:call-macro name="differences"/>
2945 <dc:call-macro name="bedheight-differences"/>
2946 <dc:call-macro name="flow-velocity"/>
2947 <dc:call-macro name="sediment-load"/>
2744 </dc:if> 2948 </dc:if>
2745 </dc:context> 2949 </dc:context>
2746 </dc:call-macro> 2950 </dc:call-macro>
2747 2951
2748 </old_calculations> 2952 </old_calculations>

http://dive4elements.wald.intevation.org