Forum Replies Created

Viewing 15 posts - 4,666 through 4,680 (of 7,185 total)

  • RE: Change the port number for connections to SQL Server

    Kelsey Thornton (3/1/2012)


    Very well explained but missing one useful point:

    "Why would you want to change the port number in the first place?"

    (1) Security, to prevent attacks on the default port....

  • RE: database corruption

    I've seen backups succeed when the database has corruption in it. That's why it's important, periodically at least, to test that you can restore your databases and run DBCC...

  • RE: how to Eliminate 'IN'

    You could use an OUTER JOIN instead, although I suspect that you may end up with the same execution plan. Have you considered indexes on the srno column in...

  • RE: Large Update Statement - millions of rows

    Kwisatz78 (2/29/2012)


    Here is what I have altered it to:

    But your original post was about splitting the update into batches. Have you tried doing that?

    John

  • RE: Large Update Statement - millions of rows

    Matt Miller (#4) (2/29/2012)


    Correct, you do log everything, but the truncate happens immediately after commit in simple mode so small batches roughly means no log growth in that scenario.

    Actually, the...

  • RE: Large Update Statement - millions of rows

    You could do that, yes, but you're only explicitly doing something that would be implicitly done anyway. The original poster says that the whole thing is done in one...

  • RE: Is there something like sp_removerolemember ?

    (At least) two ways of working this out:

    (1) Use Profiler to run a trace while you use the GUI, so that you can find out what commands were executed in...

  • RE: How to get the list of jobs that are scheduled to run on a given date

    Since there is no question here, I'm guessing that you want someone to write the stored procedure for you? That's not generally the way it works. Please have...

  • RE: Large Update Statement - millions of rows

    Matt Miller (#4) (2/29/2012)


    The "no effect" is focusing on how much is logged. You're going to log all changes in full and bulk-logged, so it will not changed how...

  • RE: Large Update Statement - millions of rows

    Kwisatz78 (2/29/2012)


    The code isn't just one big update, it is several wrapped in a single transaction.

    If it's all one transaction, batching it will have no effect. The transaction will...

  • RE: Need hlep this linked server script

    Ananda

    Just as a matter of interest, why are you wrapping a SELECT statement in an explicit transaction?

    John

  • RE: Tsql grouping question

    It's best to let your presentation layer handle things like this. If you have to do it in the database layer, you can use FOR XML to concatenate the...

  • RE: sql backup floating error

    It's worth having a look in the default trace next time it fails to see whether the activity is recorded in there. Another thing that's worth doing is piping...

  • RE: sql backup floating error

    I've just tried your script, and it looks like I was wrong about not being able to use a variable in your BACKUP statement, so ignore that comment. I...

  • RE: sql backup floating error

    You can't use a parameter for the database name in a BACKUP statement. You need to use dynamic SQL instead, or find some other way of building your SQL...

Viewing 15 posts - 4,666 through 4,680 (of 7,185 total)