Encrypt Function code in SQL Server

Is it possible to Encrypt SQL Server 2005 Function.

I know you can Encrypt Stored Procedure using With Encryption

But how to do a table-valued fuctions.

Thanks for the help in advance
LVL 11
Guru JiAsked:
Who is Participating?
 
Lee SavidgeConnect With a Mentor Commented:
Yes. See snippet below.

Lee
create function myfunction()
returns @tablevar table (var1 int, var2 nvarchar(45))
with encryption
as
begin

--- your SQL here

Open in new window

0
 
Guru JiAuthor Commented:
Thanks
0
 
Lee SavidgeCommented:
Any time.

Lee
0
All Courses

From novice to tech pro — start learning today.