select top results without selecting columns

Jonathan Brotto 180 Reputation points
2024-06-04T15:25:35.46+00:00

select top results without selecting columns?

SQL Server
SQL Server
A family of Microsoft relational database management and analysis systems for e-commerce, line-of-business, and data warehousing solutions.
13,210 questions
Transact-SQL
Transact-SQL
A Microsoft extension to the ANSI SQL language that includes procedural programming, local variables, and various support functions.
4,592 questions
0 comments No comments
{count} votes

Accepted answer
  1. Olaf Helper 42,761 Reputation points
    2024-06-04T17:44:34.7866667+00:00

    What's the problem with?

    SELECT TOP (100) * FROM dbo.YourTable
    

    Without a ORDER BY clause on an explicit named column you will get a more random result.

    1 person found this answer helpful.
    0 comments No comments

0 additional answers

Sort by: Most helpful