You are here: Re: using a stored procedure as a sub query « MsSQL Server « IT news, forums, messages
Re: using a stored procedure as a sub query

Posted by Erland Sommarskog on 10/01/18 11:19

pb648174 (google@webpaul.net) writes:
> Is there any way to do the following?
>
> select Max(FieldOne) From (
> spGetSomeData 100,'test' )
>
> Or do I need to define a view and have the stored proc use that view?
> The stored proc does some things with temp tables that would be
> difficult to replicate with a view which is why I'm asking.

Have a look at http://www.sommarskog.se/share_data.html for some ideas.


--
Erland Sommarskog, SQL Server MVP, esquel@sommarskog.se

Books Online for SQL Server SP3 at
http://www.microsoft.com/sql/techinfo/productdoc/2000/books.asp

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация