problem with drupal_http_build_query output am using drupal_http_build_query and have part of my code as follows:

$or = db_or();
$or-&gt;condition('cid',$fField1);
$or-&gt;condition('cid',$fField2);
$or-&gt;condition('cid',$fField3);
$or-&gt;condition('cid',$fField4);
$or-&gt;condition('cid',$fField5);
$or-&gt;condition('cid',$fField6);
$or-&gt;condition('cid',$fField7);
$or-&gt;condition('cid',$fField8);

$querydata  = db_select('webform_submitted_data', 'wsd')
  -&gt;fields('wsd',array('data'))
  -&gt;condition('nid', $nodeID, '=')
  -&gt;condition('sid', $sID, '=')         
  -&gt;condition($or)
  -&gt;execute()
  -&gt;fetchAll();


$result = array();
$i = 1;
foreach ($querydata as $qvalue) {
    $key = 'mapField'.$i;
    $result[] = array($$key =&gt; $qvalue-&gt;data);
    $i++;
}

$post_data = drupal_http_build_query($result,'', '&amp;');


When printing the $post_data variable value, am getting something like this:
name=john&amp;1[address]=street1&amp;2[phone]=123456789

Notice the 1[] and 2[] after the &amp;in the printed value. Any fix to remove these so that I get name=john&amp;address=street1&amp;phone=123456789?
You are getting that result because you build $result as an array whose values are array. Since drupal_http_build_query() contains the following code, the result you obtain is by design.

  foreach ($query as $key =&gt; $value) {
    $key = ($parent ? $parent . '[' . rawurlencode($key) . ']' : rawurlencode($key));

    // Recurse into children.
    if (is_array($value)) {
      $params [] = drupal_http_build_query($value, $key);
    }
    // If a query parameter value is NULL, only append its key.
    elseif (!isset($value)) {
      $params [] = $key;
    }
    else {
      // For better readability of paths in query strings, we decode slashes.
      $params [] = $key . '=' . str_replace('%2F', '/', rawurlencode($value));
    }
  }


You should change the code to the following one.

foreach ($querydata as $qvalue) {
  $key = 'mapField' . $i;
    $result[$$key] = $qvalue-&gt;data;
    $i++;
}