Forum Replies Created

Viewing 15 posts - 961 through 975 (of 5,843 total)

  • RE: Function to convert a datetime value into a harvest season year

    joe-584802 (6/14/2016)


    Thank you so much for the replies this is what I ended up doing as a Scalar-Valued Function

    CREATE FUNCTION [dbo].[GetHarvestYear] (@InputDate datetime)

    RETURNS int

    AS

    BEGIN...

  • RE: Function to convert a datetime value into a harvest season year

    But do NOT DO THIS AS A SCALAR UDF IN SQL SERVER!!! They are HORRIBLY BAD!!!!!!!!!

    If you cannot simply inline the code into your TSQL (best), then do this...

  • RE: OR in the where clause or two select statements and a union

    Luis Cazares (6/14/2016)


    Change your UNION to a UNION ALL, unless you want to eliminate duplicates.

    UNION will need to add a sort which is expensive.

    If your queries have adequate indexes, I'd...

  • RE: Maintenance plans question

    AFAIK you will need to write your own file processor either in TSQL or externally with the scripting language of your choice. I would do it with the latter.

  • RE: Maintenance plans question

    What you are missing is that you should never, EVER use maintenance plans!! 🙂

    Ola.Hallengren.com. Every single client I ever visit starts using the awesomeness found there.

  • RE: SQL Memory Consumption

    Glenn Berry SQL Diagnostic Scripts has some good stuff. IIRC the SQL Server Internals books may have a useful section too.

    I think there was a tool someone wrote to show...

  • RE: 13:1:78484916 suspended PAGEIOLATCH_EX

    gxdatareal (6/13/2016)


    HELLO

    I Have a serious problem

    I am trying to run an sql query (uodate)

    UPDATE DBO. GENERIC

    SET TITLE= B.TITLE

    FROM DBO. GENERIC AS A with (nolock)

    INNER JOIN DBO. DISTINCT AS...

  • RE: Sequential read from table

    tomd-982312 (6/9/2016)


    Luis Cazares (6/8/2016)


    For a fast sequential read of a table to move data from one system to another, you could also use SSIS.

    You're doing ETL work, use the ETL...

  • RE: Index fragmentation and SSDs

    Mick Opalak (6/8/2016)


    Memory = 2TB

    Fill Factor = 75 because our system (OLTP) is so active (3500 transactions at any given time) that indices get highly fragmented (like over 90%) daily.

    1)...

  • RE: Index fragmentation and SSDs

    Mick Opalak (6/8/2016)


    Unfortunately we are seeing the exact opposite. We accidentally altered our index maintenance job so since late March we've only been defragging about 20% of our indices....

  • RE: Index fragmentation and SSDs

    I have done what you did (in doing no index mx and allowing the system to come to something approaching a "steady state fill factor" with just a couple of...

  • RE: Index fragmentation and SSDs

    Jonathan Kehayias did a benchmark that showed that SSDs were actually slower at random IO than sequential. But the difference is pretty small.

    But there are other reasons to be...

  • RE: Sequential read from table

    tomd-982312 (6/8/2016)


    Guys, this topic is not about efficiency, or RBAR, or order by, or dbms_output.put_line().

    I'm just trying to find simple code that reads sequentially row by row from table. It's...

  • RE: Query taking 6 hrs and counting (HELP!)- how to concatenate rows into single string

    1) Did you do what I said about sp_whoisactive??

    2) How much memory do you have on this sql server? IIRC XML can be a MASSIVE consumer of memory and if...

  • RE: SQL Server 2016 Standard Availbality groups

    crcoracle (6/7/2016)


    Hi,

    May be the picture is confusing. The "mirror" is made by SQL Server AG (not by the SAN)

    As far as I know, I'm using 3 nodes, but there is...

Viewing 15 posts - 961 through 975 (of 5,843 total)