Forum Replies Created

Viewing 15 posts - 5,266 through 5,280 (of 5,393 total)

  • RE: Data Archiving

    I don't know if this is exactly what you desire to achieve, but you could take a look at table partitioning. There's an interesting article in technet that could help...

  • RE: How to increase performance over WAN?

    Poor performance is due to data tranfer between SQL Server and client application. There's no simple solution: in some way you will have to change your application or your system...

  • RE: Union all with order by not working

    Try this:

    SELECT *

    FROM (

    select '0' + dbo.date_format(getdate(), 'MMDDYY') AS End_Date

    union all

    select

    '1' +

    CONVERT(varchar, dbo.date_format(mt.end_date, 'MMDDYY')) +

    left(right('0000000'+mt.client_num, 7) + '.' + right('0000000'+mt.matter_num, 7) + ' ...

  • RE: Looking for operator to coerce char values to '0' or '1'

    SQLServer translates COALESCE in CASE / WHEN, so it would be exactly the same to do:

    CASE

    WHEN field IS NULL THEN '0'

    WHEN...

  • RE: SQL Server Develepment

    varchar with no length means varchar(1), so you'll get 1 as result.

    Gianluca

  • RE: SQL Performance

    Thanks Gail,

    I have a new top ranked item for my to-do list today...

  • RE: SQL Performance

    Thank you very much Gail, I didn't know about page splits!

    I use sometimes NOLOCK when my data is partially static and I need to read only the static part, avoiding...

  • RE: SQL Performance

    GilaMonster (3/11/2009)


    NOLOCK allows for a possibility of missing rows or reading rows twice.

    Gail, what do you mean "reading rows twice"? I know I could miss some rows with NOLOCK,...

  • RE: Update with a join where more than one value can be returned

    Try this:

    UPDATE TempFactTable

    SET CodeID = LookupID

    FROM TempFactTable t

    INNER JOIN (

    SELECT LookupCode, MAX(LookupID) AS LookupID, MAX(OtherCode) AS OtherCode

    FROM LookupTable

    ...

  • RE: Determining Case sensitive

    You can query the ASCII code for the first char:

    'a' is different from 'A'

    try this:

    SELECT ASCII('A')

    SELECT ASCII('a')

    One thing you could do is:

    SELECT *

    FROM MyTable

    WHERE ASCII(LEFT(FirstName,1)) <> ASCII(LEFT(UPPER(FirstName),1))

    Onether thing you...

  • RE: sqlservr.exe uses 100% CPU

    Your result set is too big. Work on the server side.

  • RE: SQL Performance

    If you're sure every user works only on his data, try putting some NOLOCK in the select satements to avoid table and page locking during reads.

    With this little information this...

  • RE: SQL Performance

    It depends! What does the procedure do? Does it select or modify data?

    Gianluca

  • RE: sqlservr.exe uses 100% CPU

    Babar Javaid (3/11/2009)


    The used SP return the aggregate data and i am calling the SP 5 million times. One time call return the whole data to code and code do...

  • RE: sqlservr.exe uses 100% CPU

    If you can alter the stored procedure code, aggregate the data with the appropriate group by clause, in order to get the data formatted the same way you need to...

Viewing 15 posts - 5,266 through 5,280 (of 5,393 total)