views:

122

answers:

2

can we use packages in ms sql server 2008...i m new to sql server ... if yes how it can be created and used....

A: 

I assume you are talking about the Oracle concept of a package which groups related queries etc. If so as far as I know this concept doesn't exit in SQL Server. Also you will get some interference when trying to Google for this from DTS packages, which are a completely different concept.

Tetraneutron
yup m taking abt oracle concept...is there any alternate sollution...
hrishi
That depends on what you are trying to get from them, if you are just wanting to tidy up your project and group like things then not really - if you are trying to manage permissions then yes - roles. Tell us what you are trying to achieve and I'm sure you will get many replies as to how its achieved in SQL Server.
Tetraneutron
+1  A: 

The only thing somewhat similar would be a SQL-CLR assembly, e.g. C# code compiled into an assembly, hosted inside SQL.

There's no equivalent of a package for T-SQL stored functions and stored procedures in SQL Server.

What do you need that for, anyway? Granting permissions?

What you could investigate, too, are the schemas in SQL Server, which also help you grant or manage permissions - but it's quite a different beast from Oracle PL/SQL packages. Schemas manage collections of database objects (any of them - tables, views, stored procs and funcs).

Marc

marc_s