Created
November 23, 2020 14:10
-
-
Save MarshalOfficial/5b901431aa129d9b2c59ef89f3fde673 to your computer and use it in GitHub Desktop.
call table value function with base table select statement
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| --The APPLY operator should do the trick: | |
| SELECT * | |
| from MarketDataMaster | |
| cross apply dbo.fn_MarketDataDetails (MarketDataMasterID) | |
| --This essentially calls the function once per row returned from MarketDataMaster. "cross apply" works like an inner join, in that only rows for which data is returned by the function will be returned; use "outer apply" for functionality similar to left outer joins. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment