Forum Replies Created

Viewing 15 posts - 946 through 960 (of 1,554 total)

  • RE: need hep on update query, -datetime

    Yes? What about them?

    Leap years is the reason to divide by 365.25 instead of 365...

    As a sidenote, I can't take credit for the algorithm, I read it in some article...

  • RE: need hep on update query, -datetime

    Here's what I use when determining ages

    -- 2003-03-11 / Kenneth Wilhelmsson

    -- Determining current age notes.

    -- To be able to determine current...

  • RE: Using calculated values within the same Select Statement

    It is, though you have to move the third sum 'outside' by wrapping the amount1 and amount2 calculations in a derived table.

    I think this is what you want..

  • RE: Copying Records

    The quick and dirty way - (if it's a very large table, watch so you don't interfere with others during the operation)

    SELECT  *

    INTO    db2.dbo.myNewTable

    FROM db1.dbo.myTable

    ..will make a copy along with all...

  • RE: how to access view from another application

    No, that's not necessarily better. Though it's possible to do it like that, I wouldn't do so myself.

    I suggest that you get hold of BOL (Books On Line) for SQL...

  • RE: Question on SQL sp getting correct results back

    We need DDL scripts for the tables involved (at least the important parts), and scripts that inserts testdata that when we use the query you have, will produce the 'wrong'...

  • RE: SQlServer.exe

    By design, when in 'dynamic memory mode', SQL Server will grab memory when it needs it up to a limit leaving 'enough for the o/s' (sry don't have the exact...

  • RE: SQL Mail Setup Error.

    Once upon a time, long long ago, I managed to get SQL Mail to work.. sort of.. It was clunky at best, and a real pain to find all the...

  • RE: Incrementing a value with a set based solution

    If the method of generating new id's for the users is to just take the max(id) +1 from the prod table, then you have no choice but to close down...

  • RE: changing data types

    The same fact still applies, wheter it be a script or using EM..

    You cannot change (ie alter) a column that is type text to varchar. Frank's script does not change...

  • RE: Help with query to calc new field

    It's probably me, but it's one thing I don't get... (I can't figure out what 'draw' means)

    In any case, the example will say you have a 1% sale... I don't...

  • RE: always rounding down

    Great

    Perhaps you need to adjust the numbers so your max values will fit.

    select substring(str(@m, 10, 4),1,8)

    The 10 is max...

  • RE: always rounding down

    Here's the only way I can think of...

    Convert the value to a string using STR with all decimals intact, then just snip off the last two digits with substring...

    August 10, 2005 at 8:01 am

    #581034

  • RE: Transaction Error

    Here's an article worth reading Implementing Error Handling with Stored Procedures

    Don't be scared by the amount of text, it's crucial that every Transact-SQL coder understands transaction handling fully.

    Also,...

  • RE: SQL query that includes *all* table rows

    Hehe, well in your example you requested the value 'www.foo.com', so that's what you need to ask for.

    You could provide the URL through a variable instead, I assume that you...

Viewing 15 posts - 946 through 960 (of 1,554 total)