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 |
|
Eagle_f90
Constraint Violating Yak Guru
424 Posts |
Posted - 2002-04-23 : 07:54:17
|
| Is there a way I can set a column to have data that is different depending on a random number? Like have it says "today is odd" if the a random number 1-10 is odd, but if it is even the column says "today is even". Thanks for the help. |
|
|
Page47
Master Smack Fu Yak Hacker
2878 Posts |
Posted - 2002-04-23 : 09:06:16
|
| There is tons of info on random numbers here and by searching the forums.<O> |
 |
|
|
AjarnMark
SQL Slashing Gunting Master
3246 Posts |
Posted - 2002-04-23 : 17:52:59
|
| And the way to have the value in the column change on the fly is by defining it as a computed column. See BOL for more details.If, instead, you just want to set it to some value once and leave it that way, then you could put the randomizer logic in a trigger.Edited by - AjarnMark on 04/23/2002 17:54:04 |
 |
|
|
|
|
|