You mean dependent drop down.
see the FormWidgetExampleForms.xml
<field name="emptyField2" title="${uiLabelMap.CommonEmptyHeader}"><display/></field>
<field name="dependendDropDownFields" title="${uiLabelMap.ExampleDependentDropDowns}">
<display description="${uiLabelMap.ExampleDependentDropDownTooltip}"/>
</field>
<field name="stateProvinceGeoId" title="${uiLabelMap.CommonState}" widget-style="required"><drop-down allow-empty="false"/></field>
<field name="countryGeoId" title="${uiLabelMap.CommonCountry}" tooltip="${uiLabelMap.CommonRequired}" widget-style="required">
<drop-down no-current-selected-key="USA">
<entity-options entity-name="Geo" key-field-name="geoId" description="${geoName}">
<entity-constraint name="geoTypeId" value="COUNTRY"/>
<entity-order-by field-name="geoName"/>
</entity-options>
</drop-down>
</field>
See this link for example
https://demo-trunk.ofbiz.apache.org:8443/exampleext/control/FormWidgetExamples