Are you using BI Publisher? If so, forget about doing this inside of it. To accomplish this, the easiest way I know would be to create a web-service that will do the job, and load your that in the publisher from that WebService. You can also struggle with DataTemplate, but I don't think it can be done.