If you are upgrading from BizTalk 2006 to BizTalk 2006 R2, make sure that the SQL Adapter is using the Default Host Instance (normally BizTalkServerApplication) before enabling the EDI functionality in the BizTalk configuration.
If you have created a seperate host instance for SQL, you will recieve the following error: Invalid Receive Handler error when configuring BizTalk EDI/AS2 Runtime in BizTalk Server 2006 Configuration
Once you have re assigned the SQL adapter to the default, it will configure propertly, and you can re assign it after the configuration completes.