Unable to delete SQL records

Please support our MS SQL advertiser: Intel Parallel Studio Home
Reply

Join Date: Mar 2006
Posts: 6
Reputation: JohnC is an unknown quantity at this point 
Solved Threads: 0
JohnC JohnC is offline Offline
Newbie Poster

Unable to delete SQL records

 
0
  #1
Mar 27th, 2006
Hello,

I'm pretty much a newbie with SQL. I have a database that is growing out of control and I'm unable to delete any records (data) from it. I've tried numerous open source applications but nothing has worked. The database is with a hosting and they provide ASP.NET Enterprise Manager. I also have Table Editor 0.81 Beta loaded on the host. I can get any program/app to connect to the database, and I can see all the tables and data, but I'm unable to delete old records. There are 2 years of old data that I need to delete. And my hosting company is screaming at me to make the database smaller. It is currently around 650MB.

Can anyone PLEASE offer some assistance to a SQL newbie, pretty please??
Reply With Quote Quick reply to this message  
Join Date: Jul 2005
Posts: 483
Reputation: campkev is an unknown quantity at this point 
Solved Threads: 19
campkev campkev is offline Offline
Posting Pro in Training

Re: Unable to delete SQL records

 
0
  #2
Mar 27th, 2006
need more info. what have you tried? what error messages/symptoms do you get when you try it?
Reply With Quote Quick reply to this message  
Join Date: Mar 2006
Posts: 6
Reputation: JohnC is an unknown quantity at this point 
Solved Threads: 0
JohnC JohnC is offline Offline
Newbie Poster

Re: Unable to delete SQL records

 
0
  #3
Mar 27th, 2006
Thanks for your response, campkev. I'm not sure I understand what you mean by "what have you tried." Applications or commands? I am trying to query a particular table that is logging impressions on banners. I have tried the following:

DELETE FROM usd_ImpressionDetails
WHERE bannerID = 13;

Where "usd_ImpressionDetails" is the table and "bannerID = 13" is just one of the many rows I need to delete. I have a half a dozen application that allow a query to the database and they all produce the same results, which is nothing.

I recently researched if perhaps the database had some kind of lock or permission limits and I was able to turn on "autoshrink" in hopes to reduce the size, but I think I need to wait until the SQL server resets or something. I also ran "dbcc shrinkdatabase bannerdb" but I'm still seeing the same size mdf and ldf files when I run "sp_helpdb bannerdb."

I'm at a complete loss here...
Reply With Quote Quick reply to this message  
Join Date: Jul 2005
Posts: 483
Reputation: campkev is an unknown quantity at this point 
Solved Threads: 19
campkev campkev is offline Offline
Posting Pro in Training

Re: Unable to delete SQL records

 
0
  #4
Mar 27th, 2006
if you are executing your delete query from an application, does whatever login the application is using have delete privileges on the databases and tables you are trying to delete from? Are you getting an error when you run that query or just "0 rows affected"?
Reply With Quote Quick reply to this message  
Join Date: Mar 2006
Posts: 6
Reputation: JohnC is an unknown quantity at this point 
Solved Threads: 0
JohnC JohnC is offline Offline
Newbie Poster

Re: Unable to delete SQL records

 
0
  #5
Mar 28th, 2006
I'm not quite sure... when I go to Users, the user that I'm using, these two items are checked: public and db_owner. Then when I go further to Permissions, nothing at all is checked. I tried checking Delete from the column for the particular table that I'm trying to delete data from but when I click save and go back, it doesn't look like it's saved because there's no check marks again. I'm doing all of this with ASP.NET Enterprise Manager. I hope I'm explaining it to where it's making some sense.
Reply With Quote Quick reply to this message  
Join Date: Mar 2006
Posts: 6
Reputation: JohnC is an unknown quantity at this point 
Solved Threads: 0
JohnC JohnC is offline Offline
Newbie Poster

Re: Unable to delete SQL records

 
0
  #6
Mar 28th, 2006
P.S. I'm not getting any error messages.
Reply With Quote Quick reply to this message  
Join Date: Mar 2006
Posts: 6
Reputation: JohnC is an unknown quantity at this point 
Solved Threads: 0
JohnC JohnC is offline Offline
Newbie Poster

Re: Unable to delete SQL records

 
0
  #7
Apr 1st, 2006
Can't help?
Reply With Quote Quick reply to this message  
Join Date: Jul 2005
Posts: 483
Reputation: campkev is an unknown quantity at this point 
Solved Threads: 19
campkev campkev is offline Offline
Posting Pro in Training

Re: Unable to delete SQL records

 
0
  #8
Apr 1st, 2006
this is sql server?
Reply With Quote Quick reply to this message  
Join Date: Mar 2006
Posts: 6
Reputation: JohnC is an unknown quantity at this point 
Solved Threads: 0
JohnC JohnC is offline Offline
Newbie Poster

Re: Unable to delete SQL records

 
0
  #9
Apr 2nd, 2006
Of course.
Reply With Quote Quick reply to this message  
Join Date: Jul 2005
Posts: 483
Reputation: campkev is an unknown quantity at this point 
Solved Threads: 19
campkev campkev is offline Offline
Posting Pro in Training

Re: Unable to delete SQL records

 
0
  #10
Apr 2nd, 2006
I don't know what to tell you if you aren't getting any error messages. I've never used .Net Enterprise Manager, so can't give you specifics. Can you update information in those rows? BannerId is an int, right?
Reply With Quote Quick reply to this message  
Reply

This thread is more than three months old.
Perhaps start a new thread instead?
Message:



Other Threads in the MS SQL Forum
Thread Tools Search this Thread



About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC