Click here to monitor SSC
SQLServerCentral is supported by Red Gate Software Ltd.
 
Log in  ::  Register  ::  Not logged in
 
 
 
        
Home       Members    Calendar    Who's On


Add to briefcase 123»»»

The Percent Sign in T-SQL Expand / Collapse
Author
Message
Posted Saturday, February 26, 2011 10:57 PM


Right there with Babe

Right there with BabeRight there with BabeRight there with BabeRight there with BabeRight there with BabeRight there with BabeRight there with BabeRight there with Babe

Group: General Forum Members
Last Login: Monday, July 14, 2014 10:08 AM
Points: 754, Visits: 3,816
Comments posted to this topic are about the item The Percent Sign in T-SQL

______________________________________________________________________
The greatest enemy of knowledge is not ignorance, it is the illusion of knowledge. - Stephen Hawking
Post #1070114
Posted Saturday, February 26, 2011 10:57 PM


SSCrazy

SSCrazySSCrazySSCrazySSCrazySSCrazySSCrazySSCrazySSCrazy

Group: General Forum Members
Last Login: Wednesday, August 27, 2014 5:52 PM
Points: 2,270, Visits: 3,789
Easy one

Mohammed Moinudheen
Post #1070115
Posted Sunday, February 27, 2011 11:46 PM
Ten Centuries

Ten CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen Centuries

Group: General Forum Members
Last Login: Tuesday, April 19, 2011 1:59 AM
Points: 1,042, Visits: 234
Thanks for easy question.
Post #1070337
Posted Monday, February 28, 2011 1:04 AM
SSC Eights!

SSC Eights!SSC Eights!SSC Eights!SSC Eights!SSC Eights!SSC Eights!SSC Eights!SSC Eights!

Group: General Forum Members
Last Login: Yesterday @ 5:25 AM
Points: 939, Visits: 885
easy one, thanks

Iulian
Post #1070352
Posted Monday, February 28, 2011 1:36 AM


SSChampion

SSChampionSSChampionSSChampionSSChampionSSChampionSSChampionSSChampionSSChampionSSChampionSSChampion

Group: General Forum Members
Last Login: Today @ 11:26 AM
Points: 13,622, Visits: 10,514
Nice and easy, good for a Monday morning. Thanks.



How to post forum questions.
Need an answer? No, you need a question.
What’s the deal with Excel & SSIS?

Member of LinkedIn. My blog at LessThanDot.

MCSA SQL Server 2012 - MCSE Business Intelligence
Post #1070361
Posted Monday, February 28, 2011 2:52 AM


Ten Centuries

Ten CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen Centuries

Group: General Forum Members
Last Login: Tuesday, August 27, 2013 4:28 AM
Points: 1,248, Visits: 779
Nice easy one to start of the week, cheers.

_____________________________________________________________________
"The difficult tasks we do immediately, the impossible takes a little longer"
Post #1070386
Posted Monday, February 28, 2011 4:05 AM
SSC Eights!

SSC Eights!SSC Eights!SSC Eights!SSC Eights!SSC Eights!SSC Eights!SSC Eights!SSC Eights!

Group: General Forum Members
Last Login: Monday, August 18, 2014 6:13 AM
Points: 984, Visits: 350
Thanks.

It would have been nice to have a shortcut for 0/0 (divide zero by zero) .
Post #1070408
Posted Monday, February 28, 2011 8:02 AM


Hall of Fame

Hall of FameHall of FameHall of FameHall of FameHall of FameHall of FameHall of FameHall of FameHall of Fame

Group: General Forum Members
Last Login: Friday, August 22, 2014 7:04 AM
Points: 3,675, Visits: 72,433
I got this right but...

SELECT 0%0

gives

Msg 8134, Level 16, State 1, Line 1
Divide by zero error encountered.


So it seems you can use it to divide 0 by 0 and get an error.




--Mark Tassin
MCITP - SQL Server DBA
Proud member of the Anti-RBAR alliance.
For help with Performance click this link
For tips on how to post your problems
Post #1070541
Posted Monday, February 28, 2011 8:41 AM
Ten Centuries

Ten CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen Centuries

Group: General Forum Members
Last Login: Today @ 3:42 PM
Points: 1,309, Visits: 1,685
mtassin (2/28/2011)
I got this right but...

SELECT 0%0

gives

Msg 8134, Level 16, State 1, Line 1
Divide by zero error encountered.


So it seems you can use it to divide 0 by 0 and get an error.




This makes sense, since a modulus can be defined as a product of division, you have to be able to do the division. Some systems, though, define x mod 0 as x (i.e, the difference between x and the nearest multiple of 0 [which is 0 (because 0 is the only multiple of 0.)])
Post #1070590
Posted Monday, February 28, 2011 9:05 AM
Ten Centuries

Ten CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen Centuries

Group: General Forum Members
Last Login: Thursday, January 31, 2013 8:01 AM
Points: 1,232, Visits: 1,046
So happy that over 80 percent of us know math.

Can you imagine how hard it would be a SQL developer or DBA if you didn't learn higher level math?
Post #1070608
« Prev Topic | Next Topic »

Add to briefcase 123»»»

Permissions Expand / Collapse