FUNCTION  fDMSbase

Base function to convert declination in degrees to +dd:mm:ss.ss notation.

SDSS SkyServer function, courtesy Johns Hopkins University.
@truncate is 0 (default) if decimal digits to be rounded, 1 to be truncated.
@precision is the number of decimal digits, default 2.
Example usages:

SELECT dbo.fDMSbase(87.56789,1,4)
=> +87:34:04.4040

SELECT dbo.fDMSbase(87.56789,default,default)
=> +87:34:04.40

NameTypeLengthinoutpnum
@degfloat8input1
@truncateint4input2
@precisionint4input3
 varchar32output1