December 16, 2024 at 12:00 am
Comments posted to this topic are about the item The Random Rows
December 16, 2024 at 6:14 am
I have to disagree with the answer here. If you run the code more than once, it comes up with the same 10 rows. Therefor, they are NOT "random rows". 😉
--Jeff Moden
Change is inevitable... Change for the better is not.
December 16, 2024 at 9:19 am
"This table has the BusinessEntityID as the PK"
Well that would have been nice to know!
December 16, 2024 at 3:54 pm
It's the well known AdventureWorks database. All tables have PKs in there.
December 17, 2024 at 9:48 am
I too disagree with the answer, but for another reason:
Without a table definition, there is no way of knowing that the BusinessEntityID column is a primary key column (not everyone has a solid memory of all table definitions of the AdventureWorks database).
There really is no way to determine the values without this bit of information. Granted that assumptions can be made based on the term "ID" in the column name, but yeah... those are assumptions.
"My gosh! It's full of [SELECT] stars!"
December 17, 2024 at 5:37 pm
The question says AdventureWorks. This is a public schema.
Viewing 6 posts - 1 through 5 (of 5 total)
You must be logged in to reply to this topic. Login to reply