Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    text
    copied!<p>Personally, this particular bug has been my nemesis for 3 weeks in various fashions. I have solved it in one part of my code base and it shows up elsewhere (I believe I finally squashed it tonight). The exception info is rather unhelpful, and a way to force a reindex would have been a nice feature given the lack of MS to solve the problem.</p> <p>I wouldn't look for MS's hotfix -- they have a KB article on it, then redirect you to an ASP.Net fix that is completely unrelated.</p> <p>Ok - enough complaining. Let's see what has actually helped me in resolving this particular issue in the various places I've encountered it:</p> <ul> <li>Avoid using Default Views, and modifying the Default View if possible. Btw, .Net 2.0 has a number of reader/writer locks on creating views, so they are not the issue they were pre 2.0.</li> <li>Call AcceptChanges() where possible. </li> <li>Be careful about .Select(expression), since there is no reader/writer lock in this code -- and it is the only place (at least according to a person on the usenet so take it w/ a grain of salt -- however, this is very similar to your issue -- so using Mutexes may help) </li> <li>Set AllowDBNull to the column in question (questionable value, but reported on the usenet -- I've used it only in places where it makes sense)</li> <li>Make sure that you are not setting null (C#)/Nothing (VB) to a DataRow field. Use DBNull.Value instead of null. In <em>your</em> case you may wish to check that the field is not null, the expression syntax <em>does</em> supports the IsNull(val, alt_val) operator.</li> <li><p>This has probably helped me the most (absurd as it sounds): If a value is not changing, don't assign it. So in <em>your</em> case use this instead of your outright assignment:</p> <p>if (column.Expression != "some expression") column.Expression = "some expression";</p></li> </ul> <p>(I removed the square brackets, not sure why they were there).</p> <p>Edit (5/16/12): Just ran into this issue repeatedly (with an UltraGrid/UltraWinGrid). Used the advice of removing the sort on the DataView, and then added a sorted column which matched the DataView sort, and this resolved the issue.</p>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload