Collections:
Exact Numeric Literals in SQL Server Transact-SQL
What are exact numeric literals supported in SQL Server Transact-SQL?
✍: FYIcenter.com
Exact numeric literals in Transact-SQL are numbers written in
standard signed decimal formats.
Exact numeric literals are used to provide values to exact numeric variables or table columns like INTEGER, DECIMAL(8,2), MONEY, etc.
Exact numeric literals are also used in exact numeric operations in expressions and exact numeric arguments in functions.
Here are some simple rules on how to write string literals:
Here are some example on how to write exact numeric literals:
-- Identical exact numeric literals PRINT 9; PRINT 9.; -- Identical exact numeric literals PRINT 9.0; PRINT +9.0; PRINT 09.0; -- Different exact numeric literals PRINT 9; PRINT 9.0; PRINT 9.00; -- Exact numeric literals in operation PRINT 1.0/3;
2017-05-05, 1015👍, 0💬
Popular Posts:
How do you know if SQL Server is running on your local system in SQL Server? After installing SQL Se...
How To Create a Dynamic Cursor with the DYNAMIC Option in SQL Server Transact-SQL? If the underlying...
How To Replace NULL Values in Expressions using ISNULL() in SQL Server Transact-SQL? As you learned ...
Where to find MySQL database server tutorials? Here is a collection of tutorials, tips and FAQs for ...
Can You Create a View with Data from Multiple Tables in SQL Server? Can You Create a View with Data ...