Ravi,
Majority of the cases, export declaration will be filed before the truck leaves the warehouse which means PGI has not been done yet and commercial Invoice will be generated only after PGI is complete.
Because of the above reason, Commercial Invoice will not be available at the time of filing export declaration and the possible option is to use proforma.
Regarding the configuration, yes you can choose whichever the invoice you want to use to create export declaration.
Also, for Brazil you need to have commercial invoice for filing export declaration.
Regards
Raj