Forum Replies Created

Viewing 15 posts - 1,681 through 1,695 (of 2,647 total)

  • RE: How many indexes is too many ?

    Evil Kraig F (2/15/2012)


    SQLKnowItAll (2/15/2012)


    I would actually structure the application to call separate stored procedures based on the parameters provided. This way you don't have this messy code; i.e....

  • RE: Storing a variable to use later in an update

    Ok, try this! 🙂

    USE tempdb

    CREATE TABLE tableName

    (Tif varchar (255),

    Type varchar(255),

    Code varchar(10),

    RC int,

    SEQ int,

    Descript varchar(30))

    go

    INSERT INTO tableName (Tif, Type, Code, RC, SEQ, Descript)

    Values ('00002667.TIF',102205,NULL,1,1,NULL)

    INSERT INTO tableName (Tif, Type, Code, RC, SEQ,...

  • RE: Storing a variable to use later in an update

    Ok, here's what I got so far:

    USE tempdb

    CREATE TABLE tableName

    (Tif varchar (255),

    Type varchar(255),

    Code varchar(10),

    RC int,

    SEQ int,

    Descript varchar(30))

    go

    INSERT INTO tableName (Tif, Type, Code, RC, SEQ, Descript)

    Values ('00002667.TIF',102205,NULL,1,1,NULL)

    INSERT INTO tableName (Tif, Type,...

  • RE: Storing a variable to use later in an update

    Ok, I guess I was thinking whatever was writing this data should be inserting it with the correct values to begin with. Since it is a one time thing......

  • RE: Index

    You don't have to drop the NCs to rebuild a CI.

  • RE: Label Partitioning Data based on matching attributes

    R.P.Rozema (2/15/2012)


    Similar to Paul's suggestion:

    SELECT

    ItemNum,

    ROW_NUMBER() OVER(PARTITION BY Attribute1,Attribute2,Attribute3 ORDER BY (SELECT NULL)) as DupNR

    FROM T1;

    All rows having a value higher than 1 in...

  • RE: Storing a variable to use later in an update

    Ok, I get it now. Can I ask why you are doing this in SQL? Is this a 1 time update? Are you getting data from a file, importing...

  • RE: Monthly Report Query

    Jeff Moden (2/15/2012)


    adeel.imtiaz (2/15/2012)


    1. Query Monthly report (A1)[font="Arial Black"] with result in grid[/font], it will take 4minutes and 9 seconds.

    2. Query Monthly report(A1)[font="Arial Black"]with result in text[/font], this time it...

  • RE: Storing a variable to use later in an update

    Ok, great. So from this sample data, what is supposed to happen?

    something like this (Not real SQL, just a kind of pseudocode)?

    UPDATE tableName SET a.Code = b.Type WHERE b.lastRC...

  • RE: Order by While inserting

    Jeff Moden (2/15/2012)


    ScottPletcher (2/15/2012)


    I think the order does matter for the clus index and whether it gets fragmented or not. SQL is coded to recognize sequential inserts and not...

  • RE: NT SERVICE\SQLSERVERAGENT

    Try this link, http://social.msdn.microsoft.com/Forums/en-NZ/sqlsecurity/thread/9e6bb2de-8fd0-45de-ab02-d59bbe05f72e it does a better job at explaining it than I did. Sorry if I have confused you more.

  • RE: NT SERVICE\SQLSERVERAGENT

    sqlfriends (2/15/2012)


    SQLKnowItAll (2/15/2012)


    Let's try this explanation... When you use SQL Server Configuration Manager to change the logon for a service, it does not "add" that domain user to SQL Server....

  • RE: How many indexes is too many ?

    I would actually structure the application to call separate stored procedures based on the parameters provided. This way you don't have this messy code; i.e. GetResumesByName, GetResumesByNameAndNumber, GetResumesByCity.

    More code...

  • RE: Storing a variable to use later in an update

    Your DDL should look like this:

    CREATE TABLE tableName (Tif varchar (255)

    Type varchar(255),

    Code varchar(10),

    RC int,

    SEQ int,

    Descript varchar(30))

    Is this correct to make...

  • RE: NT SERVICE\SQLSERVERAGENT

    Let's try this explanation... When you use SQL Server Configuration Manager to change the logon for a service, it does not "add" that domain user to SQL Server. It adds...

Viewing 15 posts - 1,681 through 1,695 (of 2,647 total)