Forum Replies Created

Viewing 15 posts - 466 through 480 (of 499 total)

  • RE: Advice for array oflarge arrays

    I think the only significance of 3 values per line is so it fits on an old 80-character green screen.

    I have been investigating the code further and it seems the...

  • RE: Error when trying to do join on two tables

    Some suggestions:

    Try SELECT T1.ID, T2.ID, T3.ID

    instead of SELECT * - if it now works, add columns back in until you find the problem column

    and Try adding a WHERE clause

    WHERE...

  • RE: Advice for array oflarge arrays

    Thanks Jeff,

    the file is ascii, record structure is

    line 1 [Block Number] [No Values in Block]

    lines 2...341 [value] [value] [value]

    e.g. the first 4 lines are

    ...

  • RE: Points Suggestion

    Maybe just a standard x points for an article, y for a script and z for a QotD if they pass the moderator and make it onto the site. ...

  • RE: Performance Tuning: Concatenation Functions and Some Tuning Myths

    Jeff

    Its brilliant. But how on earth can anyone be expected to figure out the STUFF(... WHERE ... FOR XML PATH('') Syntax - especially when there is no XML involved!

    I'll...

  • RE: delete records

    On first reading I thought your delete was taking over half an hour - so TRUNCATE may be an answer instead of DELETE * for a particularly large table.

    However I'm...

  • RE: Date Format

    I'm not sure exactly what you're looking for but this could help

    CONVERT can take a variable, you could pass that as a parameter.

    DECLARE @Fmt INT

    SET @Fmt = 113

    SELECT CONVERT(varchar(25), YourDateTimeColumn,...

  • RE: How to design a "Tagging" system

    Thanks Barry

    I had thought about separate Tags tables originally: BookTags and AuthorTags - but a single Tag table does simplify things. I'd wondered on how to prevent the same...

  • RE: The Daily Commute

    Hmm although 7.5 miles certainly would be better exercise, I'm sure the car would win out if that were the case. Free parking at work too

    But there is a...

  • RE: Slow with the in function

    Your NOT IN clause would mean checking against every single value to make sure there is no match.

    Check the execution plan for the query, then try

    AND NOT EXISTS (SELECT...

  • RE: Is there any benefit of using TOP/SET ROWCOUNT on update if within transaction

    A reason to break the updates into chunks using TOP/ROWCOUNT is to prevent an exclusive table locks. There are other advantages to do with transaction logging, but I think you...

  • RE: The Daily Commute

    😀 I am so lucky in my current job :). I cycle 2.5 miles to work, along a mostly traffic free route, however I do lug a heavy laptop...

  • RE: Unclosed quotation mark after the character string '.jpg’

    I think you have the wrong type of quote at the end of .jpg a " ` " instead of " ' "

    replace the quote and it should be OK

  • RE: Max function

    Is this what you're after?

    SELECT SNO, Rating, Rating_Month as RatingMonth

    FROM PI_ALL

    WHERE Rating_Month = (SELECT MAX(Rating_Month) FROM PI_ALL)

    GROUP BY SNO, Rating, Rating_Month

  • RE: Generating a Custom Sequence Number in SQL Server 2005

    I think you can do it quite simply.

    SELECT ID, ROW_NUMBER() OVER(PARTITION BY ID, ORDER BY ID) AS Seq_Num

    FROM ... etc

    See the ROW_NUMBER() function in BOL

Viewing 15 posts - 466 through 480 (of 499 total)