Forum Replies Created

Viewing 15 posts - 361 through 375 (of 5,502 total)

  • RE: Concat columns in Where clause

    Jonathan Marshall (11/12/2013)


    The queries are updating lookup tables that do not have a value by using a subquery to the lookup table.

    I like that idea of using a computed...



    Lutz
    A pessimist is an optimist with experience.

    How to get fast answers to your question[/url]
    How to post performance related questions[/url]
    Links for Tally Table [/url] , Cross Tabs [/url] and Dynamic Cross Tabs [/url], Delimited Split Function[/url]

  • RE: XML Export File

    hunchback (11/12/2013)


    Have the descriptor in a separated file and do the concatenation at the command side using COPY.

    c:\>copy f1 /B + f2 /B f3 /B

    Why would someone use the file...



    Lutz
    A pessimist is an optimist with experience.

    How to get fast answers to your question[/url]
    How to post performance related questions[/url]
    Links for Tally Table [/url] , Cross Tabs [/url] and Dynamic Cross Tabs [/url], Delimited Split Function[/url]

  • RE: Concat columns in Where clause

    Your question is incomplete since ther WHERE clause is missing the "= something" part. But that's just as a side note...

    If my limited knowledge is correct, you'll end up with...



    Lutz
    A pessimist is an optimist with experience.

    How to get fast answers to your question[/url]
    How to post performance related questions[/url]
    Links for Tally Table [/url] , Cross Tabs [/url] and Dynamic Cross Tabs [/url], Delimited Split Function[/url]

  • RE: Summary column values need to be zero not null

    something along those lines should help:

    SELECT DISTINCT

    ISNULL(IA.TeamsRSF, 'Not Provided') AS 'Teams RSF'

    ,ISNULL(IA.TeamSupervisor, 'Not Provided') AS 'Teams Supervisor'

    ,ISNULL(IA.AssignedWorker, 'Not Provided') AS Worker

    ,ISNULL(TA.TotalAssignments,0) AS TotalAssignments

    ,ISNULL(PA.PriorAssigned,0) AS PriorAssigned

    ,ISNULL(NA.NewAssigned,0) NewAssigned

    ,ISNULL(CA.Completed,0) Completed



    Lutz
    A pessimist is an optimist with experience.

    How to get fast answers to your question[/url]
    How to post performance related questions[/url]
    Links for Tally Table [/url] , Cross Tabs [/url] and Dynamic Cross Tabs [/url], Delimited Split Function[/url]

  • RE: Not able to open TSQL scripts in SSMS

    duplicate post. No replies please.

    original post: http://www.sqlservercentral.com/Forums/Topic1506446-3077-1.aspx

    @OP: Even though you don't like the answers you received so far, therer's no reason whatsoever to open a new thread for the very...



    Lutz
    A pessimist is an optimist with experience.

    How to get fast answers to your question[/url]
    How to post performance related questions[/url]
    Links for Tally Table [/url] , Cross Tabs [/url] and Dynamic Cross Tabs [/url], Delimited Split Function[/url]

  • RE: DATE

    It looks like something along those lines might help (untested due to missing sample data in a ready to use format...):

    WITH cte AS

    (

    SELECT DISTINCT articulo

    FROM unknown

    )

    SELECT

    uk.articulo,

    uk.bodega,

    uk.cant_disponible,

    uk.cantidad,

    uk.fecha_hora_transac

    FROM cte

    CROSS APPLY

    (

    SELECT TOP...



    Lutz
    A pessimist is an optimist with experience.

    How to get fast answers to your question[/url]
    How to post performance related questions[/url]
    Links for Tally Table [/url] , Cross Tabs [/url] and Dynamic Cross Tabs [/url], Delimited Split Function[/url]

  • RE: Uncertain JOIN condition - are there settings that control how it is tolerated?

    I'm not sure what you mean by "settings", but one method you could use to make the update statement "fail" is to add a constraint:

    ALTER TABLE #a WITH CHECK

    ADD...



    Lutz
    A pessimist is an optimist with experience.

    How to get fast answers to your question[/url]
    How to post performance related questions[/url]
    Links for Tally Table [/url] , Cross Tabs [/url] and Dynamic Cross Tabs [/url], Delimited Split Function[/url]

  • RE: moving Model.mdf file on different drive and Model.ldf file on different drive

    Yes, it's possible to have mdf and ldf files on different drives, including the MODEL database.



    Lutz
    A pessimist is an optimist with experience.

    How to get fast answers to your question[/url]
    How to post performance related questions[/url]
    Links for Tally Table [/url] , Cross Tabs [/url] and Dynamic Cross Tabs [/url], Delimited Split Function[/url]

  • RE: Having problem openning SQL scripts

    If those files are on a network share, ask your admin responsibe for that share if a backup from last week is available and if they're able to restore the...



    Lutz
    A pessimist is an optimist with experience.

    How to get fast answers to your question[/url]
    How to post performance related questions[/url]
    Links for Tally Table [/url] , Cross Tabs [/url] and Dynamic Cross Tabs [/url], Delimited Split Function[/url]

  • RE: Remote Scan via Linked Server

    There are several issues:

    1) "a query not using the cluster index. It is running a full scan."

    A "full scan" (of the table) acually returns all data from the...



    Lutz
    A pessimist is an optimist with experience.

    How to get fast answers to your question[/url]
    How to post performance related questions[/url]
    Links for Tally Table [/url] , Cross Tabs [/url] and Dynamic Cross Tabs [/url], Delimited Split Function[/url]

  • RE: How to safely secure Human Resources sensitive data?

    I'm just slightly confused: The current process having Excel files, MS ACCESS and the like involved is obviously "secure enough", but SQL Server is questioned? :doze:

    Has there ever been a...



    Lutz
    A pessimist is an optimist with experience.

    How to get fast answers to your question[/url]
    How to post performance related questions[/url]
    Links for Tally Table [/url] , Cross Tabs [/url] and Dynamic Cross Tabs [/url], Delimited Split Function[/url]

  • RE: Insert Into Databases

    An insert statement can only have one target table at a time.

    Even if it would technically be possible, I don't see any logical way to make it work: just assume...



    Lutz
    A pessimist is an optimist with experience.

    How to get fast answers to your question[/url]
    How to post performance related questions[/url]
    Links for Tally Table [/url] , Cross Tabs [/url] and Dynamic Cross Tabs [/url], Delimited Split Function[/url]

  • RE: Insert Into Databases

    I wonder if the code you provided is actually correct...

    As far as I can see, this code will never insert a single row into DB2.dbo.CUSTVEND, since

    DB1.dbo.CUSTVEND c1

    where c1.ACCTNO+c1.SUBC not...



    Lutz
    A pessimist is an optimist with experience.

    How to get fast answers to your question[/url]
    How to post performance related questions[/url]
    Links for Tally Table [/url] , Cross Tabs [/url] and Dynamic Cross Tabs [/url], Delimited Split Function[/url]

  • RE: Getting Total Count for each month based on the Start and End Date

    Just as a side note:

    Whenever dealing with a date type in character format, I'd prefer the ISO format 'YYYYMMDD', so '20131015' instead of '10/15/2013'

    Just use SET DATEFORMAT DMY in a...



    Lutz
    A pessimist is an optimist with experience.

    How to get fast answers to your question[/url]
    How to post performance related questions[/url]
    Links for Tally Table [/url] , Cross Tabs [/url] and Dynamic Cross Tabs [/url], Delimited Split Function[/url]

  • RE: Indexing and Querying a Frequently Updated Table

    I'm not sure what you mean by "a lot of indexing"... The number of indexes you described is moderate, at least from my perspective...

    Depending on the ratio of the messages...



    Lutz
    A pessimist is an optimist with experience.

    How to get fast answers to your question[/url]
    How to post performance related questions[/url]
    Links for Tally Table [/url] , Cross Tabs [/url] and Dynamic Cross Tabs [/url], Delimited Split Function[/url]

Viewing 15 posts - 361 through 375 (of 5,502 total)