Forum Replies Created

Viewing 15 posts - 16 through 30 (of 155 total)

  • RE: How many more Mondays until I retire?

    I modified your function as follows:

    CREATE

    FUNCTION dbo.MySeqDates (@LowDate DATETIME, @HighDate DATETIME)

    RETURNS @Dates...

  • RE: How many more Mondays until I retire?

    In the first code sample, I suppose that this portion should return each number between 0 and 32, right ?

    SELECT

    a.i...

  • RE: How do you spell S-Q-L?

    Q: What is checkpointing?

    A: Checkpointing is the point at which the system checks to see if the transaction log needs to be truncated.

    This answer is not completely wrong, because...

  • RE: Question of the Day for 12 Jul 2005

    Oops, I was wrong... The GUID-s generated by SQL Server are random, even if the server runs on Windows 98 ! The GUID-s are sequential only if they are generated...

  • RE: Question of the Day for 12 Jul 2005

    I answered that in SQL Server 2000, the GUID-s generated by NEWID() are always random (which seemed to be the most appropriate answer), however this is not entirely true.

    The...

  • RE: Procedure cache - recompile problem

    Good news: Microsoft has issued a fix for this in SQL Server 2000 SP4 (actually, in 8.00.0954):

    http://support.microsoft.com/kb/870972

    You have to enable trace flag 9055 to activate the "threshold improvement".

    Razvan

  • RE: Wrong week numbers

    The DATEPART(WK,...) function does not return the ISO week number. If you need the standard week number, use the following function (the first example from the BOL topic "CREATE FUNCTION"):

    CREATE...
  • RE: GROUP BY vs DISTINCT -- SQL SERVER BUG ?

    I recently found out that Microsoft has added a new KB article for this issue:

    http://support.microsoft.com/?kbid=883415

    The good news is that there is a hotfix,...

  • RE: Running T-SQL script

    You get an error because "GO" is not a T-SQL keyword, it's a batch separator; normally it should be processed by the client tools (not by the server). You could parse the...

  • RE: Second instence of SQL Server 2000

    Indeed, you should use the Server Network Utility to enable the TCP/IP protocol (and maybe disable the Named Pipes protocol). It may also be useful to read the following article:

  • RE: Evaluating Boolean expressions using T-SQL

    The first part of the procedure is good enough, but a better solution could be done for the final evaluation. Instead of using a temporary table, we can use output parameters in...

  • RE: SUM function to return null if null value exists

    Here is another way, without using a subquery:

    SELECT item_grp, CASE WHEN COUNT(item_value)<COUNT(*)
     THEN NULL ELSE SUM(item_value) END AS raw_sum
    FROM ab_sum_nulls
    GROUP BY item_grp

    And here is another one, without using a CASE:

     
  • RE: SQL Statement

    Steve,

    Regarding your question "why a query with INNER JOIN-s may perform worse than the equivalent query with WHERE conditions": this is theoretically possible (although in very rare circumstances), because of...

  • RE: CONTAINS statement

    AFAIK, the correct syntax is:

    CONTAINS (contents, '"lighting" AND "futures"')

    Razvan

  • RE: Retriving host IP Address via T-SQL

    OK, Frank, go ahead.

    It would be nice, however, if you'd have an english version of your site.

    Razvan

Viewing 15 posts - 16 through 30 (of 155 total)