The transaction log for the database "Name" is full. To find out why log space cannot be reused, see the log_reuse_wait_desc Column in sys.databases

I am getting the following error while I try to insert 8355447 records in one query.i insert using sql-server-2008-r2.

INSERT to table

select * from [DbName] .table

Please help me decide .... Thanks

+4
source share
3 answers

Check the disk space on SQL Server, as it usually happens when the transaction log cannot expand due to lack of free disk space.

, , TEMPDB.

+1

, . , - .

0

. - , Stackoverflow .

  • . , say 'n' no. , "n" ..
  • , .
  • , , .
  • , SQL TRUNCATE_ONLY ( , ).
    dbcc sqlperf ('logspace') .

    , : -  dbcc shrinkfile (, TRUNCATEONLY)

    DBCC Shrinkfile DBCC Shrinkfile.

  • If you do not get space even after this, you may need to carefully shrink it by redistributing the pages in the database (indicating the target size), details about this can be taken from the provided link.

0
source

Source: https://habr.com/ru/post/1530954/


All Articles