Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Lars Fagerbakke 2 posts 22 karma points
    Jan 28, 2015 @ 09:08
    Lars Fagerbakke
    0

    I'm missing my views

    Hello!

    Yesterday I created a new project. It is just a test thingy so I'm using SQLCE and the database is saved to App_Data\Umbraco.sdf.

    Today strange things happened. When I run the application and log in to the backoffice all my views are gone. I created several yesterday with new document types. They are gone. If I  browse the file structure I find them where they belong, under Views/. In the backoffice I tried to reload but it did not find the files for some reason.

    Is there a way to load them in again? I'm using Umbraco 7.2.1.

  • Jan Skovgaard 11280 posts 23678 karma points MVP 11x admin c-trib
    Jan 28, 2015 @ 09:26
    Jan Skovgaard
    1

    Hi Lars and welcome to our :)

    Unfortunately there are issues when using CE SQL with IIS express. Please see this issue http://issues.umbraco.org/issue/U4-4621

    So the views have not been created in the database - What you can do is setup an IIS site using a local hostname and point it to your Umbraco folder and keep using CE SQL or you can migrate CE SQL to MSSQL instead. That way you should not loose any data in the future.

    Once that is done you can recreate your views in the backoffice. But before doing so make sure to temporarily remove the view files and store it another place untill you have recreated the views. Then you can overwrite the new view files with the backed up ones. If you don't do it I think it can lead to a mess where Umbraco will be confused etc.

    I hope this helps.

    /Jan

  • Dennis Aaen 4500 posts 18255 karma points admin hq c-trib
    Jan 28, 2015 @ 09:28
    Dennis Aaen
    0

    Hi Lars, and welcome to our :)

    I have seen some people have trouble using IIS Express and SQL CE, where they experience loss of data, I know there is a issue on the issue tracker
    http://issues.umbraco.org/issue/U4-4621 You could try look at this and see if someone has found a solution.

    I also often see people recommend to use the MS SQL for live environment, and the SQL CE database is good for getting quick into Umbraco, or if you need to do a quick proof of concept on something.

    Sad to hear that you have trouble with Umbraco,

    Hope this helps,

    /Dennis

  • Lars Fagerbakke 2 posts 22 karma points
    Jan 28, 2015 @ 10:06
    Lars Fagerbakke
    0

    Thank you for your feedback Jan and Dennis!

    Quick follow up: is the best scenario a centralized database (MySQL) that I can reach wherever (Azure <3)? I'm developing on multiple computers (regular pc and surface for sofa-time-with-the-wife :P). Having MySQL installed on each of them and maintaining them would kill productivity, if I have to update database scheme. In that respect SQLCE is great as there is no problem for me to git the database (single person project going on here :-)), but if the caching is crap then I cant really use it if does not commit stuff from cache or whatever.

  • Dennis Aaen 4500 posts 18255 karma points admin hq c-trib
    Jan 28, 2015 @ 10:11
    Dennis Aaen
    0

    Hi Lars,

    I would not recommend you to try use MySQL database, I donĀ“t think that the MySQL database has get much attention since the SQLCE database was introduced in Umbraco 4.6, if I remember correctly. So if I was you I would use an MSSQL. if you see the system requirements for Umbraco 7 http://our.umbraco.org/documentation/installation/system-requirements then you will see that the databases that are supported is Microsoft SQL Server and the bult in SQL CE.

    /Dennis

  • Jan Skovgaard 11280 posts 23678 karma points MVP 11x admin c-trib
    Jan 28, 2015 @ 10:32
    Jan Skovgaard
    0

    Hi Lars

    MySQL is not a good choice since it has not gotten much TLC for a long time and most 3rd party packages does not support it either, which means that even if you did get Umbraco up and running on MySQL then you would not be able to use packages that only support MSSQL.

    So as Dennis is saying SQL CE is good for quickstarting a project but if you install a package that needs to connect to the database it's no guarantee that SQL CE is supported either so before doing so I would recommend migrating to MSSQL, which is quite easy using Webmatrix for instance.

    In your scenario you would just need to connect to one database on another server than the one you're using for doing your local development of course. It does not make sense to have a DB instance for the same Umbraco installation across multiple machine since data, packages etc. will not be in sync then.

    I have not tried using Azure myself but the approach of having an external database is my preferred way of doing it.

    But as I mentioned in my post above you can keep using CE SQL - You just need to setup an IIS site pointing to the site. Then the data does not disappear. The issue is when using IISExpress and CE SQL in combination.

    You will then of course need to setup an IIS site for each of your machines but that should not take that long. Then you can keep the database as a part of your source control system. But be aware that the .sdf file can't be merged, which can lead to issues if you forget to push it before pulling the source down and making DB changes on another machine.

    Hope this makes sense.

    /Jan

Please Sign in or register to post replies

Write your reply to:

Draft