Quantcast
Channel: Customized Commerce 13 and earlier versions
Viewing all articles
Browse latest Browse all 9642

The getting of prices is very slow

$
0
0

Hi.


Probable, somebody knows, why the getting of prices is very slow.


I get a price using IPriceDetailService.

var priceDetailService = ServiceLocator.Current.GetInstance<IPriceDetailService>();
int total;
var price = priceDetailService.List(productLink, marketId, new PriceFilter(), 0, 1, out total);


The command sends a request to sql server:(from sql profiler)

declare @p6 int
set @p6=1
exec ecf_PriceDetail_List @catalogEntryId=id,@catalogNodeId=default,@MarketId=N'marketId',@CurrencyCodes=@p4,@CustomerPricing=@p5,@totalCount=@p6 output,@pagingOffset=0,@pagingCount=1
select @p6

Reads - > 51 000

During - > 8 000

This request runs about 8 secs, when we execute from .net application. If we run this script using sql managment studio, we will spend < 1 sec.


I read the topic

http://stackoverflow.com/questions/2736638/sql-query-slow-in-net-application-but-instantaneous-in-sql-server-management-st


I tried to turn on the option(ARITHABORT). It helped me. But I am not sure, that this fix is a solution. Because We have this case for test db. And I don't have any problems for my local db.


Viewing all articles
Browse latest Browse all 9642

Latest Images

Trending Articles



Latest Images