none
LINQ Performance between different database RRS feed

  • Question

  • Hi,

    I have a problem here, i have difference in performance if point to different database hosted in same sql server instance.

    Example,
    I have database 'A', and i restore database 'A' to database 'B'.
    In my application, i am using LINQ to call a store procedures in database 'A', i have tried with using LINQ to call a store procedures in database 'B' as well. But the speed to retrieve data is much faster in 'B' compared to 'A'

    The data is same because i restored the data, and they host in same sql server instance as well, just the database name is different. This result is weird to me.

    May i know is there any others thing might cause different in performance?

    In my store procedure, i am using #temp table to store data, could it be root cause?
    Because this store procedure will be triggered quite frequently, and can be accessed by many user at the same time.

    Tuesday, May 20, 2014 3:34 AM

All replies

  • Hello,

    Is it always that the speed to retrieve data is much faster in 'B' compared to 'A'? I assume that you made the test first with database A, and then database B, if you try to test with database B firstly, what is the result, if A is faster that B, then I think the result may be cached by sqlsever.

    If I am not correct, please point it and let me know.

    Regards.


    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click HERE to participate the survey.

    Tuesday, May 20, 2014 8:20 AM
    Moderator