SqlCeCommand cache and rebuilding SqlCeCommand.Parameters
hello,
i caching sqlcecommand objects in data layer. after executenonquery etc clear sqlcecommand.parameters collection , add new instances of sqlceparameter on next execution.
does have impact on cached plans ? not observing performance improvement cache.
my plans being rebuilt every few minutes when after sync.
regards,
kamil nowicki
hi,
i'm not sure if helps, idea of preparing sqlcecommands improve performance define parameter's name, data type , length each needed parameter in commandtext instruction, invoke prepare method, , each time need execute command, have assign value each parameter. clearing parameter collection won't let take advantage of keeping sqlcecommand in memory between calls.
alberto silva microsoft mvp - device application development - http://msmvps.com/albertosilva moving2u - r&d manager - microsoft certified partner - mobility solutions - http://www.moving2u.pt
i'm not sure if helps, idea of preparing sqlcecommands improve performance define parameter's name, data type , length each needed parameter in commandtext instruction, invoke prepare method, , each time need execute command, have assign value each parameter. clearing parameter collection won't let take advantage of keeping sqlcecommand in memory between calls.
alberto silva microsoft mvp - device application development - http://msmvps.com/albertosilva moving2u - r&d manager - microsoft certified partner - mobility solutions - http://www.moving2u.pt
SQL Server > SQL Server Compact
Comments
Post a Comment