Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

Dow can i delete records without creating a entry in transaction log

Posted on 2004-09-17
7
Medium Priority
?
298 Views
Last Modified: 2010-08-05
I have a DB server which is almost out of space and i need to delete some data / rows in a large table to make space.
my problem is that when i try to delete the row the system is trying to write to the translog but there is no more space to grow it.

is there a way to temp disable any logging while i delete the records ? Or any othere way to make this happen ?
0
Comment
Question by:AlexPonnath
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
7 Comments
 
LVL 10

Accepted Solution

by:
Jay Toops earned 900 total points
ID: 12085628
change your logmode to simple
THEN ..
if it still wont do that transaction
you will have to delete a FEW records at a time like
delete from MYTABLE where id > 1 and id < 1000

OR

simply add annother LOGFILE in the database setup
you could EVEN use a network drive if your desperate..
of course this will be VERY slow

JAY
0
 
LVL 10

Expert Comment

by:imrancs
ID: 12085754
if you are deleting all the record from the table then you have another option; you can use TRUNCATE TABLE <tablName>. TRUNCATE is not a logged operation.


Imran
0
 
LVL 43

Expert Comment

by:Eugene Z
ID: 12086737
TRUNCATE table as imrancs  told is the answer
additionally if it is sql server 2000
you cab try to chenge recovery mode to simple recovery mode

 simple recovery mode does is, it truncates the log
each time SQL Server performs a checkpoint

0
Will your db performance match your db growth?

In Percona’s white paper “Performance at Scale: Keeping Your Database on Its Toes,” we take a high-level approach to what you need to think about when planning for database scalability.

 

Author Comment

by:AlexPonnath
ID: 12086972
that does not help, i can not dump the whole table and and doing simple has no impact, when i delete more then 200 K rows it fails becaus
of log is full....
0
 
LVL 10

Expert Comment

by:Jay Toops
ID: 12087033
THEN ..
if it still wont do that transaction
you will have to delete a FEW records at a time like
delete from MYTABLE where id > 1 and id < 1000
or by some other column that you can slice the table up into pieces with

JAY
0
 
LVL 6

Assisted Solution

by:mcp111
mcp111 earned 600 total points
ID: 12087077
You could also try dbcc shrinkdatabase
0
 
LVL 10

Expert Comment

by:Jay Toops
ID: 12108706
did this work .. ??

did u get to try it?

JAY
0

Featured Post

Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Why is this different from all of the other step by step guides?  Because I make a living as a DBA and not as a writer and I lived through this experience. Defining the name: When I talk to people they say different names on this subject stuff l…
A Stored Procedure in Microsoft SQL Server is a powerful feature that it can be used to execute the Data Manipulation Language (DML) or Data Definition Language (DDL). Depending on business requirements, a single Stored Procedure can return differe…
This video shows how to set up a shell script to accept a positional parameter when called, pass that to a SQL script, accept the output from the statement back and then manipulate it in the Shell.
Via a live example, show how to extract insert data into a SQL Server database table using the Import/Export option and Bulk Insert.

688 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question