I'm creating an application in ASP.NET 5 and need to deploy the same in Bluemix. I would want to connect to IBM SQL Database in Bluemix.
I'm trying to use ODBC to connect to IBM SQL Database. But, when I build my application in Visual Studio 2015, it throws compiler error.
This is the error that I'm getting.
The type or namespace name 'Odbc' does not exist in the namespace
'System.Data' (are you missing an assembly reference?)
Visual Studio shows that the System.Data.Odbc is available in DNX 4.5.1 but unavailable in DNX Core 5.0 and hence it throws the error.
I'm stuck and unable to proceed further.
What should I do to be able to use the ODBC connection?
Can anyone please help.
Related
I tried install Asp.net Zero Power Tools for my project.(https://docs.aspnetzero.com/en/common/latest/Rapid-Application-Development)
The Tool installed but when I try load entity from database and then connect to my postgresql database,I give an error.
This error is;
enter image description here
For this error, I installed "System Threading Channels 5.0.0" with Nuget Package Manager. But I still give the error.
Also, They says .NET Core 2.2 Runtime as a pre requirements on the site https://docs.aspnetzero.com/en/common/latest/Rapid-Application-Development. But when I try install .NET Core 2.2 Runtime, they says .NET Core 2.2 Runtime "This release has reached end of life, meaning it is no longer supported". Can you help me?
My Versions are;
.NET 5.0 Runtime
.NET Core 2.1 Runtime
Visual Studio 2022
Thank you.
I have just installed Entity Framework Power Tools Beta 4 into Visual Studio 2013. I am running a .NET framework 4.5 project, using Entity Framework code first with an Oracle database. I have installed the latest ODP.NET from Oracle (version 12), including the EF drivers, and I have Oracle.ManagedDataAccess and Oracle.ManagedDataAccess.EntityFramework referenced in my project.
This set up allows me to run my project and read and access data from the Oracle database. It all works fine. My problem is when I try to use the Entity Framework Power Tools. I can specify a connection using the Oracle database name and credentials, and the dialog says 'Test Connection succeeded'. However, after clicking the next button, I get the following error:
System.Data.ProviderIncompatibleException: The store provider factory type 'System.Data.OracleClient.OracleClientFactory' does not implement the IServiceProvider interface. Use a store provider that implements this interface.
I am confused because my project is able to use the installed ODP.NET as is to communicate with the Oracle database via Entity Framework. Most of the research I have done on the WWW suggests there should be a problem with versions and the contents of the web.config - but if this is the case surely I wouldn't be able to use EF with Oracle in my project without errors?
Is it just the case that the Power Tools do not work with Oracle?
Cheers!
Martin
As Christian says in his comment, you need to install ODP.NET as a provider that Power Tools can use. I did this by installing Oracle Developer Tools for Visual Studio.
I installed NpgsqlDdexProvider-3.1.0, through NuGet added to the project packages Npgsql v.3.0.5, EntityFramework5.Npgsql v.3.0.5, EntityFramework v.5.0.0. I try to add connection to database via Server Explorer and get error:
Failed to find or load the registered .Net Framework Data Provider
My data provider: .Net Framework Data Provider for PostgreSQL (Npgsql Ddex Provider)
My connection string:
Host=localhost;Username=postgres;Password=1;Database=postgres;
How to fix it?
You must add provider's dll to GAC and assemble of your IDE.
Environment:
IBM MobileFirst 7.1
IBM Liberty Core 8.5.5
IBM DB2 10.5
0 Windows Server 2012 R2
While installed the IBM Mobile First 7.1 platform, in Database Creation request step, I am getting message No DB2 instance found on the server.
However on db2ilist it returns default instance as "DB2".
Any idea why it's not listing while Mobile First installation in database creation step?
This question may be a duplicate of: IBM Worklight 6.2 Server Deployement error: DB2 Instance not found on server
As the answer mentions, it seems the Server Configuration Tool may not able to create the database for your specific topology. You should then create it manually before running the tool. For instructions, see: https://www-01.ibm.com/support/knowledgecenter/SSZH4A_6.2.0/com.ibm.worklight.installconfig.doc/admin/t_creating_the_db2_database_for_wladmin.html
For the Project Runtime databases, the doc is here: IBM Worklight 6.2 Server Deployement error: DB2 Instance not found on server
I am trying to connect PostgreSQL from .net core Server Explorer using Npgsql 4.1.1. But it is throwing exception Could not load file or assembly 'System.Runtime.CompilerServices.Unsafe'.
I tried installing earlier version of Npgsql but, still the same exception.