Could you hire me? Contact me if you like what I’ve done in this article and think I can create value for your company with my skills.

December 13, 2007 / by Zsolt Soczó

Tapasztaltok egy 35ezer tranzakció/mp-es rendszer implementációjából

Na, nem én csináltam, sajnos nálunk nem nagyon van ilyen, bár, ha tudtok róla, jelezzétek. Mobilosoknál talán van valami hasonló terheltségű db, de az Oracle.

Szóval, nagyon-nagyon jó post a témában, pár meglepő fordulattal, pl.

Néha nem a legszebb megoldás a legjobb:
“When developing the upsert proc prior to tuning the indexes, I first trusted that the If Exists(Select…) line would fire for any item and would prohibit duplicates. Nada. In a short time there were thousands of duplicates because the same item would hit the upsert at the same millisecond and both transactions would see a not exists and perform the insert. After much testing the solution was to use the unique index, catch the error, and retry allowing the transaction to see the row and perform an update instead an insert.”

A CLR implementáció bukása, talán az interop költségek miatt?

“This app requires that several hundred “items” are passed into the stored procedure for processing as a set. I chose to input the data as comma delimited VarChar(max), originally using Erland’s iterative string2set function to parse string into a set inside the proc. It worked well enough. The plan was to substitute a CLR function near the end of development. When the time came, the CLR function ran blazingly fast on my notebook, but under stress it was painfully sloooooow. I didn’t understand at all why. This is exactly what we were told by Microsoft the CLR was for. Pass string data in, manipulate it, pass it back – no data access – sounds great right? In a few emails to my friend Adam, he told me he had the same issues a while back and the CLR simply could keep up with the marshalling of the VarChar(max).”

Stb. Nagyon jó cikk.

Could you hire me? Contact me if you like what I’ve done in this article and think I can create value for your company with my skills.