Forum Replies Created

Viewing 15 posts - 46,711 through 46,725 (of 49,552 total)

  • RE: Anonymous Access in Reports

    SQL King (5/5/2008)


    ( I am sorry if some of you have already seen this in other topic of this forum, I just want to get as many response as I...

    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: Get First row value

    IMHO = In my humble opinion.

    No.MID has any value,I look at only CODE

    So how do you define the 'first' row for a specific code?

    Remember, SQL Server has no concept of...

    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: Performance Problem

    You can't add more filegroups to TempDB. Just more files (tempDB1.ndf. tempdb2.ndf, ...)

    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: Get First row value

    By 'first', do you mean the one with the lowest MID? If so, this will work for you.

    SELECT <Column List>

    FROM Emp Inner join

    (SELECT MIN(Mid) AS FirstMID, Code FROM...

    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: Full Recovery Mode Question for SQL 2000/2005

    Yup.

    It's something for you to consider when deciding whether to switch to simple or enable log 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: Full Recovery Mode Question for SQL 2000/2005

    If you're not going to do tran log backups and you don't care about recovering to a point in time, in the case of a failure, then there's no reason...

    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: RGB calculation

    What's the formula for calculating RGB from R, G, B? It's possible that T-SQL can do the maths.

    You could create a calculated column in the table, which means the RGB...

    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: Command to know the Name of the database of a backup file

    Yup. That will work great if the backup was created on the server where the query is being run.

    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: Performance Problem

    Here's something:

    Working with tempdb in SQL Server 2005

    An excerpt...

    tempdb supports only one data filegroup and one log filegroup. By default, the number of files is set to 1. Multiple files...

    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: SQL Join Hints

    No. those will be up to the query optimiser/query processor depending on memory availability, number of rows, etc

    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: Command to know the Name of the database of a backup file

    Note it's a resultset, so it's going to be difficult to get into a variable, unless you do something like this.

    insert into SomeTable

    execute ('Restore .... ')

    select @SomeVar = [Database] From...

    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: Creating 1 Million Row on the fly

    karthikeyan (5/5/2008)


    Can you give me the full query ?

    You should be able to figure it out.

    I don't have time to type out 6 subqueries each with 10 unioned queries...

    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: SQL Join Hints

    ... FROM tbl1 INNER LOOP JOIN tbl2 ON ... -- nested loop join

    ... FROM tbl1 INNER MERGE JOIN tbl2 ON ... -- merge join

    ... FROM tbl1 INNER HASH JOIN tbl2...

    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: Creating 1 Million Row on the fly

    On 2005, you could use a recursive CTE.

    Why can't you use a table?

    If you absolutely want to do this the hard way, something kinda like this will probably...

    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: Creating 1 Million Row on the fly

    Cross join a couple of system tables together. Jeff usually uses spt_values (in master)

    You could use a user table also. All you need is one table of 1000 rows.

    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 - 46,711 through 46,725 (of 49,552 total)