none
This database cannot be imported. It is either an unsupported SQL server version or an unsupported database compatibility RRS feed

  • Question

  • Hello,

    I have built a Windows App in VB Net and the application has been fetching data from a database in a server installed on the same machine. Now when I decided to deploy it, I had to transfer the database into the application (akin to creating an .mdf file). I also changed the connection string accordingly, and everything worked pretty well...(or so it appeared). A few tweaks later, I realized the application wasn't updating the tables in my newly created .mdf database but all queries returned no exceptions. When I attempt to refresh the tables manually, I get this error "This database cannot be imported. It is either an unsupported SQL server version or an unsupported database compatibility" Please if anyone knows how to fix this, I'll appreciate.

    In addition, prior to discovering this issue, I had been stuck on how to create a connection to Crystal Reports for reporting with my App. How do I get to successfuly link CR with an .mdf file?

    Thank you.

    Sunday, October 13, 2019 5:27 PM

All replies

  • Hi Wambua,

     

    >>This database cannot be imported. It is either an unsupported SQL server version or an unsupported database Compatibility

     

    Visual Studio sometimes uses TWO databases: one is in the source folder and it is used at design time; the other is in the binaries folder, and is accessed by the program at runtime. Every time you run your project from Visual Studio, the design-time database is copied into the runtime database. Therefore, even if the program correctly saves the data in the runtime database, you will not see this information if you examine the design-time database. And the changes will be overwritten from the source the next time you run the program. If you don't want this behavior, you can modify it by clicking on the database file in Solution Explorer and selecting an option other than "Copy Always". Or edit the connection string and point it to the design-time database.

     

    >>In addition, prior to discovering this issue, I had been stuck on how to create a connection to Crystal Reports for reporting with my App. How do I get to successfuly link CR with an .mdf file? 

     

    Please refer to https://stackoverflow.com/questions/10143647/how-to-attach-mdf-file-to-crystal-reports

     

    Best regards,

    Dedmon Dai


    MSDN Community Support
    Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com

    Monday, October 14, 2019 2:40 AM