How do you remotely execute a table valued function in Sql-Server 2000/5?
I have a stored procedure (sql2005) that needs to call a table valued function on a remote server (sql2000).
My query is as follows:
select * from mytable mt cross apply opendatasource('sqloledb','Data Source=remoteserver;UID=user;Password=pass').mydatabase.dbo.mytvf (cast(param1 as numeric(20,0)), @param2, mt.param3)
I’m getting an incorrect syntax error near ‘cast’. Is it possible to execute a tvf with this notation? Should I somehow be using openrowset? Any help is appreciated.
One Solution collect form web for “How do you remotely execute a table valued function in Sql-Server 2000/5?”
Here’s the official word. You cannot call a UDF in this way.
Looks like Mircosoft is working on the ability in a future version though.