Form API select list remove blank entry (default select an entry) I populate an select list using the following code.

$getCompanies = 'SELECT nid, title FROM node where type = "my_type"';
        $companiesResult = db_query($getCompanies);
        $companyArray = array();
        $companyArray['empty'] = "";
        while ($data = db_fetch_object($companiesResult)) {
            $companyArray[$data-&gt;nid] = $data-&gt;title;
        }
        $form['company'] = array(
            '#title' =&gt; t('Type'),
            '#type' =&gt; 'select',
            '#description' =&gt; t(''),
            '#options' =&gt; $companyArray,
        );
    }


This gives me an empty result first. I want to remove this empty result. I tried adding #required by it does not add a default selection. What can I do to remove an empty element?
The blank option was added by yourself:

$companyArray['empty'] = "";


If you remove that line you wont have a blank line, or alternatively your could change it to

$companyArray['empty'] = t("Please select");


To make the phrase Please select appear as default in the select option.