Archives of the TeradataForum
Message Posted: Mon, 21 Apr 2003 @ 16:56:02 GMT
Subj: | | Re: Select * from mytable |
|
From: | | Dieter N�th |
Anomy Anom wrote:
| MyTable has tens of millions of rows. | |
| The astute user wants to look at the first 2000 rows so they enter: | |
There are no _first_ rows in a relational table (without Order By).
| lock MyTable for access
Select * from MyTable; | |
| Explain says the query will use an all amps retrieve. Why do the nodes take over 2 minutes to start returning rows when there is no
one on the system? Based on experience with other database systems I expect the system to start returning rows. | |
Teradata first spools _all_ rows and then starts returning data.
Why don't you use a
Select * from MyTable sample 2000;
This will return 2000 random rows.
Dieter
|