Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
Author |
Topic |
MelissaTsalicoglou
Starting Member
16 Posts |
Posted - 2014-06-05 : 05:17:29
|
Hi All Can someone please explain to me what the % 4 +1 means?I cant understand that a custid would have a % in it ? Please help me understandSELECT CHOOSE(custid % 4 + 1, N'Group One', N'Group Two', N'Group Three', N'Group Four') AS segmentgroup, custid, contactnameFROM Sales.Customers; |
|
webfred
Master Smack Fu Yak Hacker
8781 Posts |
Posted - 2014-06-05 : 05:48:14
|
% = modulo Too old to Rock'n'Roll too young to die. |
|
|
|
|
|