Index: wp-includes/query.php
===================================================================
--- wp-includes/query.php	(revision 21662)
+++ wp-includes/query.php	(working copy)
@@ -2613,22 +2613,24 @@
 			$this->request = apply_filters_ref_array( 'posts_request', array( $this->request, &$this ) );
 		}
 
-		if ( 'ids' == $q['fields'] ) {
-			$this->posts = $wpdb->get_col($this->request);
+		if ( in_array( $q['fields'], array( 'ids', 'id=>parent' ) ) ) {
+			
+			if ( 'ids' == $q['fields'] )
+				$this->posts = $wpdb->get_col( $this->request );
 
+			if ( 'id=>parent' == $q['fields'] ) {
+				$this->posts = $wpdb->get_results( $this->request );
+				$r = array();
+				foreach ( $this->posts as $post )
+					$r[ $post->ID ] = $post->post_parent;
+
+				$this->posts = $r;
+			}
+			
+			$this->found_rows = $this->post_count = count( $this->posts );
 			return $this->posts;
 		}
-
-		if ( 'id=>parent' == $q['fields'] ) {
-			$this->posts = $wpdb->get_results($this->request);
-
-			$r = array();
-			foreach ( $this->posts as $post )
-				$r[ $post->ID ] = $post->post_parent;
-
-			return $r;
-		}
-
+		
 		$split_the_query = ( $old_request == $this->request && "$wpdb->posts.*" == $fields && !empty( $limits ) && $q['posts_per_page'] < 500 );
 		$split_the_query = apply_filters( 'split_the_query', $split_the_query, $this );
 
@@ -2750,7 +2752,7 @@
 		if ( !$q['suppress_filters'] )
 			$this->posts = apply_filters_ref_array('the_posts', array( $this->posts, &$this ) );
 
-		$this->post_count = count($this->posts);
+		$this->post_count = count( $this->posts );
 
 		// Always sanitize
 		foreach ( $this->posts as $i => $post ) {
@@ -2770,6 +2772,9 @@
 	function set_found_posts( $q, $limits ) {
 		global $wpdb;
 
+		if ( empty( $limits ) )
+			$this->found_rows = count( $this->posts );
+		
 		if ( $q['no_found_rows'] || empty( $limits ) )
 			return;
 
