Uploaded image for project: 'Cayenne'
  1. Cayenne
  2. CAY-1584

Improve Cayenne modeler re-ordering named query in the cayenne map xml

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Minor
    • Resolution: Fixed
    • 3.0.2
    • 3.1M3, 3.0.3
    • Modeler
    • None
    • Windows 7, SUN JDK 1.6

    Description

      We have got this issue that where multiple cayenne modeler re-orders differently for the named query every time we modify it and save.

      Someone in my team modified the named query, and check the code in. The order for a particular named query becomes

      <sql><![CDATA[...]]></sql>
      <sql adapter-class="org.apache.cayenne.dba.oracle.OracleAdapter"><![CDATA[...]]></sql>
      <sql adapter-class="org.apache.cayenne.dba.sqlserver.SQLServerAdapter"><![CDATA[...]]></sql>
      <sql adapter-class="org.apache.cayenne.dba.mysql.MySQLAdapter"><![CDATA[...]]></sql>

      After I check out and make some changes, the order becomes

      <sql><![CDATA[...]]></sql>
      <sql adapter-class="org.apache.cayenne.dba.mysql.MySQLAdapter"><![CDATA[...]]></sql>
      <sql adapter-class="org.apache.cayenne.dba.sqlserver.SQLServerAdapter"><![CDATA[...]]></sql>
      <sql adapter-class="org.apache.cayenne.dba.oracle.OracleAdapter"><![CDATA[...]]></sql>

      Since we have a lot of named query defined in Cayenne. This makes our merging process difficult. After check out, we'll see a lot of queries are changed. In fact, only re-ordering has been done. So we can't see what others did to the cayenne.xml easily.

      Any short workaround about this problem is appreciated as well.

      Attachments

        Activity

          People

            demitri Dzmitry Kazimirchyk
            frankmanzhu Frank Zhu
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: