Forum Replies Created

Viewing 15 posts - 3,421 through 3,435 (of 6,036 total)

  • RE: how to remove numbers from strings?

    Matt Miller (10/19/2007)


    I figured that was the general direction you were heading in. A lot of that's improved with the newer updates to the framework. Certainly after them...

  • RE: Adding workdays

    Greg Snidow (10/19/2007)

    Sergiy, wouldn't it be possible to have a small table of only hollidays, and if @DateEnd falls on one of those days just add 1?

    Bloody site!

    Wiped out...

  • RE: Adding workdays

    Funny story guys is that your UDF's don't work.

    No matter how hard you try to perfect it.

    They don't work by definition.

    And nobody can do anything about it.

    At least they don't...

  • RE: How to rewrite a LEFT OUTER JOIN query?

    Sorin,

    Your query returns columns only from table "s".

    Why you need those joins at all?

  • RE: Adding workdays

    Jeff Moden (10/18/2007)


    Ah... sorry, it doesn't work as expected... it includes weekends which is what Greg is trying to exclude... in terms of your example, he wants to add 30...

  • RE: How to use a constant value in select query in a view definition

    Another name for "View with parameters" is "Table function".

  • RE: Adding workdays

    BTW, my Tally table holds 65k dates, it's the whole range of "smalldatetime" dates.

    So, "Working Days" table contains 65k - 14 rows.

  • RE: Adding workdays

    Jeff Moden (10/18/2007)


    Heck of a good try... but still a bit of RBAR there... looks almost like a date table but limited to 365 days. No doubt it works...

  • RE: sum(float) != sum(float)

    Jeff Gray (10/16/2007)


    I'm not pointing out anything other than the fact that the order in which the rows are added changes the result, thus suggesting that addition of floats is...

  • RE: Apparent Error with BETWEEN operator

    [font="Courier New"]--Create 2 tables to hold normalized data

    IF Object_ID('dbo.PrefixCode', 'U') IS NOT NULL

    DROP TABLE dbo.PrefixCode

    CREATE TABLE dbo.PrefixCode (

    ID smallint IDENTITY(-32767, 1) NOT NULL PRIMARY KEY NONCLUSTERED,

    Code nvarchar(10) COLLATE SQL_Latin1_General_CP1_CI_AS...

  • RE: Apparent Error with BETWEEN operator

    Jim Howell (10/18/2007)


    That could be the answer! In the real world, these numbers are barcoded on envelopes and we send and receive a couple hundred thousand a month. ...

  • RE: How to rewrite a LEFT OUTER JOIN query?

    System functions are as bad here as UDFs.

    But it does not mean you cannot use functions in WHERE clause at all.

    You should not use it to modify values in table...

  • RE: Auto Column Check

    Lowell (10/18/2007)


    i don't think you can use a calculated column in this case, because the penalty amount resides in a different table

    You can declare computed column using a function.

    And function...

  • RE: Trying to understand SQL Server's handling of redeclared variables

    Kenneth Wilhelmsson (10/18/2007)No, there is no risk of memoryleaks or 'runaway' multiples of overwritten variables etc, since the declaration only happens once.

    There is only risk of fooling yourself.

  • RE: Trying to understand SQL Server's handling of redeclared variables

    Here is one trick which can help to understand it.

    There is one variable which you can see declared.

    It's table variable.

    [font="Courier New"]----------------------------------

    SELECT * FROM tempdb..sysobjects WHERE name LIKE '#%'

    GO

    SELECT * FROM...

Viewing 15 posts - 3,421 through 3,435 (of 6,036 total)