4 Replies Latest reply on Apr 25, 2004 7:11 PM by malipanchu

    JBoss-ql in 3.2 vs 3.0

    toaka

      Hi!

      Im using the following JBoss-QL query in JBoss 3.2.x :
      SELECT OBJECT(f) FROM Filme f WHERE f.tipoFilme.tipo = ?1 and f.vitrine = true order by f.codigo desc limit ?2

      and it works perfectly.

      When i deployed my application on JBoss 3.0.x, a FinderException is thrown complaining about the limit clause:

      09:04:29,067 ERROR [STDERR] javax.ejb.FinderException: Error compiling ejbql: org.jboss.ejb.plugins.cmp.ejbql.ParseException: Encountered "limit" at line 1, column 103.
      Was expecting one of:
      \<EOF\>
      "," ...


      Is there a syntax diference between 3.2.x and 3.0.x ?
      Doesnt JBoss-QL in 3.0.x support the limit clause ?

      Thanks in advance ...

      Thomas

        • 1. Re: Adding an RSS feed (block) to Nukes
          malipanchu

          Thanks!,

          Here it goes:

          <?xml version="1.0" encoding="UTF-8"?>
          <server>
           <mbean code="org.jboss.nukes.addons.modules.rss.RSSModule"
           name="nukes.modules:name=rss"
           xmbean-dd=""
           xmbean-code="org.jboss.nukes.component.NukesMBean">
           <depends>nukes.modules:name=core</depends>
           <constructor>
           <arg type="boolean" value="true"/>
           </constructor>
           <xmbean>
           <attribute name="Security">
           <security>
           <permission group="Admins" pattern="::" level="ADMIN"/>
           </security>
           </attribute>
           </xmbean>
           </mbean>
           <mbean code="org.jboss.nukes.addons.modules.rss.blocks.RSSBlock"
           name="nukes.blocks:name=rss,feed=sf.net"
           xmbean-dd=""
           xmbean-code="org.jboss.nukes.component.NukesMBean">
           <depends>nukes.modules:name=core</depends>
           <xmbean>
           <constructor>
           <arg type="boolean" value="true"/>
           </constructor>
           <attribute name="Title">SourceForge</attribute>
           <attribute name="Side">2</attribute>
           <attribute name="Weight">3</attribute>
           <attribute name="FeedURL" description="set the RSS feed URL">http://sourceforge.net/export/rss2_sfnews.php?feed</attribute>
           <attribute name="Security">
           <security>
           <permission group="Admins" pattern="::" level="ADMIN"/>
           </security>
           </attribute>
           </xmbean>
           </mbean>
          
          
          <!-- Additional RSS block starts here -->
          
          
          
           <mbean code="org.jboss.nukes.addons.modules.rss.blocks.RSSBlock"
           name="nukes.blocks:name=rss,feed=slashdot.org"
           xmbean-dd=""
           xmbean-code="org.jboss.nukes.component.NukesMBean">
           <depends>nukes.modules:name=core</depends>
           <xmbean>
           <constructor>
           <arg type="boolean" value="true"/>
           </constructor>
           <attribute name="Title">Slashdot</attribute>
           <attribute name="Side">2</attribute>
           <attribute name="Weight">4</attribute>
           <attribute name="FeedURL" description="set the RSS feed URL">http://slashdot.org/index.rss</attribute>
           <attribute name="Security">
           <security>
           <permission group="Admins" pattern="::" level="ADMIN"/>
           </security>
           </attribute>
           </xmbean>
           </mbean>
          
          
          </server>
          
          
          
          


          Please advise what am I doing wrong... (I am sure is something obvious enough)

          Thanks and regards,

          Antonio.

          • 2. Re: JBoss-ql in 3.2 vs 3.0
            roger_cmu

            I thought 'order by' clause is not supported by ejb-ql in ejb 2.0. I know jboss doesn't strictly adhere to ejb spec. Just double check it.

            Good luck!

            - Roger

            • 3. Re: JBoss-ql in 3.2 vs 3.0
              aloubyansky

              Yes, there is. 'LIMIT/OFFSET' is not supported by 3.0.x.

              • 4. Re: JBoss-ql in 3.2 vs 3.0
                toaka

                Yes.

                I checked it too .... jbossql 3.0.x doesnt support the syntax of 3.2.x.
                Even the order by clause doesnt works the same in both versions.

                Thanks !

                Best regards,

                Thomas