Suddenly lightswitch is giving us a database error when deploying. We are deploying to Azure DB and hosted on Azure as well. We have not changed any of the deployment options but the error we're getting is:
Basically your issue is... After you first published your LS app to Azure and the data tables were first created in Azure SQL you modified the data table in your LS project in a way that your changes cannot be made on the Azure SQL instance automatically.
Did you change any existing fields that were created in the database when you first published? Like change field type from string to Integer?
If you change a field type directly on the SQL server it may warn you that you will lose data.. This is the same case except if this happens during publish it will error out with this Multi-user error.
If you make a field required that was not required before and there are already records in the database where the field is emtpy it will not let you convert it untill every existing record already has data in that field.
If you change a field type you need to make sure there is no data in that field in Azure SQL database or the field cannot be converted automatically during publish. Its a conflict.
Also, if you rename table columns in Lightswitch you should go into the SQL manager of Azure and manually change the fields there before you publish.. or you will create new fields in the database and the existing information will be in the old field.
Proposed As Answer byOrloafFriday, July 13, 2012 10:14 PM
Edited byOrloafFriday, July 13, 2012 10:24 PMClarification
I'm getting it as well. seems like an issue IMHO - whole point of Lightswitch is RAD and Refactoring. It would be very useful to know what table/column is causing this so we can attempt to patch the Azure database. I've just added about 10 new tables and
refactored a few existing ones.
I wish someone like Beth Massi would take note of this.
Edited byemtoppingMonday, August 13, 2012 11:13 PM