Quantcast
Channel: Forum SQL Server Database Engine
Viewing all articles
Browse latest Browse all 15889

An error occurred while executing batch. Error message is: Exception of type 'System.OutOfMemoryException' was thrown.

$
0
0
I am getting this error repeatedly on SQL Server 2008 on Windows machine when i run a simple query which involves close to ~ 10 million records.
select sum(a.test) from (select COUNT(*) as test from xf.dbo.sec_mthprc s1 group by gvkey, datadate) a

Technical Data:
   Sql Server 2008 : 2009-07-29 03:13:16.280 Server       Microsoft SQL Server 2008 (SP1) - 10.0.2531.0 (X64)
                             Mar 29 2009 10:11:52
                             Copyright (c) 1988-2008 Microsoft Corporation
                             Developer Edition (64-bit) on Windows NT 6.0 <X64> (Build 6001: Service Pack 1)
   Microsoft Windows 2008 Standard Edition x64 with 16 GB RAM and 2 quad-core processors


Viewing all articles
Browse latest Browse all 15889

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>