I am using a sproc to query 2 tables and input data into a new table for use in a ColdFusion file. I use a cursor to select each row of a table (Issues) and another cursor to select all rows of another table (comments) that match the first cursor's item number, ordered by date. As long as the query for the first cursor specifies a discreet item in the Issues table with a WHERE clause, the second cursor finds the comments and outputs them as expected. If I don't use a where clause in the first cursor, I get nothing from the second cursor query. Any idea what is happening here?<br><br>First cursor:<br>DECLARE OuterCursor Cursor FOR<br>SELECT actionNumber, recommendation, priority, details, leadOrg, ownerLName, contributingOrg, currentDueDate, nextReviewDate, status FROM Issues /*have to include this for the second cursor to work*/ <br>WHERE actionNumber='4.3' (yes, it's a varchar field)<br>I fetch the outer cursor into variables, including @IactionNumber for use in the second cursor.<br><br>Second cursor:<br>DECLARE InnerCursor Cursor FOR<br>SELECT Comments.actionNumber, Comments.comment, Comments.date FROM Comments WHERE Comments.actionNumber =@IactionNumber ORDER BY date <br><br>AS long as I have the "WHERE actionNumber='4.3" or similar restrictive clause in the first cursor everything works fine: the second cursor finds all the comments and does with them what it's supposed to. If I leave out the WHERE clause or include something like "WHERE @IactionNumber !='1000.0', I get more records returned by the first cursor, but nothing in the comments from the second cursor.<br><br>Why do I have to specify a WHERE clause in the first cursor?