doc subselects better

git-svn-id: https://svn.jboss.org/repos/hibernate/trunk/Hibernate3/doc@7488 1b8cb986-b30d-0410-93ca-fae66ebed9b2
This commit is contained in:
Gavin King 2005-07-15 05:13:36 +00:00
parent c62e4b6925
commit 545bb859b7
1 changed files with 13 additions and 5 deletions

View File

@ -840,7 +840,7 @@ order by count(kitten) asc, sum(kitten.weight) desc]]></programlisting>
</sect1>
<sect1 id="queryhql-subqueries">
<sect1 id="queryhql-subqueries" revision="2">
<title>Subqueries</title>
<para>
@ -869,6 +869,13 @@ where cat.name not in (
select name.nickName from Name as name
)]]></programlisting>
<programlisting><![CDATA[select cat.id, (select max(kit.weight) from cat.kitten kit)
from Cat as cat]]></programlisting>
<para>
Note that HQL subqueries may occur only in the select or where clauses.
</para>
<para>
For subqueries with more than one expression in the select list, you can use a tuple constructor:
</para>
@ -1022,12 +1029,13 @@ order by account.type.sortOrder, account.accountNumber, payment.dueDate]]></prog
</sect1>
<sect1 id="queryhql-bulk">
<title>Bulk UPDATE &amp; DELETE Statements</title>
<sect1 id="queryhql-bulk" revision="2">
<title>Bulk update and delete</title>
<para>
HQL now supports UPDATE and DELETE statements in HQL. See
<xref linkend="batch-direct"/> for details.
HQL now supports <literal>update</literal>, <literal>delete</literal> and
<literal>insert ... select ...</literal> statements.
See <xref linkend="batch-direct"/> for details.
</para>
</sect1>