Last active
May 19, 2019 22:36
-
-
Save ArCiGo/0e5ba92fba7b37eeaaf6bb611602e7e9 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
DECLARE @myDecimalValue FLOAT | |
SET @myDecimalValue = 3.1415 | |
SELECT CAST(@myDecimalValue AS INT); | |
GO | |
/** Output **/ | |
----------- | |
3 | |
DECLARE @myDecimalValue FLOAT | |
SET @myDecimalValue = 4521312.531 | |
SELECT CONVERT(INT, @myDecimalValue); | |
GO | |
/** Output **/ | |
----------- | |
4521312 | |
SELECT TOP 5 * | |
FROM Customer; | |
GO | |
/** Output **/ | |
Id FirstName LastName City Country Phone | |
----------- ---------------------------------------- ---------------------------------------- ---------------------------------------- ---------------------------------------- -------------------- | |
1 Maria Anders Berlin Germany 030-0074321 | |
2 Ana Trujillo México D.F. Mexico (5) 555-4729 | |
3 Antonio Moreno México D.F. Mexico (5) 555-3932 | |
4 Thomas Hardy London UK (171) 555-7788 | |
5 Christina Berglund Luleå Sweden 0921-12 34 65 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment