Does anyone know how to set the servername on a connection dynamically using a query or some other means? I would like the package to determine the servername in which the package resides and set the servername on the connection within the package accordingly.

The purpose is to alleviate the need to modify the servename on the package when I migrate it from the dev, test, and production environments. An ini file won't work because our dev and test environments are named instances on the same server. Based on what I know this would require me to change the ini files path in the package when I migrate between dev and test. Let me know if this is wrong.

Any help will be greatly appreciated.