WITH RECUSIVE patches 0717

Started by Tatsuo Ishiiover 17 years ago11 messages
#1Tatsuo Ishii
ishii@postgresql.org
2 attachment(s)

Hi,

Here is the lastest WITH RECURSIVE patches against CVS HEAD created by
Yoshiyuki Asaba and minor corrections by Tatsuo Ishii. (David Fetter's
psql help patches are not included. It seems his git repository has
gone).

This version implements:

- detect certain queries those are not valid acroding to the standard

I also include erroneous query examples created by Yoshiyuki (probably
will become part of regression tests).

Remaining problmes are:

1) sort query names acording to the dependency
2) planner always estimate 0 cost for recursion plans
3) add regression tests

For 1), I have proposed we limit query names to 1, in another word do
not allow mutually recursive queries. For 2) there's no good idea to
solve it, so I suggest leave it as it is now.

For 3) I will generate regression tests as soon as possible.

So the patches seem to be almost ready to commit IMO.
--
Tatsuo Ishii
SRA OSS, Inc. Japan

Attachments:

recursive_query.patch.gzapplication/octet-streamDownload
��Hrecursive_query.patch�<ks�8���_����H6%�zP����I43�u���$3�M�h	����BRv�����/�$H���{Ww��D�~��4���M����`w�v����vc��Mh@gi�]���n�q�=�s�{�����c�m�I����:K/�]��&(�mgH_���K(����tm�; �g�G����B�?�&J��h��������g�y���������t��������G���.Jf��$���^�]���[�_V4�#!<>�� ��k���`u~�H����"gd���'�FE�������������G����h���|`��I^������?���i��QX$��JZ�#�i��6�0>����UZ�J��tZ>4	j>��NO^����������
�>m�q���8N7�WhAS mZ�{/H�+?	�Z��2�.a��OR?��g�B+P�F���|�?�W~B�W�z�z��n�4"���$>�a��Ac>+���!�fL��~8���E�0���'����Ds�%�Q��'�Y^Ng^��e�lE���'o���KL������4�����J����8Zt�@e/��������� ������PZ�ClM����7��a�ZR���)��D9�
�����0��wGo'���4)7�Wo������LN'$$�� ��P~=��'�f�{T���l�P�1���}��|w]_{�<��x~����1h;b��{�;� m������[�^?[��a(�w�1�@�������cM�%:&��l������"��g�uJg���k���-/�j3���koyP�Tu�5�7���A���7�9�0.���V49�yaq:�C�k-�7�c02{C%�
�_{��}/(R ���
XvG}��3���m
��+���e�t��i�����/Hp�VK����z��� �f�v������~����9�'v����i�z�%=�&a
y�v���t���jPYb���������%$��]yqC���)�g���M���)�����b�8$c{W�r�&���y������d�\WKC-gc��
^�����Dxl=��1���p5�4��R�����b��v���v6�o�{9���?��4���du8�Y��]Z;g�K�pD�O�p����:��Vo;e[cdc�����_V^�D;h��OK7�x�'?��'�Xg=&	���5�Z�c;�����?`��Cz�]K��0��8L�Q����s�W�d[��H�KS��D?��8K=�L5�=����9�7���
�9����.�|l�"�I�0�)d��~���\e�dKXd%@{_18���iL������������Q�TR�aUKF�D�	�r���$��cw�����+�<�����g���m;�����={x�H_������}�J�P�*�v"��$���� ��
$~������%We��)�%Pq��r����T����:�c��A-�t5�S�����DW�MO$��(��oC�L?�\�,G��/�G�ey��J9���D��?Oi��g� �?Y����<Lr��J���1��������I�k|
�8���L��h�gY��>�!��W��VOK�Q�����Y�����&����V
�2�:(eG�S�Y�P���&�Y"-�� ���u,����g9C=��2n��,ej6��J�|0	�F�L�������'���!	<N�����G��sPn����#P���d�!F��l����e�g�?��cu=�������?���J�>��4�r���\GE��v�?X��ym�����#{4t{FI��@j�<�Il��[����6Y=�_�6AXx�mS�a���AL�4]�!I�5���V�������~v[����SHrZ�A�Co;�����b��9���{�o
�%�����>�239�#�3�?�~{���n����a\<	��E��!�,�2��_�c��1��n�%*��~�0�S������YIH��jgV<"]C�o6�����cd�m�k�.4!�:C��$��a�fr�1%(���L���m�/�&���D6��A��r���"�2��~��l�c�{F�(9s�M�A���e(~�F��������e@��Ia�I�f�Qd.� \}G1t��hP%�,�<r�a���6��mg�h�_�������v>f"�/���,��D��e��S�����Y��6;����^���dl�m��v���H��<�1_p9��u4fAl�r-W/q�����{��k����T���)�7�va3��#���g
��nf�n�!/�����Z��Z������9-8rw(��
������emz'�` O��?#Q���������NC�5���b<��Mx��8���?x
�����p�I�uk����JP���y����_,HzEcJ��xdQnq_�Fd	�$6�q��}��.ch{��a�h���n���zb[��(����wb�������Xs]]���][���*��{�<���L��������I`T��������Q$0�cS��LI/sQx���7O���%%x���q8	�Vy+�f>��k�:������]�rHEM�1��e!��� �g����9��40������M�$��xt/����;9X	����bC���3K$�+h#�Me�Ji��C�+ ��fQ�
��P�h
5���L:�4U5�J�r�V{�4�i��?L���:�	)��*� `���	Z��3��T�����(=��!�&����x�v�&��e�)� X1��)x���\r�	wW���� 8��s��U�2(��d���N�]B�{�h��NW�v�&_�������t�\��^c�vz�I�D)Q�D�'�S�����������N�sq�'S%�/h����c+� R<YxAF���g�;�0���Q_��3�J���sVH��s�U���7Wl��h6�����@P����S
�����y��1�A���7X����<�t-7�>{w�2b��GU����y��M�c�W(3���2�0�N�� ���gp��H�z.��$��s��U����>�{g�k�w)�~HQ'�
'�=G�2 ��t�Wh|�4�BR�b�7��k<�g��PQp�,d������	��������n`7�����R	�C*���3�O�Y�H?�UQiI�AmXRq�Q�C#S��!65&�G�tu��$�X>N0>����shf�m��g��Z�^�>�lh,/��E���*�%�!�X)�����{�X
Ne\��\�3��kp���O�+���m2�9��kC5���v��yX�D�z�]��T�l����o�������Yi��)�30�&�jIc�Y�yv�9������XGVk�dXD=��+f������`-6�>������'�&��'G�����g��N��!�Q��[��=&���^���IgA���d����V����NB����
���em������H�.��
��O��c�!�)�r�����;��������+��p��[5�!�y�^�)*/��4��5��������n%G�-2G�Y������S������x�7K���m����|Fn	{�c��xI{���;����gWUr�pcMo`�����\RP:�)F�y�q$�E?�A J1��m+��.�a��_gt����wi�����X��+1$������L���<p��k�X6f��E��9���w��������O�*�R`B�����cvHafY�T�1���T�	�^����W���+��!�����)�=���z����]�'��[,�� '�*�L�R��"�YAq��7r4�������hM�A=G'��f&z�A4�y���K ��k0j:ZV��"����/+T��{=����mD��y�
D
vn��q��������Qd	����[ny,�u���\�:z�^�4���D�&�n�6�D���,
� �KC����X��Lw�36g8��Q�2�6�L��f�k��EB��X[/�w^\��������M�co�H��#p�Y������m7��}*�z
rFJE�Y���B%4/O^�98��e(`�$En��DJ(��7�(&5���5�ji��g[�����������eS)A�c�A7Y1tj��LCu0���y�P?a�h\'S�U�'^%0S�e���~���d`��$��������R��=Y]������p8���fKs���/����D ���f�Qh�s��xl7mBy�c�~�����\��N�&��cx���?�������������e���9�����%^�>9��E��Ad/�6�%Wy\��S�vT"6��<�$��/u��	o�&������<��c�Q�*v� ��
%b~=9d4��,wd��V}kh������4��j��_yyt��l�U�[-t��''G��])=\�EB�m����V�������~��������G��Rl5Ch��P��%�bT�����UD����m��4���Z��&��},|��?����N2u|���e;)o�k��h��D?
���(��iP|Y?��a#G��B�7����&D[�,e^MI��9i0FD��I�7��dF�����-�sc���K�NW�|���_����6��W{\����O�&]�U{�F>�i(v���m���R�JgI�)7T�b�,A��K/H��}���}.�*c�ji�&,%_�B����,�jH�]�ve��|�����{�_��[�A�����l�.����Wu�������^�cd �~Q!yur<i��&�r<�
��c�r��5n�H�C�b���S,�i��E,w��F�8��!�:Z�`
���.X��.Dg�7�E��[��
��Xo��p���C��_q�G�_+
�	H��w*�	BaE!�Y*�GQ��yp�LE�>d�a�4C,���&�������ef�rJ^���i���B����L�#����<�v�-!t|�:_.��ZY%W��6�&��6��*2��,"�h��b�r�j{�/��d���:$\����o��w��O�!��N.i�~�}a��w��'+m�:?��.&�R@a)O��-���b���<���?1X������J�1�	8�/���F��P��76\�����������T���w,��I�t������6����+,s���f���o�u���iV�b-^t�m�c,��U+7���Y]	Q���x����iB���|f`h�*o��o�.�h��!X�+5`]9��4#��'-�J]��gz�d�x>-��o#�
���W��t��Kx��@��h�_�E4�a� 
-�tby8_��z�X:5��M��B@���J���~
[D�"�-�C�Z�h����������Z�>_�\���.<<����4$^�z�/&���e�W`�����WLW������t]S�%Q��/�����O�x(�~�+�#>�
���5_H��c�
�]��
l��a5g�Sk^���)R(}Tn>`<$��h`���o�����[i��}-Or-J0�s%����`j��[�~F��Ln\^Br��G��?���1SF�5A���05��%�Ju���!0�o��
���G�)���~yr+�mn�0e�I��eBW��/^�dO�r`�>d��i��+yo-�`^��Q��	��������G��
����/K��
����(7�o��Fb*W���:%����-�����9����U�FRJ���
�y�bf�?���D~��M���=�J�T��j��F��u���\}J�ed)E���;ha<��_����g�h��E,�D�G]-a�$�d#���zIAc��P������eN��B��-�������"{���
1�����.�2�}��}t���+��y�a^3��Y����2����9
�WL���V)'����'��Y$���Y��M�Wd8
���Zd
�jR���Y��gq����-�9)��><	�.1��R~[�z���%(������jb��T��"�;�ax�@^c�o��2��"BxI���/@8�:�]���HT�V��z�g�s�8q.�������#��g�W�y�X�kC��C���B�lg��rtd�M�Z�j�0/���w��V/Z��d�<�I�����������Q@����H��X�5
��=��@@�N >�h���}����
�w���n�h�X#rxs3S���9�z��}����
=Cg���!����p@��r�m���`<#&[/���R���.O
�K�W��.��C�OfY?��}kX��|���@�T[��ko�d��s3�>**�I.��"��+�7���'���2ma��F���Yt����w�=Zr2(�*�1�W�7�J����o����)4�`t����Y��F��6Pa2�oA)C�{���yp�D�-����2m'����axs�!����ne.���+<�����=}O
wv0�"[y�^Mc�� !�_���2U8��+	S�����/)[
�_} k	W\��%��
��&�����-F�<U6��rU/�C)���ER������U�Sf[�\T�{�6y?�����:<�bvQ��c��6M�M�������j�,���[���a�U�NS 4l�H`Y�0���\�����D������ ���<�QA��(���2F}���L���;X��!��PX�Z����a+�&?k	�?F�����	-��*�O��pf�#�����������^��zEZ+�w��F�p��Y�)��[Pf'5��|-�{��$�|�qk��Ek�]������I���H+�C3���|2�R4��Y���t�J����t��7c9Q��R��b��5���u�q$���Eg�$��	yz��	���j�;)���w�	f�o���H��!��f�NV�r�F�10+g�c0��3�����
���pj������9��8�O��8�u�4?�v�k�]oO�|4s���a�p�RE����_���u;�������o����s��f'��:�V$!�|��2��=�i>�F��8�����f�������q�k[������+�����=���9����G$V�F���u���g���m|������~�jC�\�������}�P�>�
X��
����e���k�u�35��.��Q��V�
��g_�]zi��51Q]�����Y��w_!�������:�@)Oa�qL�\���@mcL?��\B.0�H����
�c~�.d���d����\�1�H5zr)��*���~�2d�������=��9{��_1����M|����G�=��_���g�m���)�>�����9����Ph�jT� �t��1e�'	?Y��d�W�L�tlNH�#!T�oD�����jF�����T��M8b�T���������]���2_����Z�+�������Q���(J8������������Z��F\��D�'��LB����g�������"�pP�7�uSZkg2��=cK���x���`�u<":���N���l�Oa�
S�~5�����F�`M������.^��D5�����5��~�m��\�=.>�A������b���y�Ve�g����C�M��-�f�x9�+*��<m����k�6���k5X�5���Zo���e4]iJ�<��&�����)JJ�W6�6��6'���lQBW?��}����>�'�����[�,A��u>����T���W��������{}��N}/�4D�^�~�)8|�3��C�����n4	�O'6(��!=@�Y�z��n�8�2v�1C[1�7��I����M���"��1Xz@<��������|��4��{ T1X��p�r�
0�@�G���o�NXZ� W#����x^��D��?� �������~������������o8��t<�+d��y������e=v�^C��Ae�*�u]���3��*\$15�� �%��q�+9��k�1������sI����O��f��^$%���.H���Z;���XP������u�:�]l6�������H�6���2]���v��m�T��e��_���%�������f	B�r.Q�������>��Tv��j"��hj�.<�����
�*[�m�����������M\�L-T���y��S0��p�����-��P���|�Vz�9����l�U���[I���>9j��}������ �����b��5��~���=�k{�ZD�|�Y�a�A������<)�y�����a�"h��i���EOp�W��9~�E�mC��FWI1��O�-� �sU�B%kOVn�}4PZ��#C���=,��p8���a�#J��^�J�lNzW4P��i�$�/������\�GyiP�
�K��8��[�rvz���A(��g�$+�}}��Y��F(����^,YI�,iON�A�H�h2�I&��0mf`r��[l|�~�� O�����E���8��@8���-y�VD�D�|��o��WO4�q��������Z�c��fqO����7�f���H����3���K�AGD[wZ z��R�(BA��
�Y��,�Vk�����z0c�QNXZ�1.�A�_��;Kr��)W�J��`	�WD��E��oJ������x��$>�r�A�Z��~������d��>�)��cQ��)�%�)�!�rW�+����W����-��W�S��OL���<bM;!�m�o*����*8]��`��3c�$���)��Y����!�j$_����+6_O1�����2���l�F��\_��n��[��[��hAK4������U�������8����� �����o�Eg_}9�4�K�G�d�5���[
]��0��NP���?<)����N���N�!����o���{��Ee��==2�<+(��vQE�-�X�5�z����8M_TB�=/�_.��#�E���#_c��F��{,Gv*��K�?�����H���t��Jt���W��GK��FVtDU�W�)����Z�<T���Y��2�h<-���&�-�
3�a��1�e!y�xQs$���9�Z�fjt3��#?
n�������1�m�,eR6Xu��J
��b����kpcn�A(X���1U��d����${�s��A�z�*��������RR&Y__�~����g���>�-z�����<��s9�9R�i&��������m��H.��Z|���Gm[�zG�~��������[G�6�Q�����v����Ocj�Ff�Jn��-s##w�r�$G)(�J��G��F��W��

n�9�m���~�^}w��2���+��V�J��z��{�4'���%ft�h_*��i�
_���>N|-8��'9!�����'�Gd�Ll�L;�0��g;���v;j����������MN��4���>�)��u*�wlf6yK��������2Ke����+����w#O����m�C��Zc�6�����n��U�'(�xNFD��8��'��:�U�4�H_4A�j����W	�����������L,�^2����v|�m�C���U�4,3���ZK~��x��i;q�I���������)$����o�y��^Ds�^P��O]���x�z�	jg4��	$���������I�ZB�U[@Y1�a}]��%U�����A��	��B�����G�����ru�:O��`"~D$�u���������`��xft)��[Jnz���V��W�U9�("���9�A�������8�,]�����P
�R��S�����D=	d���.�u�G����j�0���k3�K����b��%n�s��8�;&h-��s�DbrZd	���IX�`��.��,�L��&��eF�w���S;[�w�S�@�L��$NU��WO� ,�|]�z�����/U���W�����xv�w�[�B)�����S�.j`[^
��1U��7���ln���:�����������G�t-��O{3�������~{�����N�.b]<XJ��*��t����d�	��������p��8�3z�&R��1A"):<�t�,�?@����e��4��<�_�:���0�F��_o���wI��I�
�Z`.	NH��,d������������>�����9�&Qrk��\��"���|[\�U����U�.�0+u���M�`��>����o�g�u�Q9d��u����tr���UJ|.Mx�Fi����{�����\��Z��9��R��5W9-��\uD�Q;L;�$����yaH=<����$Lq�����z\p�O��V��
�\/b�d`xX6�8EF��j,>jZ�?��1S���8B��PQ��S�[�)�����7��P>Zj47}�b{�z�g������ Bk��}�9b��Q���9�b	�6������t�phR��s�u�b3�L��i�\�>P8�*oiprf�<��G���`C�#S����]����
�{�@��i�[O$k���e�Z��%����vEz������K"�Fl��������E9��^��h�lB`���B��2�Q?o�C��*5A����]�<B���i��Rof��eV���I��0Iv��F�����f�-,J����e��`4n^�[^��h��hEQ�3c��&��.�)#�}H;��v������4�iDr�^P����0����!)g��|:�H�+U��%i> Z�La�z����a�{��S��,��LJ�T+��.������w����.��#E{_���:�W +6��`R?��
���|�Q^�b �
��`J��?����C=L5���L�WY��������T�tm1����99��R��R;�_����Q���(�;[!{��_������w#u����{86g���j���77�;�M�����|��-��`�J3?0���0\Nu�&��"��������=��o<�a+��	�����C��������pG���J��*e��M���/��j�����]������/���w�]E!4�����t��
������O��QdB{:�_��y���d�+/���a��RN����!����H�K)	��r@\NBW�W�\�D,-�����U*��9�RM{sq��i����&��rk��7����-�&��VjM���#�2l�
p�Q�����[�\{���������)����7/�'��+9�zjg�&Q�8��`Jz����W��Kx�e������������|�_% ��iP���@���F��h������nz+u{��n�[��@�0������Hm_�u^'w ������������1���hK0�!|�����8�q����z@*V��O,R�J\r	�L�C�D������0�'�a
�j����1��LU6�N0>��9�R&
����1����~R���qK���$X����I��e��T�?�4��L���rm�U��u�JV��6�[9!�z 4�Ub����%�������/��Q����d8�IU����C��W��������1�_�f^���jPo
����������K��Ui
�w@{�=A QW'+�O�R���{�����v/����.���+� �I�G���xt�p�~ ���!��.���$�ox�����!���.Db��x	t��24y4��-)�I�@5j���b)p�������L-�1T���\^{���u����7����Q�������X����;���@>O�rU�pF~s��O�����>/�W�����?/�����q���E��������J�amg''�b�����P��IWw���]��qu	���>����^}Gg�����(8_�Ui���(t���^��?j�e������[���������>R��FU"��<�b�1��p��gc�
�Y���8���U0'e�%��~�+���A������#����������JY�
Z�$����_��E����� �$=�(4���*������Q��M��&�m��F�*[��.T����l����Sz�(�M=���
��.^��u@z�+��L������������[�/�g�f�;t��niu��A�������+��$�rF'�E����������G5���������wW������^M{��~����s������Q���ZL����v
hy[������Y��me��2xzy���d��Z�|�Q�3Z~�7t�����~Rf�����[�?���������f����*sr(�Y�(VG=I���
��=e���c��@�&�r2wb]n}��[5lcQ��N0��f�Z����(.��S��awSXi���"�5
�����@��-�{-PJ'�#R ��e����D�V-�"V�WvS>�/��T���t�u=��i_~-���u���/�ZX`z��l�+��.��M��������A�oJni��g�@� 5���4[�"�����d����*�l<a��I�?l�4��b��a�L=�
����?��X�!��tj ����'z�;�����Pr#��~�����{yBZ�|cG_��n�����W������;�Q]�LZ��G{����Qm�F�*pkd��t<n��!�`���\����E��)�������Ui�V�����ZO���Ro���H=�U�h}6	J�8�;�D3�hL��x��e��(Rg�A>�����%�S��q�iuj)��b l��&���|<;$+E ��[Y��o3����������]m�v��EY�M@qr�������c�A�L����"jn~h�fm�IYm��uJ06x6k�C�2v����^���R�#�vF0"9}ya���}q?��;�_��>�@����{���Ayu�z��^jm� �/�w3�����p�::;����}��@j_
l!8Co&\�u�z{����w�����uO�I�WP��.��7<Zq�&������FGK�I{����*��bt�,\�C��]��E���0j��.<����Y�#��jS��������M�a(���H��
��XT�<?�� P(oh�� �������m���X��RX5��L�
Y��r��k�����F+����_�T��s���s��oy�����?��S����$��{�2&:�\���h��|�h���F�8��Bm}������%\YZ������
����B�v�����H6��=�vS���)I�xlr�BS�_X����|,y�������k���W9;?3~���!S�AJ8m�X����f�p����	����0�Hh ����5���3��S,=j�F���������w��v4@�y�)=z�����j��/�Do�Gm��.���$�Gb$ �#r�`N�!�*���f��������U���TJ�>}(m���A����'m��<�z��������F��x���~��u����L"���./������4�w����������K\HG��VM2+;O0�s�66�h���B��R=z?��uGm?�aA����fwu���={C������-�}�5�����#q��)1S�r�7��@��}���xt:
�FO����6��s��/���v�m�}�-%6u�D�:�m;]6}[�Of�_�
�9�	.��o��G�/������� ������y�1H���!`\���{Z���W�]=IG�I�&������<��k�N���0;�#jS��h����|VY+�f�@I���uCQodD.�����Z�T���n����_���9~V|������^�iU�/�K������TV�8�(p�����Y�<�X��aL
N �"0�l�=j9�O6��V�FU�(5:�`��N�a�c��~qR�
���wL.s)Nz�{�����U��RP��^���,���K�pk#������2��e��'dl,����Lo'�XJ��U�����0��Qu�?DsV�+S�.�F���7��������h\t`�
���w�D�1=�z�m�HS��^����M;�(�����y����e3����7�q�kq����h��6ity5q�p��82xxo�Q��{73 X���4��(���}�"�\l3�:Vm���-_Ik3����U#��P�C�u
+�����k[>M�Z���|BP��s��>��f��� ���y�@_�����
C�M��]����TO��m^1qv ����\���I��������$� ��6��B�G����QB���Q�a�c��>��L<=in9[����.��gpB��GDM,T(o\�w��.�.2.���mM�6~M4$��������LE�^h_�����v�?Gcy��	hmV���1N�Q���U9���glY�:k�z�S*C���8�)F9���;#g�W��7Ar��/�	|H,��~�)�S���$;��=�aJY���c��f����r��j��5�2���������B5�2���cj����L-�����d���i���&�x��I���J/Z������U]�\��^]�[2o^�]@k!��G��^�m��cG3����V:G(��?�#�8���fd��S�4+UYE��[�[(H�y>����*[��@��p^�F�����A�4Hn%n2[�T�<�vD���AwsKM��Z����w�|����S8Q�����o2N�pr��J��K"a�8O�I�ux�~L�����%L�OT�'���	lO��`�q9����d��#���� �}yF��3�?{��g�C�V���X����4��bj���o		$j�����lT��O���4R��;���������*�r�K�s���x0=�ABe�����Z����T�^�#h�0�0KK���-�5��U .ny�%�$[������S����s��^?i_���V�3�1���W�����������O��';�9c��@�y*������NO �aG���]V�)f�����!�+X���R�����\���s����D��0�|[&��K�V���c-���:�������$\�C���dJ{7	�� Y���$vN�M-!�$Rg������r�K����Wk ��`a�;9L�W������a4�	�K[�Pp�m���|���bX�w�e�90"��t�N�wZ�A��'��C"���4�3�m�7��}\�W@CZO`�F�3�im��w��n	K����;��)
��<J3�P._;�]YO,5�:h�\�A_Bi"3�f0ph}�������\���o����1�7�z�g�O��c�U�N0�Q3�6a�9���9=�@J���pR��l�N�����"���&@r�����x��5�v}�	4HI��b���h���z� `��|�\a�(����t�j��?B���h�^&�(��������4:��1�)>~�;:;y��i�:[Y���
1A���/g��I��/�v�8�L9-n�e��h�&6�2�d��I�n$��
����c�i���3�zm��|1��.�������

��&�����Y����I�f�S���Dx�u�iM����_�����t=�N������c���<���v�F�[���"�jD�E�	���*�����j-b����Yb@��������2��S� 7�������|��la�E����RD��	j��	
Y
MF����>���$H� � ��l�i�-�!�Mb�F.Qv8��w}
�n��9y)C54p5���
���k��B|JZ`D�B7����� ;J`<]M�#����
u�F�TU������{�j6^�(-A4�	�x)pZh�-D�d�L{H��qv��eKR'Z���!��j��%N���;���<�D+j�s��=�J+�n�-��Svg��e����G�jn`���zDj77k�P��	�)~��u��Tny�)m�����G�9Q�
�����$���-�);0by�@X�B��^��5�%ie={�9^�T�!��Y*D�,*|$}<���������/Q35����Mq�j�S���)Ou�S��o�8�\���V�#���JPm��%��Y����+��M:�[�1e	ir:��f�+��J���p!����iwC���^2{z�#����lfZ$��#�yf����-���#!�tYy���>Y�d2Gp������^	�k%�@6F�I�f$o��Jgf�����lt`E�I=G�������\ �=��x�W!�{�Ym�L�p4cC�g��P�i��F~~����F��z�x��C9�:��G�{����``C0%���P�CW5����G���L�4�B�5Xj�d���������#��Q����F$U����n��N�������R��Z��G�Q�d�0��}���h�K� g/���e<���_�*��~m�46K�]O���4���.�s���
�*{J>��
���_;(���qu���^������+GJLA�HH����8�D�>J�m�N�-�w��������$� �m�EF���(B��M�^.�-�2v]4bEu�8��Q�}����"��v�	��]����P'�q���a/��#tgG��X�:F�E�o��T����$���M��V��Z��J�E*���t����,�z�����	�-xp3�Z�)5�
1�5���;��1B���
�����e��@��{<�(����O+����0oT���i��B�$@>+�\��2���/1����B���c2~o��5q����}�����U�����x�c*�j#�zF���G�����0�-=�{����<�H��Q��G�����
x+��|��K0��8��p�V��!����Tf���\v�kW/d����z���Tj��V��t��f.�\���E������j��ow"TaDEO��y�����o��i>�3n��h���j��#�O�T�x��f]�u���4=>����ds�LS��
�����|���z��P]wK����rs��L�<��(�yp�5;��[��	�0.��s���]�Q��ewmm��|~�sm�hZ�e���V��1���+���;%�F��.O�[��E���7�Z	�h �R�M,�7�8=����y�;*���C����}7G�{�nF�r����4:^6���hU�`����M�|!C�p^���J��%��8'��mN��U��U�}��
tK�i�i�7vO��%w��1���.4��[>����
,z�~�x`,���*A���	��92�#���D��&�D�q������������������<"��`9}z��{x~�=}��.�nf�B�in8��6v���L��,��zP���B�&����f_�YO���1�;�Q��x��u��xA�y�.�j��������%����d~}���X���������������Q]h�s��?H��!��wW Qq�$*Wf��wO�x'�'�y�CO�����0H�y��9�aSS@�m�2���:C��8Ot:0��1��x�I�0�
��$~c�|��{A�Sq��nw���C���t	�	@�R��c8�`�0&��0F�
����p�
n��Qr��b�@��9�gy���v�z�iA�����4K�G?[��rkG���~�|������e��;xP�E��[c�x�����UZ��e�+��D2O��a�+�K�I�,����Y`A��
	�dL��^��k��hf7������K���6#N�����M�)�]�`M��XY���4�]J�6Jf����f�q�����6������$��b��h���l����O�G1AX����d��Atd�Nu� G���NK�?C�����Icl�V	����,i������h2�3����dz0��� �b�T�����E'���wjUUi�7j����N����{{AS�?���Q�z&�'#�K���]!�@*c�.�C�������M���T��6F|������������\?���G�i5�?l��vC����W �Wtm����`AP�c��
����9�%���X^��=���V�V�N%�4�I�*'K^O�y�&��l��f�5;�z��=*�\�=��E1�H�t	>t�]dr�>w�0kz�t<�0��W�q�,��*�r+�m�W�z]l����
��o�*� �E3f�=�|]
��_����5����cu��]��'���P����Ig�J�����AU�����zG�����D����f�v,_Ja�2�'����.0���b(6� ����-'�R�`��/��\�3Zo��zK��-X6mg��1�6<'|��_;		�A/�/]�roq�s\���>0Wx�%~��)g�i>�YO�#4����S��������fQ.X��{���@]8<B<b��o��#V5�RG_t��.^�wR_J9���������0Ss!�m8�@���U
QS�����|����3
0��p��`�&E��n�rP�1���/�0��c�Q	�M��B=���%���K&�8B������ 
sa5W���{���������y������QlNWk���I���PV�� �kww���	�N��L�_��6�"��`������F X��VY�+H
������{}~��	���nai�>�{X�I�M����7(�9��"���)������{�P���A��!L���o��_B���j;/��"W���#�H<�
U�hZH��oON^�3���}~F?������75��� ����I���+�|����DXL���lW��pw�1�D���D������W�R�e�����r~�s(����N�=�:��{���OZb%w�P��H�{�3G��0Bg�W9[	�{R����O��g���NE�wQ�4����_������������V��N�{t��A�A�a�a�^�8w�&sv���%�����9`�.o_��K#�|w��y
pA3��#�Ok>����x�������c���!����M���j���*'���������-�gh�Bfa{<���Sm����^u�V}/���1�l�C�������	��.S�<q�f�	J'�o�?`�\J�L'�t��oNT�R2��:C;�p�}34�
��Q�Z�.�!E;�@��V�7��*���������eS�`#�Ha�r��\K����*�_�-�W�\������`$�@R�Go���6�K�6B��������-��%�Ye``��8���Z~�/��f.�z�}�M��&�gV�9�\X���:8&�?����0L����5j�)8�c���~4�:u�>e�
�"��
��)�W�{��|���6��7
�=?��Z�5g����J��P�*g��
\�����c*{�����G6P��i%�y�4��5���p�Z��y�g�}�:��	�i��������YV�����_N�Z�Z�r�����q5��f���Y���UY��j�V��:�s]D��W�.��hZT���^�(�`�Vin^���L��]d3�����t(H_��c��"I���&]9�[�������NR���������ue	������n����f�E��<F�����f�E�qB%w�<�����ZA�RY'��,V?����2���?���^�:%/�v���\�}�����C�!N���
���8}�'6K��������MC�9r]������0,��D��f�4&�����n���mRT��a'���(���\J�����tak�6�|�!�j��0�M��QkCSP�g�2���'h�k<t;q�}�����T�. J�F1���P%�+z�
�V�����}5�-4?�C��tg�t���Y����v�.�'�rW�oa�:���0V���>�5�[��b+oc4a'�������+��"��U
���.Ng�H-D7A�0>v�|x��������=�*����\D������q��F��n��$,��i�$�9~1q>Oj�p�!�j�
h������P�'6 �bdb�gJ��o?��C��d���D����;�Gi������^�]A��R`N{��,��������>��@����th�n��	;����@ZWp�n�����
��&��1�m���;���ss@���?����)\"�g+������9s��,�,����>��`dS��/Ms
P�����t�4/}7�#�N�Pc�(���-����S2���/Yvr�!9/�����u���|�><���r�k.�F�4Z6C)v�/o��0#)����)��tg���ls&��H�_��.|b=��������7'x�����?��)Y���:�����#�r���U��
_���{��������vvr��!���=���RJUv��.
+w�F^������S�:7I
error.sqltext/plain; charset=iso-2022-jpDownload
#2David Fetter
david@fetter.org
In reply to: Tatsuo Ishii (#1)
Re: [PATCHES] WITH RECUSIVE patches 0717

On Thu, Jul 17, 2008 at 06:40:25PM +0900, Tatsuo Ishii wrote:

Hi,

Here is the lastest WITH RECURSIVE patches against CVS HEAD created by
Yoshiyuki Asaba and minor corrections by Tatsuo Ishii.

I tried this patch vs. CVS HEAD used my usual configure option with
only --with-prefix set, then tried to make, and got:

make[3]: *** No rule to make target `parse_cte.o', needed by `objfiles.txt'. Stop.
make[3]: Leaving directory `/home/shackle/pgsql/src/backend/parser'
make[2]: *** [parser-recursive] Error 2
make[2]: Leaving directory `/home/shackle/pgsql/src/backend'
make[1]: *** [all] Error 2
make[1]: Leaving directory `/home/shackle/pgsql/src'
make: *** [all] Error 2

Is there something missing?

(David Fetter's psql help patches are not included. It seems his git
repository has gone).

I apologize for that. I rearranged it last night because the name was
not scalable, but delayed sending this out until today. It can now be
found at

<http://git.postgresql.org/?p=~davidfetter/with_recursive/.git;a=summary&gt;

To pull from the new location, in your .git/config, change URL from something
like the following:

url = git://davidfetter@git.postgresql.org/git/~davidfetter/postgresql/.git

to

url = git://davidfetter@git.postgresql.org/git/~davidfetter/with_recursive/.git

This version implements:

- detect certain queries those are not valid acroding to the standard

Great :)

I also include erroneous query examples created by Yoshiyuki (probably
will become part of regression tests).

Remaining problmes are:

1) sort query names acording to the dependency

This can be done at query time already using arrays per Asaba-san's
suggestion. I'll add some examples to the documentation.

2) planner always estimate 0 cost for recursion plans
3) add regression tests

For 1), I have proposed we limit query names to 1, in another word do
not allow mutually recursive queries. For 2) there's no good idea to
solve it, so I suggest leave it as it is now.

For 3) I will generate regression tests as soon as possible.

So the patches seem to be almost ready to commit IMO.

Wonderful!

Cheers,
David.
--
David Fetter <david@fetter.org> http://fetter.org/
Phone: +1 415 235 3778 AIM: dfetter666 Yahoo!: dfetter
Skype: davidfetter XMPP: david.fetter@gmail.com

Remember to vote!
Consider donating to Postgres: http://www.postgresql.org/about/donate

#3Tatsuo Ishii
ishii@postgresql.org
In reply to: David Fetter (#2)
1 attachment(s)
Re: [PATCHES] WITH RECUSIVE patches 0717

Here is the lastest WITH RECURSIVE patches against CVS HEAD created by
Yoshiyuki Asaba and minor corrections by Tatsuo Ishii.

I tried this patch vs. CVS HEAD used my usual configure option with
only --with-prefix set, then tried to make, and got:

make[3]: *** No rule to make target `parse_cte.o', needed by `objfiles.txt'. Stop.
make[3]: Leaving directory `/home/shackle/pgsql/src/backend/parser'
make[2]: *** [parser-recursive] Error 2
make[2]: Leaving directory `/home/shackle/pgsql/src/backend'
make[1]: *** [all] Error 2
make[1]: Leaving directory `/home/shackle/pgsql/src'
make: *** [all] Error 2

Is there something missing?

Oops. I forgot to include patches against newly added files. Please
try included patches.

(David Fetter's psql help patches are not included. It seems his git
repository has gone).

I apologize for that. I rearranged it last night because the name was
not scalable, but delayed sending this out until today. It can now be
found at

<http://git.postgresql.org/?p=~davidfetter/with_recursive/.git;a=summary&gt;

To pull from the new location, in your .git/config, change URL from something
like the following:

url = git://davidfetter@git.postgresql.org/git/~davidfetter/postgresql/.git

to

url = git://davidfetter@git.postgresql.org/git/~davidfetter/with_recursive/.git

Let me try later.

This version implements:

- detect certain queries those are not valid acroding to the standard

Great :)

I also include erroneous query examples created by Yoshiyuki (probably
will become part of regression tests).

Remaining problmes are:

1) sort query names acording to the dependency

This can be done at query time already using arrays per Asaba-san's
suggestion. I'll add some examples to the documentation.

1) refers to mutually recursive queres.

Show quoted text

2) planner always estimate 0 cost for recursion plans
3) add regression tests

For 1), I have proposed we limit query names to 1, in another word do
not allow mutually recursive queries. For 2) there's no good idea to
solve it, so I suggest leave it as it is now.

For 3) I will generate regression tests as soon as possible.

So the patches seem to be almost ready to commit IMO.

Wonderful!

Cheers,
David.
--
David Fetter <david@fetter.org> http://fetter.org/
Phone: +1 415 235 3778 AIM: dfetter666 Yahoo!: dfetter
Skype: davidfetter XMPP: david.fetter@gmail.com

Remember to vote!
Consider donating to Postgres: http://www.postgresql.org/about/donate

Attachments:

recursive_query.patch.gzapplication/octet-streamDownload
���Hrecursive_query.patch�=ks�8���_�xw3�M����3q��Qf���Y���V6��%HbB��r����n��!���\���X
���O����&�)�-�G�]���<���d�����:^o4��Z�Ys����w{��n��>d��o46k��@U_x�hF������|��~��C�m��4N�C�%���]�j����b7a�`>������>��!�_�B>����_�:��=�7��U@�(�{���boNo����
	���]��rK�Q,�aA����������$��ly�ga�!�����������
���G����dptI>pl�&��/.�Oy�P�
?���)c~f�(�J��#�a��
���gxAneZ�L�d�'>t�s���@^����
�$��C?����},�U�m��u���B�4�;Jf���������YHoPbwq4���%~8=���V�
1��������g�~����,���G��,%a>��eV�u��cv��Tb|���C��(Z���V1�
�!*�Uy	*��g1����i�"m�������%?�Sa��g���v3�����&�����&T�������o5���-�E�����$��v��:��k#Us��y�8O��Z�)lR	-��zx�n�n�`�V#6{�W����ep> !��tlf��W��E����Z[��mm��f\y��4������lTB��a}$-G��vH���6���5��ZH�n�����n��
.zj{ol�<`���p����y��yI�D���|S�3�R�:��e�zp�����-��#��'soq�T���[��Ns���Z��:-�����K�.F^�N�!x���^S��p��T!)Y������v��K�����^?]r��pz���������:��4L��O���0�Z��|[��+��OH�R��]% �a�v���?&�Q���_�^8��W� L�o��$A�'6�
T���VG(���s�J�o�f^��&\����gxow�2F�����D!h�X3���+A\�p�5�����r0���j�V���@
Z�v������~�Hb�?��$��$v���ol�\�j���e�lL'�2H�-���o������tg��k9��Fn�\����#�^/�Q��an�����5>m�0Cd����TPj����
,�z���X����������]��i�]�m��? ��CZ�]U��p��8f�|����r�B����qqb .������E��d�n���'Dg~[`x�|+@�0c'sl ��J��;L��T|k���G"��wv�.^�%%��v��8�4kC��OajL�3����|����NN���v� �*���)Rc������G���x��SO���(�}�}�?�i��'n���o��h��p����{:����S�zd\��p��"�_��@�����_��_<6�#��O�������S�4�R	���g&�S�� �R��9e����'y+���&g
�E+�w������\�('��W�~���"��BH���a�������a�#
Z��~=B-�5��
��_�O��<&m5��)��/����_����7�a.����*�w�*���2����/~8
�`Y�������Vi�Y���v��R�YJ
��A�h�Q�� 
�u�u���wt[��3]� �z�]�J%u�����`6�(��T��A�'��G x������(��A��UC"�N�}r4�����J���uYE�l�{�=�4V��r��bz����o#VJ�G"����+���Q�z�]��KQ���N�a��-��!'�;P-����po���Lm�n�=��m��&0�6�&T�P.:��2I/i�:����+���n6�vZ�x�u�3$���k���q4B�i[��c���vg�� ��|w+�oC���.!���}����j�m�������|nt�+����u��Nk�|1wc������O4x����xVM$7�re�M��2
^����<�m�(�����lXM0�n�������L\���EJ)��#�����M�	n(�����bC�l���3A���0��p	"�^��4��gdYNs��a211�E��#��GBn|�I�\T�L2]��[z��D��(z]���)#YjM��("_�\�G�;�N�Q�,�v�������"�m3q�GX>���)���b�8�5[�U��Z�l��\g��6���������e��5�-���Q9�X�h�	�.���ku��"�v��v:�{�UkH���Y����s�	�����`���3\-���Fs0����NO�V��-���^m�������=�o.p����^-�+�;9
�Y#h������ �PT�>Q��kb��m<��F��;U{����X�(���N����E���NO
��s��HB���$3S�3��-D�%ti���:��8���|f���Ee��;J����U&*KO� }������?�R���t[�����N��0Nb���u/����3)�0�UpW��x��!��aF#��}�?J�Xb�(�N���U��<,x(�YP��?��� \[�UUf>V�
��<�p��,��V���E�0�U\������L^����E�U^�[GO����kI�=jr��^�L�bCj�A�SI$�����R-�p�2�)	���^r�����^;X�:\
�U�.�Z;�ux�r)��x.auX	)�.7 `��<����\��[��<��$L�0��l���Z
FjMq��(
�A�cF_�L!��^�f���� 8�;�x}T�� �w���*��/B�zh��J�8�M4��������k?	X�c�c��������1�O��R=0����
��^���r�P��8��|Dh#�������0B���=��c�^����u=�c��D_����^<E ��D��<`� �B�A���������;K�w]� ���$�)t��o��.v�����a�����S$<�
7�`��o����C��]|�Q�K��������c���,PC/%���bk(�4��t@���I���q����h�<����D}'��o���&�&,���SQIG�Bo<\k�KgH�q_}�Q��d�Js�ix����\C��K��r�3��n�r��sB���}3[���T��JkP*V�%m��0��2����icpz�1�nR�'���O��y�A��a�G��VU���b����Z3�p���4�4����<D�L��5����G9�;�?4�K�����3D#��Z��C����A��l&�����Q��(��hq�m�������5$�,����'�� ����^� Z���!?;t�6�8#���
1?���#��(}/���y�jpzy��������T-������?.�wE��&pbL&
���B+�S�C�/�t+�i�������<�C=��H
������@���a�����gQ�D|m�iOe*J@�:��^�D����*5*�,<K�����:.�*8H
��c���RG�|AD�/
�l��`���, ���$�/U_hi�/�Rl���������%�����n���P
Bd�R\-"z�3�'�a3e(��?����Sr�&����-�F*�����QJ�'�B�

UL������q��k4�d��\�������ve����������A�N���8�(V�x.<o�0��L��>~��#rg�w�X������q�P�f��y4�`��i��3�N��=�E&E��O����\����>�\>��g@�c�^N��3��I��a.��� IU�������q���*9i6�9Jg��c�hU�L\V����z�Q���@�h(Sr��3�����o�%Ga�r;�`��r�\���5A��L�BG������B;�{^�����7S�U4���K�	58[��kI#.���(��3�2k���P,!�>�����b��S?������,]Y�4���J�]�
�p�}$��
�k�����(L��1��{m��^F>-�)�U�4���Ty�R1l����������}F�O���P1n��cE�Q�"��n��c������6�X�����8!#�+�qx.�Uwp��� �����E�4�Ec���/T�^Su|���� ��4�k_�K����i>�C���MRE���}�D�q-6��o�q�X�M��X�����#z���,-%��C�qr} �������0�Y����E�A����b��b�%��$c�3��"� ����G��'�?���W�����7)�O�/y�)�0����l�Q<��-Q��iX�8X���Be��Qt�`�d������������lvc���|3�*�#a����-0�������������c��3��d�����r��f���V*��AFY'�\�d�Y�3��\�0��e8���5=����"��&"�	�0[�:�3f��<�SF�9?��+���iM���F4~�h���$��	[��w����GNS��=y�l���B����C�H��p:8+�\%\�Oi�P"O����f�
��U*�����l��[�_�������]�/���o������������|T��txzqrvyA�Y��5�"�kN
}o9v��2�P���z��������G����lH�JcC���8�_JY��:=�cc��<���C�F����
I�������������i�'E
��
)8ZRB���;�S)C��*g�R������z����9�O�Vo�YQ�:V3Ny�������OTv88��h���|����<W���~2�s�s.��=�)e��B��M���<���D�9����#{���?�������$�Js�d"��$�J+�(J>������������N�9�������A{+�|f�"�i���q��PP��v��x��'���0��vYvA�06�,�Z���G �O�lb]�1g1|��KXdk�Xl�'�ij�������y���p����I� ��*�Q�����z|Ym��#���Z�s����2^��C.�����P��7D�x�c��������4��W�`�����0L����i�xB�x��:������1�0���
��Q|�cE~���Ab��L��nvA
o��w�1�>���/h�up���V�tN�D��F���e�j�a�/>\^���P�B��HD����.Y�����)�X�Wf=�&���-����;6�}>����Q������A~y����c�+��7@2�*��+Y] N�����O��"���'z�qm�Eg�|\P�*�L���g�]RzChY5,�m�hx{Sj9r
��2���
�a(�)}���k�('������M��]��s���t�u3�u/b����� ��,t�d�/�_�fW����
��FW��k�[s�9���q���A6��qQy�5G�?$��]����9�=}�TY"O�-�G��%J\>u���m��I�N�����f�RF�K�Nq�Nv�>���y��9B.g�����U�wL�	�`��0�],��9Q�f:�<���R���.�V�Z�nSG���,����3�K�e,��$13�Hk[=eN2o�7��I�;;Q<#w%33%�2rxkN����G���u���O�[�h/_&gJ
61�!���O��~u�������]��{�}�crCG���^��f�U��+f��4�9L�R����L��n�N�r?����~����qz8u���o���^���79�+����x�p	�s���������������|3��<%�;�7�e8bf�����m5���;f7W��)��zz�=��4��
]�:�o�]'��C�~��x�(�B�
k�r�o	�������<E^t6��t���%l��1��:d�o	3
7�+QT^���q��r��Qb:��
�1&43�����O�^
���'�*f�����7%Q�om�<�
�+Oy��f�_��qA{��l���(����x��/o�o�����|�(���By�����������'X�Y2Q�)�5�V��������8�~{��y�'�#�����K���K�*�m�g�����5d�W?
I�P���\��i��9���hi��8<��LP�=~������s��!3<��<�J����j��QO)�@:<��:7�|<��'�ZF���(�I��~�EB�:����	���W�`��#3`�\��=��������m�[��8��?�_�f������!X�y��p��w�!
���hG#��������K�L�.@��=�� i���/��u�z��?<�vRm����Iz����vJE���.�����������- �[����O��������C����X��s/��3��IZn5����,�Q�]��j5w*G�\�e������)�~
cdbr��o��No!��od�k��6Q�-/���Gtr}-�����!K�X��3M�9i��t4��#7a�{{�M��VK�j ��L�%9�R{A�09��QU�tDe*D*�t�0�eH�WN��9�q9�����4r��2O�^��=����d/g9	���t6��l(a������Xz�et�g.*7��R+���p�D�����������I`g�����s$��<���?�%�rY��2'Yp�b�x����*U���Lx�����01��ay�Csp��t��3�C��1)���4�p(c��!��[�V��*��hUKA��`�Ff�<G���szd���L���Y{�xn��$����D���<�L.���f��u�i��L3������@���y����8/�i5������RjT�������Z�J��bdZ���G��49Q�V���������L�@����U�Z����h�PE��>
�XY���X/�������B���N;�u�o��d� lI>+�s9���hJ|w���3wL�����6�76���6>O�v��t�P��:��f:��'��4����*����Yj-D���}r�	s�	j,�_�w���-;����''G�c;w�`��;�|���������+�����(qo�FE����=?2������d�6����6�S�t�/?�5�Ll������5��9'k�V�t�����������7nW��IV��,^��3
PjU2R�Q���z���������2u�{�0�|�:�l�Bv�>����4xOD�gl�4GAd������y/�P�R��
��P.��KX�
���F��-]�U��O{��_p�:����\�/y�����\0'@�0�3����i�+�ZP�8E��0|)c�����UH���2^M��;���-.���\�W
�����^��O���k,+�u���#���.eL��Fl�K
��'���F�b���6K�n��2~YLw��T13�QL��O�PO�R1�NA��u4I$*�#�w$�����>-.6�*+�u/.���E�W��z3h��A�'O,�guq5����Al�	M;��D���������Y��8���G'�D]	m	v�^e�`"�W{�uc�"�"N��P��$�G�V�z�$����'�;����8��J���-8<�y�7Zw(We6��P���w��E�| ��$���0��js0��
���V��d��y�%�o����t�c�
�.n�1�=H�;
!�0Q	��B7Lta��,�d=���X���yO���s�S*�[�^�.��E���.�Ry�2OFyO
������&����S�oo<pr�@��A��f�Q��V9�P���y�|;w0��R��R��/���xj��iM����v����+�0��H$��u�n��_{n�����U���������xo��F������x�h3"g�T�+��%|�Z
�O+�98M'=����0�`��r�B8i�lE���Ga���<r�p�	���g	{'��[*�(�(�$���zC���
�J�73�]#O��C]s�Sv'�^�����Gp����OWa8�$��Y��$�
�������N�mxG1�	���B��}��9h��<<�NA��q�0��	�!��!r:��kHFE����q=[�P�����5���jF�����
�r�'>��`)�@�Q��m&��,�zO�q12�z8�E5j��� \�)����7��L�=^��H!�/Jp�h��Rl�3�>�=G����g�&�+��(�J����S�s������D�hTp�������'��ns�c�`3.`2
g����E�lO/����P7������>�t'�8o����J��{�N�9���&�''�P���G�O��j��S���s�h4�?�A��`�����y�cP
���x�r��1�c"7S:g�Ysa�����1�(���E8���c�e)�����]IO���}��a�DS�R����/t?U�����iu��
G����
%-*����������[�J8����7�C��#-������K�d
`l���S�����P[My���3v���$��97�B��F�W8����YXxI��� t���K�P��^��<��5�1�UB������#J�Z��h
�w�_?�������@@K1���N�OHaL��q�x0�G���9����Szl���<\�D�@�nn��F���x�B(>PjH��-N�d���}(w��za������kHA�R��F��D�E����I]I��)�zi�T�r	{q�b{{����E+����L���*���@Zekp�H-G%,R7C(��O�O���7 *�N��!,!�h�L�K�c��(m�0�� ��MD=�J��8���Y�O�r�iC�������jv�Y�����+FE�8I
�!B"��9-�N:��G����t_t�K��*��'X�C��b<��"�h����j����4���|����tP�A3J��Q���e����p��"L�:�VJj����v��S+jm8cK&*��Ys�0�9��{%��h�n�N,�����q��L��d��5����$���(d�+{�>WD�����������������d-!�E9�$yao�@�Y2��`g��O���\�����P�|�&f���$�s���=e�����c�������{����f��[=����� 5�|�V6�.N�^���B�~v��������"�Z��y���P�L��������/��!�4*�:����ME�>��#����������B������"�
�P<���p���z#0@<0������PD��!�j�H���D�;g��6U�7*�Zi���6�[w5�c�A���L
]�� ��S=<�}��<l�T��h���:�_j�	��fwc�0��D_G���Hq�� L`?T|?��S���i��H0����o��j;]�V:
�9����_\��cH����%GD�	���j�;�R����'@�%���lj��P��3p���c8�����|X����re=�/tR�����/���1��3NfcI�F*�vo�H�[�n�d���������=,��m4g/�����;�_��k��;���������v�n��,PB��p�e�{9U|�^�.����~����������vjM?-�b�!j.��� a"��G(V��G���UP�t��J�fZ���.>����z�4��h��7�����}�@�>b�
H������p�-?w�E�	N�`��:G%J=6�u��;1���
(5��`�R��1�Y��w�����=SA[���Q�~�5�b���P)U��:-�P�W]���\:����cPQ�)��#�s����U��$`�g��![���p��qz��zg�qV~M��6������^y�����R�>C-�V������o��������
=xT�`��)m��N��zIBO����p���[*6	�f�S����;���rK�L�f��P���)b�P0hqu7��|���H��ta�^����8~^8�����F����=G��3^��j�������r��7^$#�}3��l������<��qZ����f�nJkmMf8�di?���%��z���$����p`��i`z�h	�e��M�W�{�@�_798!��T��]�����*�i@a�k<�5��o��\�]U��+�Ugm�A�%z�=�uN4A������}"tj� 
��&?q���k�6����JEbb���m�����*��+L�:�X�������"*E_��[��m��37��������z�7�|s�Kn���m.�����	����iu�R��n��[�>��5{u��v��k,�.p���?��V�Tz��P��s���:����7��6��-c{-���}C���0\�d�Y6RZ>&QO�d6��={9������YW
U���[(|9"X FCr��7',%W���b����S=�E�m�FUf���s�����\�9���zRi�
�0��f�F��j�W�.���I�z����%'����V�u������1���T~��sKw��������^K����f��K��7����s��"�(��UC|��C`�t��j�~*��A�a�_���z-�F���#�)�%��dW{����H��x���W9;��r11oAH]���l;���������7�`�n���R��G��}��!��qHQv���f��C��{/y�[�������p.�W:;E�����.���%�SS�4N>f+�z����)�i����Vf+�O��X~)��s���@���[�!0�&{�Kz����R�U��E�W%y���.�1bR���<�O+����2��M�	�i����f+�\P���r�l�x�C���WQ1h�O�-EhC��-T�'�:P�������"22�l���b��0���"L>�c��*����u(�I�4��I�������8��-���8=��H%�Y�yihG]t+Y�n����3���H������J�`�N�l��X��
YR����H�h<����M�	C@��=�Fg��\
��1�Lr��;/���g�0���%���(����o_a��%��(��WKz�����7���O�G���K,<]�l�]����C(���Po��+ ������/mm�nJ����T�
�"d���A|Eg)������&��S���#�r����Q�L�!?�*�,�e�}'�
�zu
�WDi�`����q�:h/���1SnR���]���<2U��=�����cQ<�)�%�)�!�|W��B�VP�Wy,y;(7��).�\��7�)U����U�Y�i��	Ym3K�hS����U�)�Z���g� �T��X�d����BA��5��\0@=S�(�j��RtB]�h6p�i4W�3�����j���6���9����nf��(�)v��N��>�����1�>�QI�_�5���8�����V�.�!F�����Q�g�u_h>��j+������?\v�~���������"�
�?���
�o1�e�TV]�����,�y�����
�/�N2�*$���K�L�f�yd�����0���0`�Y�5�t6*y��V���t��E|�t*ido)A��Z$���Ot��f����T��1D���fz�d�������������=d��9bQ��n�=1�C��7�w%�;���R2N��* 7�1K�����&�.;������jS��*��������S���Iu+~��)9��S�	��
:r���������G/8|�)�_�yxI��V3�?^n�l���u#���k�����m����*dn�w{{����6�V�z^���:g�����������q�end���gI<BHN�TqQpG�e�"����J����fh@�$��s�������TK��R-�lo�v;����4'`�������}�����(p\��d���k�!���	���T�m���^3�MP3m	�p�l�7����r�
�����Jt����Qx���,��Nw�&w����
����)4KU��R�%�~��d��������V�>�^�
�����P4fx3�U��9A1�s<�D@h����l�����8�0�LP:�-�*f��c��:������I��'"��PF�QX���x�(+�&��V5s�2��5����y7m'���L��'F������6G����7;��� �@��;@e# ��
(=�pz�pV��n.��G'�k�"����u�^����wz������wy$��p4�����Iy�A�*v���k0!D���#Wa�������%�������o���`g���W�M��<
Se��k����Ag�9�����(�,
�KJ����JM)������T
=��|YO��/��ul��Xu�n�0!ze�M�(���w�����N!n�H
�1���x<��I��G�@��1�&~,��y��0������"�a�]��v���@�\uT�KP=���SI������<s����Z���RE��������P
��|`�n��w�%O�O�RzpG]�p�%���x{��E��[k��j��j?�����*�����t-��Oy3lI��7�-}y����#<��,��Q������'jH�(��JV�P���P����tr����1z�M��G�A$)*<NP��`���_�"��3��"$�%����X����7J��js��~4�zA?�x����������8��L���~~�98�?Rg�/u��g�8JnM�'������W�o��5������J8�f����L6�+�x(���A�3�:�Q9$��=q��7�r1V�b>����JE�����n��^3~��*����:����v^�V�rX�Dis���0�P�H��''4��z�$��Q�j������
�@�I���{Ia�U�B��L��L�"-��5-��r��n`���);B���@QGi�2�L"�tV����~�M���F}�U���w��Pju��.O"����s�14�Z'`����,�r�F�=yk6F�<4q��5T:E����L��i�\�>P�����89����R���0���!��c�/���kr��=���Y����O$kY���s�J��U��B���]��{w���36{��+A�%��f9v�^��(�l�`�����idN�~��B�U�$������Vt
�&��O�g��z�0�%]&��� �r��m���a?�b���@3��:�3u�8���y�5������3yfL5�e6��"b����,�A�?P���`�<���������8�
�r���&���Sr�_���
��u�vq���r�Yn��xJ������A�����t=_�;s.k��e]p$o�+a����zYf���yb�������>�@�W,(���r����;$B^G���
H��6�+�JP�1�P��%]�@	�NO��w.v_��������a�!�*�;!{������c���nG�&���y���cs*�R_��n���|'�I��?8�����oZ�:��i��������6������D��O����@��c]n�m8A	)q�lr��{����p���=��4���(�V;h��Ft��U+�H�����<}���������:Chz�{��&�7�A.�S	�,���vU5����=M���7N�?����s-8F���H�|p��Y��r!%!dc�:/'fW�W�Z�H,M�9V��@"��>�R]{wv�Aw�Fl����;/�ksccN��
d������J�v��#����} ��z�U�:��X��B�#��'�4x�a\Le���Mq��s�9�����v�l�m��3LQ��sx|�9;��t~<��^�oll�[��,����fT6�;)f��s��N�pl�syz7���=<C��x+3�?���P����\N������Qx��I����mU���LE��L�����?�o���c\�-����U1������`�lA8D���>�u���{
(��e���$��{L�<S��1$�{������EC�����FQ/)b��������"����E��y��T�?�2y�suj���A�9e�������V�A���*��x�����@�P��S�a���~�p<J���%j�P9D�U�C��i<�loL�/}�7�j�TL��6�A�ibG�F������SD�����]�C"Q�+�������������v7B\��@5�}$0it��������l��uU�������5'���Z<D3U�e�X� ^L:
��2�u��,)��w�j�fP��0�?\�\t���2�B�9�?����C����������Y���s.����(H����=������<���!P������.��������<�\����3�<;<�/�H?���
^���{�v��{����}�=:���f�G5������y��s�����������{�qpr�V���������;R��C��������}?��CQs����wt_���8E��T�A�V����Y�b�9&h0������4�?�{��J	jRV�,���*�����hP����O}|�����r_9_UP)�SA)�x�4����$��UY������$]�)0���lB�����Uu������m��Z J�p.�7�:�m���SFS�M5=���Q.��vU@z�*1��L��c�"~e����q+������tx��4,���6��z^q��
����3:�����Lu���u8wW<���R�_w�[?,��W^l����N��[�u���������G�k>��s	����-�o�Zn������������C��������gE����pw����a<����d��y��g2��	����d�/���"w�m+�����!�W�����!O��,���)����������8XC6�k��"�����GQ'?��7����,!���Ti��J���A����8���QO��?�	�:V.=*�)_/�A�`�1����������
��[��k%���������l�7
��&?���O�{�[pcw>k{��8�0ld���:���r��&U�qh��:�9]��	����{_
3'B����n���c��5��J�"�=����;�����Pj����^t�O���=]�R�$���������yr���.����LZ.�������Vn�Z����� �M��v����R{{x`;�9f��:�L1�T4���f����rJ+����jz���z��U� ����/B��g��$����bI4��h;5/�{E�����O��	b\7���$A��i7���f�1�m�^����B>����"`z�������L?�U%r7k�[�f�nUKN��1�G�/Ll43�h$�D[��-�����jV�����h�Q� ��f���V��u������]le9��`#��+3�9�����E�3Nt�)�X���g��\5�LR�j�������z�F�*�qpr�Z���O�����F��SCT����ig;o��1�=�Fm^N�W�1q#�\�h��u�����y!�[��p~��U@�E�s����������<��#F�T��4�46�?Q&�P��w�Y�v=�����&�`!���m����������D6�MM�%e ;5u)5�l[iv0���T�cm��:
Y��r�k�����F��%����o���8N~�-{1����Sc"
�qn8L�;���6��sf���D�.�C��5���@j�#�O
�hM�����z��������@l�-���q@� �vD�u�C�$��c�*jH?�`aG�����J3��G��#�89?S���>��Pjd ����A��P�������EDW��]�.e���:e��	��h���=����m��<���P^�:~'�o�}H:b7��g����7|X��~)'zS?js��y��6��=-�	�{s��70�����Ohqt"��ijOb+%0������LT�
��DD���8i���A���'�\�\O��b&��\�Y��YO�C��U���\tEo{SS�S�V8��O(Oj<���������dZ��`���nl�n�����`P5j�h�j�f����T�Q=���	
��I6{������E�}����,�0B�C�1� �8��
$��{����4�7���0
�����F2�fB��4�e�E�����V9�M��xY�m�1���k�
\�[� ���~�?��#� ��I���A�H��q��v�H�����!x���lu�)%qGyyP���B�BVav�G���;���qCyVY+�f�IS�����H�\ ���Z�9TN�+�n����_���5~�������^�iU�7���yp����
��0p�
�Jn�4��r�1���T3�' kh@�Z}���NN��j�rP+3�Z��k�t6,������r����zx�,�K\���=�r<�w�r^1�sK�� �l���q�pc-����u9���e��#d�-L�o�2]�A��z�F����rQ��X��]E3R�
i�H#��a��1������'�

p^T`�
�JNU`��r��t�
���Lm�"��7�*�`�V�
���3���M-��o�����= x}�, ����6Q�p=;2hzo�a,�{;	SI��mq�K�?`]o��$F�$8�fB������-_���bu�1���S*��N�u-1�����k���ZFq6�T��K��>�)�@����
,������K>��hvC)������\_C�'����
�:�*a��v�u{\�������7N(�?�'�(������&Xx%�=R����H����������`)��zx=DjbR��,��=�u>����
s4��m�"\hH���Q���Wi@�^h^�����f�=Gc~��	hlV��?�c�������<����,��^{Ze���E���B�F�a���N���+���Ar��/"�)�������J��I�iD����)}d�#��^�An<8���z#�7�<��4��T�����j�Ez����2��fM-�:��je��8����e�Q�GY�h.��4�:��8p(<�buj�/zu�n��y�v�	ZsV�8Z���m�[�if5���9���6B�u|*F������Q*;��A�[��P�����#(o��at��
g�5l�x���
���V��F��)5L�of����t�17�X�d�z������0�x
'�3R������(�$�\�b����HT'\��"���Sq1�Z;h2S��&��	p��gL��G�������y��2`�����R�G����J�B��>����ky31��jvDCp��o1	$j�!9�!�20��|#=����P�B�y��w��%�4U)�+^����h�����$P	�9��A<����?^��J��h��fi)W56��f�����_RO�E:��M�������s�����I���~4�����g��}eA�9\��*����E}�b&�3'^�oj��l��]�]�&{:=u����-���S��3��C(��('`�-��%LqQsr�$�{�99I��[���n-���;/Y���
/%��s�[�f4��5���V�>#4�s�h@i��)T�����E��(�7D��nl�d��4������w��J��oC)�F����r�$�����c�
�^HPp>��I��x��=#��o;���0}��W�O_���;��etz�4m���Ag�s�&����~/�����worC)��I�>��'^f �mut��"��T��9���!��85�7Y��!��vj�m��rp���F*�6�ON��_A�h4�`PT��r���'��(
V^�w77���1G.l�67�������]
��;�-U���6h�0����.u���}�^�BS�[��U@����[k�Wv��?��xx6�-��2D�`�b���J�?��jp@��./��X�`n�Ie6Q	��e#�z�,K�,gaR�������5 !d��<���oB���&�$]��
��
�#U�0VxB�6�*EW����?����U$+k}��$��5�C�=����,��=�k)��BA;`�#!E�<�n�e�<,��	P�^0��FQ��p6\t�gNys~�����O��^��E�!VuC��Uz&��^��_�������-��������_�/�������tn	�\"pu���C����i'y�F�V!���+Im�uMp6�5f�	�\7t��x�+O��� a���������~3��vnk��
8��m���_[�>(�s7�\���#��������02�������q��}�]���B}��Ww�/���_*X�e����f���Q�w��/��G
S@���s�f�+��5@���$�u`v���]����>�+���-�<�������I�8��	���v7�t�z��D����x�E:IL�iG������6�Bw_���������(�-u	��z�^
���tl��P��?�8x��%�����/XfP3s��$	rE�T���������$�[on@
���y�������������R�g�c���<3MP�o����!q�j��D�HO��������E���aS+M �F��$@�����q�-8����xgZ06��$�|����7��&X
	`������9h�����+%�>��������W]�������;�P��p�e�+)�c�.��v����/�����������Y�g6;t?�,;��j�N��qI�#���`1����C��O�e��U����#�ioP�)��]o���Sz��G���=-#p	��D�y"���a�[����@���L��:�M�Z!�W[��hF��:�^iz��)=����vS{i�%K�d��?
]��.��6�nm��[}�x�h�����h��	)�s��T��bQ S8���Arp�����]����o���T(P[�	�[ ���-���6n�{�X�K��*Z�JN>�3$�������L�)�k��%��8���9�?s�S���<�J�b��/��������&����ZJ����^���CaQ�k�{�
���-K��lz��fvX���p�������$���k�V^{���X�h���i����;������J�����)bV�� (�������#�� ��P9����b����$<�r���z�#f7�S�\���:��������_��h
.�"f���L�����TUfL���S���Zy�:x8���S�w�GG��RJ������\Q����F3��x��LViG�r�yw�^�@
������V�~�(������x+���-?�L������+V����0���"����@�b������M�x�����u?�V��+&3tW7��9�J��"���5:L�!-���i���%�O����2L �z���}�"������hw-+h�}��>��v6��%i��o�M�-�G�C������
7|f���c�Dk����h�����ea�cI��#��wD7��?��|-����z�.�=9[x��wS���1�2����x�r![��i��A�������8��������Lb��V5\��,�<z�e����?.m���V�7����@^�� ��KL
}��������,'%����=��u4wP�VrcI.p�b���
\��s�Wy��.C������
������y��NM���m�Z���7)4:��N��u�q�K�`�5��B�IKA��6�b�.^ 9.�P�8���.�3�J����� �W.{��eVu	�[�_�j+W�������C~L��f;(�Z5^/.�������G
1{��S�fR�zxj�x,��6:��n����v�H�"�|��D��I0��U�����=V�Aj����<2yy6M���O,����>�w��k8&��4��X7	��K{6#��<�
Y���Q=hE����6�;��.~���$S%Nd��"���p�����l�p4���c�r���p`t� �)����d*5����?��.kE��R'��!��j^�S��,���Z7N�
R�w�-D��ba��$����H(��llYE���DzI3nefI��2�LZ����"���s$�^h���O�Ye���vru�R�j4��;���j�@�J��*�+���Yw�+���`�6�n��bq��#�����tz9���X���������pX��Y���DA{���`�-�w5K�
�V�EU�&�����I�FR��I��D*�w���T��[��JKv�L��;()��Y���\�����u!�Z�c�J<���P:�/��n2��I<���"H*����s�������a���<���3g����#C����~V���p�SE>����ZE����=5�oa_���r�eh5-�)pPo���r=��?%v���)ur�"��h	����z�A���k�<&v��<��FJ�K���Q&��Zcl����QFKm��{��y�W}�0�A�8J�H������RKP����a�D���$>�/���S���A�V���dmy�^+g�����#��W\�����������3
H&] ��8�
{��!�-�|��`\���B�w���s�r�r�����V�m�%N7�7���>�$&�Ez�B�
L�t�w.�Y5v(J����j��7*���t��
�M�9��=���op�pR�2��������9c�y�{0,�>�>�k��p7!��0��z!�t��;o�o�k,	�����$;�0����%��*��f�}���a�U��u�����j���J���<�r9�x��V��[��<�*	Npv�p��=]��q���/�Tv/�x�/c%b��I������,�?��(�^=tqG��/������Z3�j�@�8�~�U�H��\F��zJ)MR.`2���
q���#�\/f;��$�+�C�T��
�>�/��Z[bd��9Zm���v�a$������o������^&��n.6"<AM��h+����H~f��&Hg�\T���'���C��J[T����n���S
�#r�K6�Z�Y��B�.��������Qj��]@h�#-5�0���Q�1L�}���W�a#���Z ��2��r�*�=��������xPz\��Uj���D}I�v1q���  �8b�y+=��~������� ��g��(P*����TWD��pW�h�*������B�S<�9���$BEG�'�[9���jv���(
	K,N3..f��J�S��WJP>�RD���,]_��P�nqj�!Z��S]@[[ e\;>N$�$6��j`aa"{6eG9Z�g��Q�������}��}�tY�M9�[�����2'�M)�3��$mH%4��G9�-�jcx�Bm}-�����.����eZS�b�����X�[o�O�.lN����-l���%\O[�BQBq8h������G�V0�>���5kQbJ;
G����.�^�8��N����*c�Z�	ut�)eu*���n;�E��_C9g����o3)�w���ASc���
C�0�*�D����R,7�g8���}(sV\w:f���x�P���{3u&�m��Gsu���D��H��N��xiZ),�j�����;���i*���*��IB��`���R�TJUV%�Rj4�����h��d3Y��t4b�.w�Ta9DE-_y����S�b��������t�-���T����z
9���v�9t���������5y�U��d�2#�5[�@���$��J-���U�0��[B,�%����gT����\�'��������Lg@�����T�[���&t�4�������+M�a��������|Q �f8t�H���jM9��*�38������D�o�V����QS���;�W<��f����WPj�Q��B_�����xx3���B�v=��K���Y:-2����i����2�	g'���XI��^k�{�V	�-)2�j���n}Y�u���_%�b{~�-';��������H���������v-�(��yy`h�Vj��{��G����r��3@ABO��.��.��%V�#��.�Jmtx"�SJ*#��>>y��?=����W����>3n��O�R��c���UW�����R�^s�����s��n���4�S���E�N�����O���sg-�
P�jn��fjG�l-,W	�xj��h��-i3��V�r/�>,7�j*�~P���p�>���R�W>����LC"4��Q��W�U���������T��7#������F.t��K22s�C2>v��d��}����=�+���m?����|y������z�/!��L=~*���X����)��e�S��"��������jP��XY`�������[$��)����1��S��>R2OGz>���|v��dED��������^�^���=Of��T� �{Y����$X�3��1��R&�v�)F��w�����&��c[bp���f�d�l�����uI�FSppFoL(����RAS%��@���-�+�_�,����8�xy^apw��Q+Ko��W�UZmv�Zmy�nI�V3�Q�7�Ah����.w�V���[��L�v���o���ar��@��f�������k��[<�@`�����moj�U��=����PX�l���BAh�Q%��q'��gU����) V.C��r���`��X���&s`w8���_��P��5��(����f	�� ������	*5�����g��m�

�/���}������Kq���'���0�B�Ss���`h������f'�^v�&��wG��
!���e�����(�ZZ]T�������z^�����G��[N��+���2XO�cC�
rz������|��D�1�D��OaPAl�� �l��o�V~���=��[��7vk��Z�Q��SO�z=h0����%]]�#�KZ��.Y���������L��z,�(�&���0�	�����-����
{#v�oC�a�}�}���_@���M��
Z56bK^9�
�Z~�)���[�R�c�0��%�x�k���n5�6�<i��v#g�8T�X�z�$�-o������*�E�V�����+/��Ht�=�8�c?M�W�e��9H�������q�����9�R��x!��~g��g���Ze�C��������%N"���AO���X5�5��T?�t�6�6C�<Vg�s	��2T�!���jiy7�e����R-en6�-���1�L�d�N���-��b�J^g(�&}Q���1Oa�@JZ�c���PfN�gN�r�D��4�@aYTQ��%�VPm2�h�)��e�4�d-{kN`"G9�-^��A�"^�����r�s\��B�������m�����O�CU,N�0��(UgQ�F��we��B)�`����P�R���J'�b69E�c����)����U���<���R�����Ks����P	��-=T���������Y�O4������5$qH�$�0�r%3l�i(_�+��e}�?�k��^kk �� �CPP,�����������P�u�<	E���	��'Go7�����6k�J4��Z�~���l�������R�����M_����#�������Q�
�����?��O�z�(\�����s���V%���Yo��F��/�-�����f�!(�)@���;�
���T����.�)���"��P
�0N!���#�M(�(��=�DB�!D���f����"���Hg���GG;��hc��QOB3�J����W$�������A���U 1����o������F�0�V9h0p��q��7L�>>��x�(�A��t��/���!V#C������:0�6�����OD��={��t$�����tA�k���n�m�����D�9�w�����.h��x�9������J����M)�4[F�iOv��w/�P��l�������,�6>b�a�R�����g��T~��N���$=jY�Y�,���Y����'0���!Z���u��!�����%x�h�]Er�_��Q�p��\f*�;lom�\��n��[)?����|�>[�!��g����	8�.RqW�	J'�o���OZ��>h�N��"��(�+�8$�et�f��E�WU*��DqG�/��v�HkZe����m%����F��M�FD��x�M��������kS�+N�*w�/��p$I*�-l^IY"V�����Pq�&��^r�
�m�V9� �"����*��t���8�u�y/?�)$RXb��}$����@�1`aOfI bA�� �5�Y��	SP�Gr����R(I��e�D�\7Q����x�����(���8�.������;����:�����Jy�W`�?��l�O�(���CY��x
G���;�h�3���G��kA�E����r���P�d��f�pJ�����)l���@2%��p�f��
�^yA������Q�����Ak���(������r�<K��D�M��}�.�Tx`����r����X'���Ss�2�+"��.n���wG)z�{aB���+�}�%����k*4Pg���~����y4�!��~���m��%S���pP���<@����w+�|���b��u�s]�N���;������^]���w����~�$�����Z�q�b��w��L�38o�C}W�
��K�l���v�$?�G����r�}���,�Sr2i5� �A�1�����n����Q���c�1�;
�=^&!�����lo���3�O��P����5��']��y������G�;VO�YA���<�������U��~�a�<e��$�����F�w*9v�V���/����,����~����"�nCO���Oo$�����\�d��!���i�8�a� �U�JF��B�=�����t[��#R
�['�s���@%m0#d�� ���(�2���X+����1r'���
���r�~9&�9��sW����@��"��@��>K@ps:�����}�{DNqOY������
2w�����"��pPP=7��l'�e��v_��S��>�]E#
���&����(��
�=�o��N��-�9��<\(��e��{�2e!�������8/�a���2h�R�I��7UE��{��p�����&�g��)��o���A��w��&K0�v��m#�����d���f)~�$#~v%y�c�Q
�gY�l�w7� ����^u����n�^�����S�+���z��;7��j���X�M�H�2"P�zc�V4�&!�c]�!+��\C���?����q"�����'9�,
{E��5�A���~0�.O.:�,����B�9�?������}��{a�������o;?

}�����W�@G~������v�/��=���G��yx�/?�;��b��>������1��������
�^������o��G'����������J4�������+���
#4David Fetter
david@fetter.org
In reply to: Tatsuo Ishii (#3)
Re: [PATCHES] WITH RECUSIVE patches 0717

On Fri, Jul 18, 2008 at 10:41:20AM +0900, Tatsuo Ishii wrote:

Here is the lastest WITH RECURSIVE patches against CVS HEAD created by
Yoshiyuki Asaba and minor corrections by Tatsuo Ishii.

I tried this patch vs. CVS HEAD used my usual configure option with
only --with-prefix set, then tried to make, and got:

make[3]: *** No rule to make target `parse_cte.o', needed by `objfiles.txt'. Stop.
make[3]: Leaving directory `/home/shackle/pgsql/src/backend/parser'
make[2]: *** [parser-recursive] Error 2
make[2]: Leaving directory `/home/shackle/pgsql/src/backend'
make[1]: *** [all] Error 2
make[1]: Leaving directory `/home/shackle/pgsql/src'
make: *** [all] Error 2

Is there something missing?

Oops. I forgot to include patches against newly added files. Please
try included patches.

This now compiles.

I have a test case that hangs and smashes.

WITH t(i) AS (
SELECT * FROM generate_series(1,5)
)
SELECT
t1.i,
2*t2.i
FROM
t AS t1
JOIN
t AS t2 USING(i);

server closed the connection unexpectedly
This probably means the server terminated abnormally
before or while processing the request.
The connection to the server was lost. Attempting reset: Failed.

An equivalent query without RECURSIVE breaks in a different, in some
sense even more severe, way, as in it just hands out a wrong result
set:

WITH RECURSIVE t(i) AS (
VALUES(1::int)
UNION ALL
SELECT i+1 FROM t WHERE i < 5
)
SELECT
t1.i,
2*t2.i
FROM
t AS t1
JOIN
t AS t2 USING(i);

i | ?column?
---+----------
1 | 2
2 | 4
3 | 6
4 | 8
5 | 10
(5 rows)

While this case is trivial, others are not. For example, if someone
wishes to do a k-deep summary on a parts explosion n levels deep, n>k,
one way to do this would be to JOIN the k-deep part of the path
enumeration to the parts greater than k deep.

What would need to be fixed in order to make the above things work?

Cheers,
David.
--
David Fetter <david@fetter.org> http://fetter.org/
Phone: +1 415 235 3778 AIM: dfetter666 Yahoo!: dfetter
Skype: davidfetter XMPP: david.fetter@gmail.com

Remember to vote!
Consider donating to Postgres: http://www.postgresql.org/about/donate

#5David Fetter
david@fetter.org
In reply to: David Fetter (#4)
Re: [PATCHES] WITH RECUSIVE patches 0717

On Fri, Jul 18, 2008 at 07:56:09AM -0700, David Fetter wrote:

On Fri, Jul 18, 2008 at 10:41:20AM +0900, Tatsuo Ishii wrote:

Here is the lastest WITH RECURSIVE patches against CVS HEAD created by
Yoshiyuki Asaba and minor corrections by Tatsuo Ishii.

I tried this patch vs. CVS HEAD used my usual configure option with
only --with-prefix set, then tried to make, and got:

make[3]: *** No rule to make target `parse_cte.o', needed by `objfiles.txt'. Stop.
make[3]: Leaving directory `/home/shackle/pgsql/src/backend/parser'
make[2]: *** [parser-recursive] Error 2
make[2]: Leaving directory `/home/shackle/pgsql/src/backend'
make[1]: *** [all] Error 2
make[1]: Leaving directory `/home/shackle/pgsql/src'
make: *** [all] Error 2

Is there something missing?

Oops. I forgot to include patches against newly added files. Please
try included patches.

This now compiles.

I have a test case that hangs and smashes.

WITH t(i) AS (
SELECT * FROM generate_series(1,5)
)
SELECT
t1.i,
2*t2.i
FROM
t AS t1
JOIN
t AS t2 USING(i);

server closed the connection unexpectedly
This probably means the server terminated abnormally
before or while processing the request.
The connection to the server was lost. Attempting reset: Failed.

An equivalent query without RECURSIVE breaks in a different, in some
sense even more severe, way, as in it just hands out a wrong result
set:

D'oh! That's what I get for sending this before waking up. It works
just fine.

While this case is trivial, others are not. For example, if someone
wishes to do a k-deep summary on a parts explosion n levels deep,
n>k, one way to do this would be to JOIN the k-deep part of the path
enumeration to the parts greater than k deep.

What would need to be fixed in order to make the above things work?

Cheers,
David.
--
David Fetter <david@fetter.org> http://fetter.org/
Phone: +1 415 235 3778 AIM: dfetter666 Yahoo!: dfetter
Skype: davidfetter XMPP: david.fetter@gmail.com

Remember to vote!
Consider donating to Postgres: http://www.postgresql.org/about/donate

#6Erik
er@xs4all.nl
In reply to: David Fetter (#5)
Re: [PATCHES] WITH RECUSIVE patches 0717

On Fri, July 18, 2008 03:41, Tatsuo Ishii wrote:

Here is the lastest WITH RECURSIVE patches against CVS HEAD created by
Yoshiyuki Asaba and minor corrections by Tatsuo Ishii.

I tried this patch vs. CVS HEAD used my usual configure option with
only --with-prefix set, then tried to make, and got:

make[3]: *** No rule to make target `parse_cte.o', needed by `objfiles.txt'.
Stop.
make[3]: Leaving directory `/home/shackle/pgsql/src/backend/parser'
make[2]: *** [parser-recursive] Error 2
make[2]: Leaving directory `/home/shackle/pgsql/src/backend'
make[1]: *** [all] Error 2
make[1]: Leaving directory `/home/shackle/pgsql/src'
make: *** [all] Error 2

Is there something missing?

Oops. I forgot to include patches against newly added files. Please
try included patches.

This crashes the backend:

WITH RECURSIVE t(n) AS (
VALUES (1)
UNION ALL
SELECT n+1 FROM t WHERE n < 5 ORDER BY 1
)
SELECT n FROM t;

apparently because of the ORDER BY 1

( ORDER BY t.n will just error out )

Compiled with:

./configure \
--prefix=${install_dir} \
--with-pgport=${pgport} \
--quiet \
--enable-depend \
--enable-cassert \
--enable-debug \
--with-openssl

hth

Erik Rijkers

#7Tatsuo Ishii
ishii@postgresql.org
In reply to: Erik (#6)
2 attachment(s)
Re: [PATCHES] WITH RECUSIVE patches 0717

This crashes the backend:

WITH RECURSIVE t(n) AS (
VALUES (1)
UNION ALL
SELECT n+1 FROM t WHERE n < 5 ORDER BY 1
)
SELECT n FROM t;

apparently because of the ORDER BY 1

Thanks for the report. I think ORDER BY in this case is useless
anyway. ORDER BY affects (VALUES (1) UNION ALL SELECT n+1 FROM t WHERE
n < 5). Since this is a recursive query, value for (VALUES (1) UNION
ALL SELECT n+1 FROM t WHERE n < 5) will not be determined until the
recursion stops. So the meaning of ORDER BY is vague. If caller wants
to get the sorted result of the recursion, he could always write:

WITH RECURSIVE t(n) AS (
VALUES (1)
UNION ALL
SELECT n+1 FROM t WHERE n < 5
)
SELECT n FROM t ORDER BY 1;

Thus I think we should avoid this kind of ORDER BY. Probably we should
avoid LIMIT/OFFSET and FOR UPDATE as well. Included patches add the
checking plus minor error messages clarifications. Also I include new
error cases sql.

Show quoted text

( ORDER BY t.n will just error out )

Compiled with:

./configure \
--prefix=${install_dir} \
--with-pgport=${pgport} \
--quiet \
--enable-depend \
--enable-cassert \
--enable-debug \
--with-openssl

hth

Erik Rijkers

Attachments:

error.sqltext/plain; charset=us-asciiDownload
recursive_query.patch.gzapplication/octet-streamDownload
#8Tom Lane
tgl@sss.pgh.pa.us
In reply to: Tatsuo Ishii (#7)
Re: [PATCHES] WITH RECUSIVE patches 0717

Tatsuo Ishii <ishii@postgresql.org> writes:

Thus I think we should avoid this kind of ORDER BY. Probably we should
avoid LIMIT/OFFSET and FOR UPDATE as well.

What of index-optimized SELECT max(...) ?

regards, tom lane

#9Tatsuo Ishii
ishii@postgresql.org
In reply to: Tom Lane (#8)
Re: [PATCHES] WITH RECUSIVE patches 0717

Thus I think we should avoid this kind of ORDER BY. Probably we should
avoid LIMIT/OFFSET and FOR UPDATE as well.

What of index-optimized SELECT max(...) ?

Aggregate functions in a recursive term is prohibited by the
standard. For example,

WITH RECURSIVE x(n) AS (SELECT 1 UNION ALL SELECT max(n) FROM x)
SELECT * FROM x;

produces an error.
--
Tatsuo Ishii
SRA OSS, Inc. Japan

#10David Fetter
david@fetter.org
In reply to: Tatsuo Ishii (#9)
Re: [PATCHES] WITH RECUSIVE patches 0717

On Mon, Jul 21, 2008 at 08:19:35AM +0900, Tatsuo Ishii wrote:

Thus I think we should avoid this kind of ORDER BY. Probably we should
avoid LIMIT/OFFSET and FOR UPDATE as well.

What of index-optimized SELECT max(...) ?

Aggregate functions in a recursive term is prohibited by the
standard. For example,

WITH RECURSIVE x(n) AS (SELECT 1 UNION ALL SELECT max(n) FROM x)
SELECT * FROM x;

produces an error.

On the other side of UNION ALL, it's OK, right? For example,

WITH RECURSIVE x(n) AS (
SELECT max(i) FROM t
UNION ALL
SELECT n+1 FROM x WHERE n < 20
)

Cheers,
David.
--
David Fetter <david@fetter.org> http://fetter.org/
Phone: +1 415 235 3778 AIM: dfetter666 Yahoo!: dfetter
Skype: davidfetter XMPP: david.fetter@gmail.com

Remember to vote!
Consider donating to Postgres: http://www.postgresql.org/about/donate

#11Tatsuo Ishii
ishii@postgresql.org
In reply to: David Fetter (#10)
Re: [PATCHES] WITH RECUSIVE patches 0717

On Mon, Jul 21, 2008 at 08:19:35AM +0900, Tatsuo Ishii wrote:

Thus I think we should avoid this kind of ORDER BY. Probably we should
avoid LIMIT/OFFSET and FOR UPDATE as well.

What of index-optimized SELECT max(...) ?

Aggregate functions in a recursive term is prohibited by the
standard. For example,

WITH RECURSIVE x(n) AS (SELECT 1 UNION ALL SELECT max(n) FROM x)
SELECT * FROM x;

produces an error.

On the other side of UNION ALL, it's OK, right? For example,

WITH RECURSIVE x(n) AS (
SELECT max(i) FROM t
UNION ALL
SELECT n+1 FROM x WHERE n < 20
)

Yes, aggregate functions in the non-recursive term is allowed by the
standard.
--
Tatsuo Ishii
SRA OSS, Inc. Japan