Calling all developers! We invite you to provide your input on Feature Experimentation by completing this brief survey.
Calling all developers! We invite you to provide your input on Feature Experimentation by completing this brief survey.
An update, but still not a fix:
I was able to decompile the code to figure out what is throwing that error and traced the problem back to this line in EPiServer.Data.Dynamic.Providers.ColumnInformationMapper.Map().
columnInformation = rows[index].GetColumn(dataType, requireIndexed, true);
It's trying to find a datatype that is "Int32" and also is required to be indexed. I don't think it's finding the right mapping because it's not finding any indexable Int32 property types.
The reason it's passing requireIndexed
as true is the line just before the one above.
bool requireIndexed = parameters.IndexNames.Contains(key);
parameters
in this case is the tblBigTable and the IndexNames
property contains only one key: "ProjectId".
I can't find where tblBigTable has stored any information that populates IndexNames with ProjectId, though. I think my next step is to continue to decompile code to find how that property is populated. Perhaps I can find a SQL statement that shows something useful.
I even set up appsettings.json with this entry to auto-remap the DDS, but it didn't fix the issue.
"EPiServer": {
"Cms": {
"DynamicDataStore": {
"AutoResolveTypes": true,
"AutoRemapStores": true
}
}
}
I figured it out. The tblBigTable was missing indexes.
From another CMS 12 database:
I bet this happened during one of the version updates before I was brought onto the project. A lot of similar posts from before 2018 said this happens when the scripts are run during the upgrade process, so that's probably what happened here.
My solution was to use SSMS to build a CREATE INDEX scripts based on the other CMS 12 database and I run them in the other database. Once the indexes were created, the error went away. Also, the CMS is a lot more responsive now. We used to have issues with the Content Tree not loading until you refreshed the page, but I haven't seen that since I made this fix. Hopefully, it was related.
We are upgrading a v11 CMS to v12. When running the v12 solution, the following error is logged every time the solution is run.
Could not map property ProjectId - table tblBigTable does not contain any columns that map to DbType.Int32
My understanding is that ProjectId is supposed to be stored in the DDS, but it's not configured correctly.
The only other hits I find online about this issue refer to not upgrading the database correctly and scripts not running, however, that's not an issue with v11 -> v12 upgrades since we don't have to upgrade the database manually.
I also wonder if there's a missing entry in the tblBigTableStoreInfo table for "ProjectId". That would explain the error trying to map to Int32 since that table has PropertyName (eg "ProjectId") and PropertyType (eg "System.Int32") as well as ColumnName (eg "Integer01"). It looks like a table that would map properties to types.
I'm very interested in finding a solution for this because it seems ProjectId isn't being stored in the DDS as expected.