Showing posts with label Microsoft SQL Server 2008. Show all posts
Showing posts with label Microsoft SQL Server 2008. Show all posts

Monday, 12 May 2014

Calling MS SQL Server user defined functions with default parameters

User Defined Function Call:

SELECT *
FROM udf_TestDef(1, DEFAULT)

Yes!! You have to insert the term default literary!

User Defined Function Sample:

CREATE FUNCTION [dbo].[udf_TestDef]
(
@Param INTEGER
@IsBigContainerPhoto BIT = 0
)
RETURNS TABLE
AS
RETURN
(
.
.
.

Thursday, 3 October 2013

Understanding Microsoft SQL Server permissions

Below is a very good article about the permissions check order. Also explains chaining; when an object accesses another object.

http://technet.microsoft.com/en-us/library/dd283095(v=sql.100).aspx
Although the article was for SQL Server 2008, most concepts are still valid for 2012 version.