Forum Replies Created

Viewing 15 posts - 121 through 135 (of 345 total)

  • RE: Troubleshooting TimeOut Expired Error

    Difficult to say what the issue is.

    If you want to look at hardware then do you have separate disks for the tr log and are backups taken to a different...

  • RE: Function - Long Running Query

    Those should help but really need to know where the issues are.

    Can you materialise the datasets you are using and maybe update them from triggers.

    It looks like the table structure...

  • RE: Function - Long Running Query

    Looks like the loop is just splitting up comma delimitted lists from @t2

    This would mean you don't need the identity.

    insert @t3

    select distinct SUBSTRING(Column1, 1,PATINDEX('%,%',Column1))

    from @t2

    while @@ROWCOUNT 0

    begin

    update @t2

    set Column1...

  • RE: Function - Long Running Query

    Assume you've dealt with indexing and such

    A few obvious comments

    Could you change union to union all?

    in (select DISTINCT Column1 from @t3)

    Could you ensure unique values in @t3 rather than using...

  • RE: linked server

    A linked server is just a method of querying the remote server.

    You have to issue sql statements to extract data

    select *

    from LinkedServer.dbname.dbo.tblname

    where .....

    it doesn't do anything automatically with regards to...

  • RE: linked server

    If there's nothing to say when a row is updated then you are stuck with transferring the whole table (or checksums) and checking it.

    Not feasible if the table is large...

  • RE: linked server

    So you are updating your local copy of the database from the server?

    Does the table have anything to say when a row was updated? A last updated column, a timestamp,...

  • RE: case vs if

    >> always the same columns is returned

    >> q.*

    Both dangerous statements.

    Does q have a simple PK?

    If so I would return the those values then join to q to get the data.

    Whether...

  • RE: linked server

    Are you asying that you have data on your local machine which is being accessed from the server to support queries (to avoid data duplication)?

    I would go back to your...

  • RE: Poor Man's Partitioning in MSSQL 2005 Std Ed.

    Can you create a partitioned view.

    No idea if this is still available in v2005 or how it's supported by standard edition.

    Note it this is still on one disk you will...

  • RE: Foreign keys/null foreign keys and multiples thereof

    Your only problem is the foreign key so the options are:

    1. Support the integrity programatically - maybe by a trigger.

    2. A single referenced table with possibly a lot of attributes...

  • RE: Programmatically create a Slowly Changing Dimension Task in SSIS - How To?

    I do this using sql fom the table definitions.

    Create an SSIS package to import the data to a staging table (xml is created from a template and the source/destination columns...

  • RE: Collation error after restore

    Changing the collation of the user databases won't help - it only affects new tables that use the default collation. You would need to change the collation of all the...

  • RE: How to design 1:n relationships in Sql Server Management Studio?

    Have a look at what it generates.

    You will have two tables.

    One will have a foreign key that references the other

    create table manager

    (

    manager_id int

    )

    create table player

    (

    player_id int ,

    manager_id int ,

    foreign key...

  • RE: 10/22

    Correct answer would be none of the above - as that's not an option a, b is obviously what's wanted.

    You need to guess the answer required rather than what is...

Viewing 15 posts - 121 through 135 (of 345 total)