Forum Replies Created

Viewing 15 posts - 331 through 345 (of 530 total)

  • RE: retrieving adjacent columns from Max()

    Another solution is using a join. This solution will give you more than one record if the max(StartDate) is not unique in the table.

    
    
    SELECT t.<needed columns>
    FROM...
  • RE: Avoiding Deadlocks

    One thing to bear in mind when accessing databases using ADO is the cursortype.

    Depending on the type, ADO will lock the complete resultset, only a part of the set...

  • RE: Changing length of User-Defined Datatype

    Been there, done that ...

    Once had a client who insisted that we changed all names in our database to reflect their own database naming conventions.

    At least we managed to charge...

  • RE: Changing length of User-Defined Datatype

    I can see your point Chris. Changing the DB layout can cause a lot of harm when they are referenced. But as you mention we do have full control over...

  • RE: Changing length of User-Defined Datatype

    Thought of that, but EM does not allow you to change the length of a UDT. So no luck there.

    The solution posted by Tim is the only one I found...

  • RE: Is this possible ?

    Having a go at this ...

    
    
    SELECT S.Batch_ID,
    DATEDIFF(ss, E.ACTIVITY_DATE, S.ACTIVITY_DATE)
    FROM (SELECT BATCH_ID, ACTIVITY_DATE
    FROM BATCHAUDIT...
  • RE: request for examples (CURSOR)

    Check out the 'WHERE CURRENT OF' syntax in BOL. This will work in T-SQL with a cursor declared as FOR UPDATE.

    
    
    USE Northwind
    GO
    BEGIN TRANSACTION
    DECLARE crs_Update CURSOR FOR
    ...
  • RE: Calculating Business month-ends

    I believe my solution can be adjusted for your schema.

    Replace Date with FullDate, Holiday with IsHoliday, DayOfWeek by DayNumberOfWeek, DayOfMonth by DayNumberOfMonth, Month by ShortMonthName and you'll be up and...

  • RE: Calculating Business month-ends

    Possible solution under the following preconditions :

    - DayOfWeek is 1 for Monday

    - Holiday is 1 for a holiday, 0 for not (weekend is also holiday)

    - @Month is the month you...

  • RE: Count WeekDays

    I guess you could find some kind of algorithm to subtract the number of weekend dates. In the end, there are 2 weekend days for each 7 days you count...

    You...

  • RE: Performance Problem after SP3

    Just some wild guesses...

    Is your IIS running on the same server as the SQLServer?

    If not, did you upgrade the IIS to MDAC 2.7? Maybe there is some (unexplainable) effect if...

  • RE: New Hardware HELL

    If a copy over the network is not an option, you could use a spare harddrive to transfer the file.

    Are there any other issues you have to deal with, like...

  • RE: Update trigger that affects multiple rows

    You're right when you say that you have to 'go through' the deleted table and handle each row. The trigger is only fired once for each query. So if you...

  • RE: Table/Column Naming Conventions (Opinions Wanted)

    Have to agree with the more verbose and redundant naming convention using TableName_ID (or something similar).

    I believe the point mromm made about enforcement not being present is a good one...

  • RE: Running Oracle and SQL on server

    We've had both Oracle (8 I think) and SQL Server (7) running on a single development server.

    No problems there, but we did not have any link between both databases.

Viewing 15 posts - 331 through 345 (of 530 total)