SQL ASIN Function

The SQL Server ASIN is one of the Mathematical functions used to calculate the trigonometry Arc sine for the specified expression. An Arc sine is also called the inverse of a SINE Function. The syntax of the ASIN Function is:

SELECT ASIN (Float_Expression)
FROM [Source]

TIP: The SQL ASIN function only accepts float values between -1 and 1. For this demo, we use the Math Table data.

Source Table

SQL ASIN Function Example

The ASIN function calculates the Arc SINE for a given angle. The following query will show multiple ways to use the ASIN function.

We used this SQL Serve function to calculate the Arc sine value for the variable @i. It means ASIN(-0.80) and assigned a new name as ‘Arc Sine’ using ALIAS.

DECLARE @i Float
SET @i = -0.80

SELECT ASIN(@i)AS [Arc Sine]

-- Calculating directly
SELECT ASIN(0.27)AS [Arc Sine]

-- Calculating directly
SELECT ASIN(0.25 + 0.55 - 0.77)AS [Arc Sine]
SQL Server ASIN Function or Arc SINE Example 1

Here, we will calculate the Arcsine value for all the records present in [Service Grade] using the ASIN Mathematical Function.

SELECT [EnglishProductName]
      ,[Service Grade] AS Grade
      ,ASIN([Service Grade]) AS [Arc Sine] 
  FROM [Mathemetical Functions]

About Suresh

Suresh is the founder of TutorialGateway and a freelance software developer. He specialized in Designing and Developing Windows and Web applications. The experience he gained in Programming and BI integration, and reporting tools translates into this blog. You can find him on Facebook or Twitter.