Forum Replies Created

Viewing 15 posts - 17,791 through 17,805 (of 49,552 total)

  • RE: declare variable

    surma.sql (7/5/2012)


    s.vcDisplaySchoolName = '@vcDisplaySchoolName'

    By wrapping that in quotes you're asking for rows that have a school name of "@vcDisplaySchoolName", not the value of the variable. Lose the quotes

    Gail Shaw
    Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
    SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability

    We walk in the dark places no others will enter
    We stand on the bridge and no one may pass
  • RE: declare variable

    surma.sql (7/5/2012)


    hello

    i have trouble to declare a variable. i try to declare string variable but it gives me null value

    declare @vcDisplaySchoolName varchar

    No length on the varchar means that's a varchar(1)....

    Gail Shaw
    Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
    SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability

    We walk in the dark places no others will enter
    We stand on the bridge and no one may pass
  • RE: Database upgrade / restore

    Rem70Rem (7/5/2012)


    I see. For the log, the best is to keep only 1 file, even if it's a 30+GB file?

    Sure. I've had 200GB+ log files before. There's no performance...

    Gail Shaw
    Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
    SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability

    We walk in the dark places no others will enter
    We stand on the bridge and no one may pass
  • RE: Database upgrade / restore

    Rem70Rem (7/5/2012)


    As of now, we have a log file of 30GB. I was thinking of creating 3 of 10GB, for better performance. This is not a good idea?

    No. The...

    Gail Shaw
    Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
    SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability

    We walk in the dark places no others will enter
    We stand on the bridge and no one may pass
  • RE: Database upgrade / restore

    No. A restore will recreate the database exactly as it was at time of backup. You'll have to split the files later.

    Why do you want more than one log file?...

    Gail Shaw
    Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
    SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability

    We walk in the dark places no others will enter
    We stand on the bridge and no one may pass
  • RE: If loop inside a Database cursor remains in the Master DB

    GilaMonster (7/5/2012)


    But then, you don't ever need to change databases. Just use the sys.master_files catalog view.

    Gail Shaw
    Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
    SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability

    We walk in the dark places no others will enter
    We stand on the bridge and no one may pass
  • RE: If loop inside a Database cursor remains in the Master DB

    There's nothing in your code that could change a database context (a USE statement) or point the catalog views at other databases (three-part naming)

    But then, you don't ever need to...

    Gail Shaw
    Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
    SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability

    We walk in the dark places no others will enter
    We stand on the bridge and no one may pass
  • RE: Need help with difficult Dynamic SQL query

    Please post table definitions and details either in your post or as attachments. I'm not clicking on a link to some file that could be anything, I know a lot...

    Gail Shaw
    Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
    SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability

    We walk in the dark places no others will enter
    We stand on the bridge and no one may pass
  • RE: I want to move a database server to server without using Backup and restore?

    AAKR (7/5/2012)


    * copy files from server to server it takes more time...

    Yes it does, but if you want to move or copy a DB from one server to another, there's...

    Gail Shaw
    Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
    SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability

    We walk in the dark places no others will enter
    We stand on the bridge and no one may pass
  • RE: Revert Last Delete Statement on in SQL Mgmt Studio

    Check the SQL jobs for the one that runs the backups.

    Gail Shaw
    Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
    SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability

    We walk in the dark places no others will enter
    We stand on the bridge and no one may pass
  • RE: Steps to consider at time of testers working on database

    Why would you need to specifically monitor anything that yuo don't normally monitor when testers are working on a testing server?

    Gail Shaw
    Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
    SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability

    We walk in the dark places no others will enter
    We stand on the bridge and no one may pass
  • RE: Columns in order by clause which has no index

    What exactly do you mean by 'how does it affect the query'?

    p.s. Distinct doesn't always mean sort.

    Gail Shaw
    Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
    SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability

    We walk in the dark places no others will enter
    We stand on the bridge and no one may pass
  • RE: Need to move a database[reportingd] of sql server 2000 from e drive to f drive

    GSquared (7/5/2012)


    If it has to be online while moving it, take a look at Alter Database, specifically the data on files and file options. Details here: http://msdn.microsoft.com/en-us/library/bb522469.aspx

    Not an option...

    Gail Shaw
    Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
    SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability

    We walk in the dark places no others will enter
    We stand on the bridge and no one may pass
  • RE: Need to move a database[reportingd] of sql server 2000 from e drive to f drive

    Detach the database, move the files, attach the database.

    To move the backups you'll need to go and edit the jobs or maintenance plans that do the backups and change the...

    Gail Shaw
    Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
    SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability

    We walk in the dark places no others will enter
    We stand on the bridge and no one may pass
  • RE: How to dicrease the ram utilization

    jagadesh.kedar (7/5/2012)


    Suppose if you have 10 GB Ram,Than assaign 8 to 9 GB RAM for SQL(8-9 GB is combindely for all the instances) and that 1-2 Gb RAM is for...

    Gail Shaw
    Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
    SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability

    We walk in the dark places no others will enter
    We stand on the bridge and no one may pass

Viewing 15 posts - 17,791 through 17,805 (of 49,552 total)