ACCRINTM
Updated 2023-10-06 11:45:58.967000
Syntax
SELECT [westclintech].[wct].[ACCRINTM] (
<@Issue, datetime,>
,<@Settlement, datetime,>
,<@Rate, float,>
,<@Par, float,>
,<@Basis, nvarchar(4000),>)
Description
Use the scalar function ACCRINTM to calculate the accrued interest for a security that pays interest at maturity.
Arguments
@Basis
is the type of day count to use. @Basis is an expression of the character string data type category.
{"columns":[{"field":"Basis","width":139},{"field":"Day count basis","width":174}],"rows":[{"Basis":"0 or omitted","Day count basis":"US (NASD) 30/360"},{"Basis":"1","Day count basis":"Actual/Actual"},{"Basis":"2","Day count basis":"Actual/360"},{"Basis":"3","Day count basis":"Actual/365"},{"Basis":"4","Day count basis":"European 30/360"}]}
@Rate
the coupon rate of the security expressed in decimal terms. @Rate is an expression of type float or of a type that can be implicitly converted to float.
@Issue
the issue date of the security. @Issue is an expression that returns a datetime or smalldatetime value, or a character string in date format.
@Par
the par value of the security. @Par is an expression of type float or of a type that can be implicitly converted to float.
@Settlement
the settlement date occurring within the coupon period of the security. @Settlement is an expression that returns a datetime or smalldatetime value, or a character string in date format.
Return Type
Remarks
If @Basis < 0 or @Basis > 4, ACCRINTM returns an error.
Examples
SELECT wct.ACCRINTM('04/01/2008', '06/15/2008', .1, 1000, 3);
Here is the result set
{"columns":[{"field":"column 1","headerClass":"ag-right-aligned-header","cellClass":"ag-right-aligned-cell"}],"rows":[{"column 1":"20.5479452054795"}]}
See Also
ACCRINT - Calculate the accrued interest for a security that pays periodic interest.
AIFACTOR - Calculate the Accrued Interest Factor
AIFACTOR_IAM - Calculate the Accrued Interest Factor for an Interest-at-Maturity security
AIFACTOR_OFC - Calculate the Accrued Interest Factor for a bond during its odd first coupon period
AIFACTOR_OLC - Calculate the Accrued Interest Factor for a bond during its odd last coupon period
AIFACTOR_RPI - Calculate the Accrued Interest Factor for a Regular Periodic Interest period
BONDINT - Accrued interest on a bond paying regular, periodic interest
ODDFINT - Accrued interest for a bond with an odd first coupon
ODDLINT - Accrued interest for a bond with an odd last coupon