Re: 2 Billion records a table



Hello David,

That's really strange. Have you let it generate the execution plan or
does it fallover?

Sometimes with large tables it takes along time to generate a plan.
Rather than using query analyzer to generate the plan try the text
version.

Try the query below:


SET SHOWPLAN_TEXT ON
GO
SELECT COUNT_BIG(1) FROM dbo.SalesOrderDetail WITH (NOLOCK)
GO
SET SHOWPLAN_TEXT OFF


The big count returns as a Big INT instead of INT. This may help your
row count if the number of row exceeds the INT range.


Hope this helps

Myles Matheson
Data Warehouse Architect

.



Relevant Pages

  • Re: Rookie Student C++ Array question (reading from a file)
    ... >Start by writing down in plain english words what needs to be done. ... >int main ... >That's your overall plan. ... at the previous suggestion of mapping, ...
    (alt.comp.lang.learn.c-cpp)
  • Re: Rookie Student C++ Array question (reading from a file)
    ... >Start by writing down in plain english words what needs to be done. ... >int main ... >That's your overall plan. ... >do the additions inline in your real source code) ...
    (alt.comp.lang.learn.c-cpp)
  • Re: crosstab problem, invalid name
    ... Plan is a reserved word and therefore a poor choice for a column name (see ... > letter "o" appears after my source qryPlanByTerritory. ... >>> says "Invalid column name Territory". ... >>> M1 int NULL, ...
    (microsoft.public.sqlserver.programming)
  • Re: crosstab problem, invalid name
    ... (BTW, if you used Query Analyzer to develop your code, you would see "Plan" ... > letter "o" appears after my source qryPlanByTerritory. ... >>> says "Invalid column name Territory". ... >>> M1 int NULL, ...
    (microsoft.public.sqlserver.programming)
  • Re: crosstab problem, invalid name
    ... letter "o" appears after my source qryPlanByTerritory. ... you see anything around the keyword "Plan" in the looping ... >> M1 int NULL, ... >> SELECT DISTINCT Territory ...
    (microsoft.public.sqlserver.programming)

Loading