Forum Replies Created

Viewing 15 posts - 676 through 690 (of 921 total)

  • RE: Complicated SQL command

    Based on your stored procedure, I take it the priority is actually (di_Priority DESC, di_discount_rate DESC). Couldn't you just use something like this?

    
    
    DECLARE @bs_Id int
    SET...
  • RE: Unique Constraint on a SUBSTRING?

    If you're using SQL Server 2000, you could use a UDF in a check constraint. Otherwise you could use a trigger.

    --Jonathan

  • RE: cascading deletes

    quote:


    Really, the fastest way to do deletes is not to have any FK contraints at all.

    🙂

    I know this sounds...

  • RE: Character Comparision

    As you're comparing characters, each is considered separately. Any letter character has an ASCII value greater than that of a number character. Perhaps you want something like this:

  • RE: Licensing - CALS

    It depends. There are two types of CAL: User or Device.

    http://www.microsoft.com/sql/howtobuy/sqlserverlicensing.asp

    --Jonathan

  • RE: NULL vs. Empty String

    My rule is to only make a column nullable if it truly needs to hold "unknown" values. Nullable columns will force you to use ternary predicates with NULL logic...

  • RE: Which query is faster and why?

    quote:


    The data type of both the fields (field_1 and field_2) is varchar and the index create was a clustered index.

    Execution Plan: Though...

  • RE: Which query is faster and why?

    quote:


    Hi Jonathan,

    I also thought exactly same at first but I tested both the queries with 40000 records in table_A, I tried without...

  • RE: Which query is faster and why?

    The first will be slightly faster assuming it uses no implicit conversions. An exact equivalence will also be faster than a range (e.g. BETWEEN) operation.

    The first will be much...

  • RE: Wrong Index

    quote:


    I think you've already cleared this 'parameter sniffing' by updating the statistics.


    I don't believe that...

  • RE: Wrong Index

    quote:


    Any way to clear this "parameter sniffing"?


    Yes, recompile the stored procedure. It will then...

  • RE: Wrong Index

    quote:


    Still don't know what the problem actually is, but somehow it is disappearing from selected databases. There is no rhyme or reason...

  • RE: cascading deletes

    quote:


    interesting.

    what about a situation where u have, for one process, 2000 sp calls to delete FK records. Would cascading deletes be faster...

  • RE: Update

    quote:


    Both servers Sql server7.0 Standard Edition...


    I thought something like that was the case. A...

  • RE: differential backup newbie question

    There are many cases where a differential backup could be larger than the previous full backup:

    • Many rows have been added. If your database consisted of a few tables...

Viewing 15 posts - 676 through 690 (of 921 total)