Forum Replies Created

Viewing 15 posts - 57,031 through 57,045 (of 59,070 total)

  • RE: Creating fixed-length tables

    Serqiy and Barry,

    Heh... I finally drank enough coffee and now I get it... and I agree.  Serqiy is absolutely correct.

    Actually, my fault... All I saw was "the latest 50 rows"...

  • RE: String Manipulation Help

    Heh... thanks for the feedback, Remi.

  • RE: Recovery of improperly detached MDF files

    Thanks for the feedback, folks.  Glad it helped.

  • RE: Creating fixed-length tables

    In the presence of an appropriate index, DClark's method and the following method both work at about the same speed and both do the same thing functionally...

     DELETE FROM...

  • RE: how to remove ''''bad'''' characters from field?

    Don't need it... N is the clustered Primary Key.  Yeah, I know what you're going to say...

    Anyway, the length in the substrings is hardcoded... surely you're not suggesting that I...

  • RE: how to remove ''''bad'''' characters from field?

    If you have a Tally table, here's a possible solution, as well...

     CREATE FUNCTION dbo.StripNonDigit(@Input VARCHAR(8000))

    RETURNS VARCHAR(8000)

         AS

      BEGIN

            DECLARE @Result VARCHAR(8000)

             SELECT @Result = ISNULL(@Result,'')

                 ...

  • RE: how to remove ''''bad'''' characters from field?

    Yep... I agree with Serquiy... if it's for an automatic dialer (or ever could be) or for humans to actually know whether it might be an international call just by...

  • RE: Stored Procedure + Parameter list

    True enough , Serqiy, but if you want to name variables for flexibility, it is an error to name them after the actual...

  • RE: Select top groups

    I'm with PW... I normally use "Derived Tables", as well.  And, I normally don't like correlated subqueries because they can be difficult to troubleshoot.  But their use seems appropriate just...

  • RE: Creating fixed-length tables

    Got a code example for this particular "keep last 50" problem so we can see what you're talking about?  I think you're talking about pre-assigning constants as variables which also...

  • RE: Stored Procedure + Parameter list

    Nicely done... although I do hope no one actually tries to pass a billion characters worth of parameters

    By the way... you hardcoded the 2's...

  • RE: how to remove ''''bad'''' characters from field?

    Some of the solutions on the link seem, well... a bit bulky...  I don't remember where I got it from but this works and it's nasty fast...

    USE NorthWind

    GO

     CREATE...

  • RE: Creating fixed-length tables

    No "error"... Think of it as an "interation step" "that I hope will never be changed in my lifetime"...

    ...unless you'd rather see...

    WHERE RowNum <=...

  • RE: Minimum of top two values

    This is SO much easier if you have a RowNum column....

    SET NOCOUNT ON

    DECLARE @MyTable TABLE

    (

    RowNum INT IDENTITY(1,1) PRIMARY KEY,

    ItemName VARCHAR(6),

    ItemNo  INT,

    ItemValue NUMERIC(20, 2)

    )

    January 19, 2007 at 11:52 pm

    #684498

  • RE: Logic to determine Gender based on FirstName

    Shoot.... in this day an age of supposed equal opportunity, why would you need to know?  Might even be against the law if it's for college admissions, for example...

Viewing 15 posts - 57,031 through 57,045 (of 59,070 total)