Quantcast
Channel: SQLServerCentral » SQL Server 2014 » Development - SQL Server 2014 » Latest topics
Viewing all articles
Browse latest Browse all 3145

TempDB

$
0
0
Hi,I am running an INSERT statement (the table is built with 1 billion records). The problem is the TempDB grows to over 600 GB and fills the disk prior to completion of the query executing.I checked the tempDB and details as follows ;[code]Recovery model: SimpleLogic Name: tempdevInitial size: 8MBAutogrowth: By 10 percent, unrestricted growthLogic Name: templogInitial size: 1MBAutogrowth: By 10 percent, unrestricted growth[/code]Please advise if I need to do anything to control the size of the tempDB from growing out of control and utilising the entire disk space..[code]INSERT INTO dbo.EmisEvent (EventGuidDigest,PatientID,ConsultationID,StaffID,EventDate,EventType,MedicalCodeID,Value,Unit,Abnormal) SELECT EventGuidDigest,PatientID,ConsultationID,StaffID,EventDate,EventType,MedicalCodeID,Value,Unit,Abnormal FROM dbo.EmisEventExtraction WITH (tablock)[/code]Can I do the insertion in batches and how can I change the INSERT statement....Thanks

Viewing all articles
Browse latest Browse all 3145

Trending Articles