Sunday, February 28, 2010

Login failed for user 'Domain\UserName'. [CLIENT: IP address] with SharePoint Farm | Deleting SSP Shared Service Provider

Of course when you get this error in SQL server, you thought that there is a process which is trying to connect with SQL Server with wrong user name or password. But with SharePoint Environment and when you delete SSP and its associated database, you will get this error and the reason is: when you delete SSP, SharePoint does not delete the JOB which is responsible for deleting expired sessions so this job is working each minutes and try to connect to SSP database, therefore you should delete this job manually after deleting SSP.

Tuesday, February 23, 2010

How to delete or truncate large table

In this post I’ll explain how to empty large table. One of our customers had a table with 450GB of size. And we tried all ways to empty this table, but no one has solved the problem.

We tried to truncate the table, but truncate operation took more than 10 hours and didn’t solve the problem. And when we used WHERE statement in any query on this table, SQL server executes the query without stopping.

The only way that I could to empty the table in 1 second was as the following:

set rowcount 1;

truncate table TABLE_NAME;

And of course after truncating the table, just go and shrink the database.