11 Replies Latest reply on Mar 3, 2020 2:12 AM by Christian.Shay -Oracle

    VS 2019 - Problems with Entity Framework wizard disappearing

    4141867

      I am using the shiny new ODT 19.3 via VS 2019.

      When ever I try to open the Entity Framework wizard to create a model from a existing DB the wizard closes without any feedback.

       

      Steps:

      1. Add new ADO.NET Entity Data Model

      2. EF Designer from database

      3. Choose Your Data Connection and click Next

      4. BOOM

       

      ODT19.3Bug.PNG

       

      I am using the following Nuget Packages:

      - "Oracle.ManagedDataAccess" version="19.6.0"

      - "Oracle.ManagedDataAccess.EntityFramework" version="19.6.0"

       

      Microsoft Visual Studio Community 2019

      Version 16.4.4

       

      Are there any ODT logfiles? and if so where?

       

      Thanks

        • 1. Re: VS 2019 - Problems with Entity Framework wizard disappearing
          00c5c286-c445-4d08-80ed-c205a3487ff8

          I was getting the same issue!

           

          But I was using the following Nuget Packages:

          - "Oracle.ManagedDataAccess" version "18.3"

          - "Oracle.ManagedDataAccess.EntityFramework" version "18.3"

          - "EntityFramework" version "6.1.3"

           

          Microsoft Visual Studio Professional 2019 version 16.4.5

          ODT 19.3 via Tools for Visual Studio 2019 version 19.3

           

          Exact same issue you were having.

           

          I then updated

          "Oracle.ManagedDataAcces" to version "19.6"

          "Oracle.ManagedDataAccess.EntityFramework" to version "19.6"

           

          This got me a new page on Step three of the steps in OP's post, but it basically said EntityFramework is out of date.

          Sorry I didn't get a screen grab.

           

          I then updated

          "EntityFramework" to version "6.4.0"

           

          And it is now working.  Luckily this project is relatively new and I have the ability to update everything to the latest.

           

           

          packages.config

          <?xml version="1.0" encoding="utf-8"?>

          <packages>

            <package id="EntityFramework" version="6.4.0" targetFramework="net48" />

            <package id="Oracle.ManagedDataAccess" version="19.6.0" targetFramework="net48" />

            <package id="Oracle.ManagedDataAccess.EntityFramework" version="19.6.0" targetFramework="net48" />

          </packages>

          • 2. Re: VS 2019 - Problems with Entity Framework wizard disappearing
            4141867

            Sorry, but as hard I try I can't get this to work.

             

            I tested all kind of combinations:

            EntityFramework (6.0 to 6.4) and Oracle.ManagedDataAccess (18.3 to 19.6)

             

            Also updated the target .Net Framework to 4.8.

            My package config:

             

            Used also a separate fresh machine with the latest Visual Studio Version Community (16.4.5).

             

            Maybe it has to do with the connection. I am using a connection to a ATP Cloud Instance:

            I also tested with a normal paid cloud instance.

             

             

            Christian.Shay -Oracle Can someone please provide a working sample:

            Oracle.ManagedDataAccess.EntityFramework connected to ATP Always Free DB Instance

             

            Thanks

            • 3. Re: VS 2019 - Problems with Entity Framework wizard disappearing
              4068057

              I use

              Microsoft Visual Studio Professional 2019

              Version 16.4.5

              Oracle database 11g.

               

              I tried EF 6.1.3 , 6.2 , .6.4

              - "Oracle.ManagedDataAccess"  from version "12." to the newest

              - "Oracle.ManagedDataAccess.EntityFramework" from version "12.x"  to the newest.

              Many combinations.  All of them don't work .

               

              Any ideas what to do ?

              • 4. Re: VS 2019 - Problems with Entity Framework wizard disappearing
                Graham Arthur

                I'm having the same problem. We are developing a web application in VS2013 and are moving over to VS2019 and when I try and go to the .edmx diagram, right click and select 'Update Model From Database', select the connection and click 'Next' it tries to open a screen to select a version of Entity Framework, but then crashes. I've got the following

                 

                VS2019 Professional 2019 Version 16.4.5

                Entity Framework Version 6.0.0.0

                 

                Oracle Developer Tools 19.3 which contains :-

                Oracle Managed Data Access Version 4.122.19.1

                Oracle Managed Data Access Entity Framework Version 6.122.19.1

                 

                We are using Oracle Version 12.1 as the database

                 

                I've tried deleting the old version of the Oracle packages from VS2013 and just having the ones from VS2019, changing the machine.config file, changing the web.config, changing the app.config, but nothing seems to be working. Could someone at Oracle please look into this, because there is clearly a major issue with this and it is going to be affecting a lot of people

                • 5. Re: VS 2019 - Problems with Entity Framework wizard disappearing
                  4141867

                  I also tested ODT 19.3 + Visual Studio 2017.
                  With the same result: The entity framework wizard disappears next to the "Choose Your Data Connection" step.

                  Please Oracle, help us and provide a solution!

                  • 6. Re: VS 2019 - Problems with Entity Framework wizard disappearing
                    Christian.Shay -Oracle

                    Hi all,

                    Thanks for all your help raising this issue. We are working with Microsoft to try to resolve it. As soon as I have a workaround or more information, I will post again here to let you know.

                    Thanks,

                    Christian

                    • 7. Re: VS 2019 - Problems with Entity Framework wizard disappearing
                      Christian.Shay -Oracle

                      4141867 wrote:

                       

                      I am using the shiny new ODT 19.3 via VS 2019.

                      When ever I try to open the Entity Framework wizard to create a model from a existing DB the wizard closes without any feedback.

                       

                      Steps:

                      1. Add new ADO.NET Entity Data Model

                      2. EF Designer from database

                      3. Choose Your Data Connection and click Next

                      4. BOOM

                       

                      ODT19.3Bug.PNG

                       

                      I am using the following Nuget Packages:

                      - "Oracle.ManagedDataAccess" version="19.6.0"

                      - "Oracle.ManagedDataAccess.EntityFramework" version="19.6.0"

                       

                      Microsoft Visual Studio Community 2019

                      Version 16.4.4

                       

                      Are there any ODT logfiles? and if so where?

                       

                      Thanks

                      Hi,

                      Could you please let me know the following?

                       

                      1) Is the Server Explorer connection using TNS alias or Basic (ezconnect) for the connection ?

                       

                      2) If the Server Explorer connection is using TNSAlias, is it using tnsnames.ora from the default location (%USERPROFILE%\Oracle\network\admin) ?  Or is it in some other location?

                      • 8. Re: VS 2019 - Problems with Entity Framework wizard disappearing
                        4141867

                        Hi Christian, thanks for helping out.

                         

                        1) Is the Server Explorer connection using TNS alias or Basic (ezconnect) for the connection ?

                        - It is using "TNS Alias":



                        2) If the Server Explorer connection is using TNSAlias, is it using tnsnames.ora from the default location (%USERPROFILE%\Oracle\network\admin) ?  Or is it in some other location?
                        - As u can see it uses: "%USERPROFILE%\Oracle\network\admin\AlwaysFreeDB2"
                        There is a tnsnames.ora with the following connection string:

                        alwaysfreedb2_high = (description= (retry_count=20)(retry_delay=3)(address=(protocol=tcps)(port=1522)(host=adb.eu-frankfurt-1.oraclecloud.com))(connect_data=(service_name=aklhtl00etaacqi_alwaysfreedb2_high.atp.oraclecloud.com))(security=(ssl_server_cert_dn="CN=adwc.eucom-central-1.oraclecloud.com,OU=Oracle BMCS FRANKFURT,O=Oracle Corporation,L=Redwood City,ST=California,C=US")))

                         

                         

                        I also tested the same setup with an Oracle 11g instance using EZConnect and it is working.

                        As far as I know u can't use an ATP instance with "EZConnect"?

                         

                         

                        Thanks,
                        Andreas

                        • 9. Re: VS 2019 - Problems with Entity Framework wizard disappearing
                          Christian.Shay -Oracle

                          Thank you!

                           

                          We have one workaround for this issue now - if the TNSNAMES.ORA and wallet files are located in the default location this error will not occur.

                           

                          On installation, the default location is %USERPROFILE%\Oracle\network\admin. The default is also changeable in the options page.

                           

                          So, you can do one of two things:

                           

                          1) Backup contents of %USERPROFILE%\Oracle\network\admin, then delete the contents of this directory.

                          2) Copy the tnsnames.ora, sqlnet.ora and wallet files to this location

                          3) Restart Visual Studio

                           

                          Or

                          1) Go to VS menu, Tools->Options->Oracle Developer Tools ->Connection Configuration and set Tns admin location to the location you want to connect from. Also set wallet file location as well.

                          2) Restart Visual Studio

                          • 10. Re: VS 2019 - Problems with Entity Framework wizard disappearing
                            4141867

                            Hi Christian,

                             

                            Thank you for providing this workaround. It works just fine.
                            I tested some simple scenarios (create & update model from ATP database) without any problems.

                            The same applies to ODT 19.6 for Visual Studio 2017.

                             

                            Thanks again and best regards

                            Andreas

                            • 11. Re: VS 2019 - Problems with Entity Framework wizard disappearing
                              Christian.Shay -Oracle

                              4141867 wrote:

                               

                              Hi Christian,

                               

                              Thank you for providing this workaround. It works just fine.
                              I tested some simple scenarios (create & update model from ATP database) without any problems.

                              The same applies to ODT 19.6 for Visual Studio 2017.

                               

                              Thanks again and best regards

                              Andreas

                               

                              Hi,

                              I need to add another comment:

                               

                              The workaround I provided will avoid the crash and allow the EF model to be added to your project, but please be aware that ODP.NET in that project will not automatically be able to find the location of your tnsnames.ora and wallet files. You will need to set TNS_ADMIN and (if needed) WALLET_LOCATION in the config file (eg app.config, or web.config) or include the TNSNAMES/SQLNET.ORA/WALLET/etc in the root of your project. In future releases these values will be set in the ODP.NET connection string automatically and you will not have to do this.