Hi Friends,
Can you just tell me that Can we use procedures within Views? Can you just tell me as soon as possible
Printable View
Hi Friends,
Can you just tell me that Can we use procedures within Views? Can you just tell me as soon as possible
ya we can use view in procedures
I know that I am replying after two weeks. If you have not find answer till now then this may help you.
You can use procedures with in view definitions.
Views are simply pre-defined SELECT statements against tables in your data model. They are primarily used for simplification of data presentation and to secure your data by only exposing those columns the user needs to see. Views do not store any data (the exception is Indexed Views, which do) but are treated by SQL Server like actual tables
so, i dont thik so....it possible
procedures can't be used with in view definitions.
You can use functions if you want.
[QUOTE=Subashini.Ramasamy;13009]Hi Friends,
no we cant use
we can't use a procedure within a view ....view can be used within a procedure...
Yes you can call a procedure inside a view by following the scenario.
create a procedure or function which would return a ref cursor as an out parameter.
if the name of the procedure is xyz
then create a view with the select statement as
select * from table(xyz)