cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From <Maxime.Ghey...@swisscom.com>
Subject XSP make loops into SQL (Esql) queries???!!
Date Fri, 16 May 2003 09:01:54 GMT
Hello,
I an XSP page I have three Queries (see bellow) who don't have any link
(ancestor) and they aren't in any loop. But when I request the page I
get a loop from these queries (see bellow the trace of the SQL
Profiler).

Why is there a infinite loop? 


Queries :

<esql:connection>
  <esql:pool>wfmgt</esql:pool>
1.
	<esql:execute-query>
	<esql:query>
		SELECT at_order, at_name 
		FROM Actions 
		WHERE at_ID = <xsp-request:get-parameter name="myID"/>
    </esql:query>
	<esql:results>
	  <esql:row-results>
		<xsp:logic>
			myOD = <esql:get-int column="at_order"/>;
		</xsp:logic>
		<menuA>Action : <esql:get-string
column="at_name"/></menuA>
	  </esql:row-results>
	</esql:results>
  </esql:execute-query>	
2.
 <esql:execute-query>
	<esql:query>
		SELECT DISTINCT pc_ID 
		FROM Processes 
		WHERE pc_order = <xsp:expr>myOD</xsp:expr>
    </esql:query>
	<esql:results>
	  <esql:row-results>
		<h4>
		<center><a><xsp:attribute
name="href">order-archivate?myID=<xsp-request:get-parameter
name="myID"/>&amp;Mode=addt</xsp:attribute>Add-task</a></center>
		</h4>
		<br/>
		<xsp:logic>
			isUsed = 1;
		</xsp:logic>
	  </esql:row-results>
	</esql:results>
	<esql:no-results>
...
3.
 <esql:execute-query>
	 	<esql:query>
	 	  SELECT * 
	 	  FROM Tasks
	 	  WHERE (tk_action = <xsp-request:get-parameter
name="myID"/>)
	 	  ORDER BY tk_priority
	 	</esql:query>	
	 <esql:results> 	
			<esql:row-results>
			<tr>
		  		<td><esql:get-string
column="tk_ID"/></td>
...
	

SQL Profiler :

		SELECT at_order, at_name 
		FROM Actions 
		WHERE at_ID = 21
SQL:BatchCompleted	
		SELECT DISTINCT pc_ID 
		FROM Processes 
		WHERE pc_order = 9
SQL:BatchCompleted	
	 	  SELECT * 
	 	  FROM Tasks
	 	  WHERE (tk_action = 21)
	 	  ORDER BY tk_priority
SQL:BatchCompleted	
		SELECT at_order, at_name 
		FROM Actions 
		WHERE at_ID = 21
SQL:BatchCompleted	
		SELECT DISTINCT pc_ID 
		FROM Processes 
		WHERE pc_order = 9
SQL:BatchCompleted	
	 	  SELECT * 
	 	  FROM Tasks
	 	  WHERE (tk_action = 21)
	 	  ORDER BY tk_priority
...

---------------------------------------------------------------------
To unsubscribe, e-mail: cocoon-users-unsubscribe@xml.apache.org
For additional commands, e-mail: cocoon-users-help@xml.apache.org


Mime
View raw message