how to used union for different filed in two select statement in drupal 7

$query1 = db_select('node', 'node');
            $query1->join('field_data_field_date_of_call', 'dateOfCall', 'dateOfCall.entity_id = node.nid');
            $query1->join('field_data_field_length_of_call', 'lengthCall', 'lengthCall.entity_id  = dateOfCall.entity_id');
            $query1->join('field_data_field_caller_s_first_name', 'caller', 'caller.entity_id  = lengthCall.entity_id');
            $query1->fields('node',array('nid','uid','type'))
                  ->fields('dateOfCall',array('field_date_of_call_value'))
                  ->fields('lengthCall',array('field_length_of_call_value'))
                  ->fields('caller',array('field_caller_s_first_name_value'));
            $query1->addExpression('null','field_schedule_slot_value');
            $query1->addExpression('null','field_schedule_slot_value2');     
            $query2 = db_select('node', 'node');
            $query2->join('field_data_field_schedule_slot', 'slot', 'slot.entity_id = node.nid');
            $query2->fields('node',array('nid','uid','type'))
                   ->fields('slot',array('field_schedule_slot_value' , 'field_schedule_slot_value2' ));
            $query2->addExpression('null','caller');
            $query2->addExpression('null','field_date_of_call_value');
            $query2->addExpression('null','field_length_of_call_value');
            $query1->union($query2, 'UNION');
            $result = $query1->execute();
used addexpression for specifying null value for any field
Comments