Check out example codes for "call function in query sql server". It will help you in understanding the concepts better.

Code Example 1

SELECT dbo.GetBusinessDays(a.opendate,a.closedate) as BusinessDays
FROM account a
WHERE...

Learn ReactJs, React Native from akashmittal.com