database-connection

Unable to connect to sql database using System.Data.SqlClient 4.4.3 and hostname but ip works

Deadly 提交于 2020-08-09 08:15:44
问题 I have tried running this in a asp.net core 3.1 app inside a docker container based on mcr.microsoft.com/dotnet/core/sdk:3.1-bionic (Ubuntu 18.04). also tried with mcr.microsoft.com/dotnet/core/sdk:3.1-buster. I'm trying to connect to a database with the following code: using var connection = new SqlConnection(connectionString); connection.Open(); If i use an ip adress it works fine. If i run this outside of a docker container it works fine. If i run in a container and use System.Data

Unable to connect to sql database using System.Data.SqlClient 4.4.3 and hostname but ip works

南笙酒味 提交于 2020-08-09 08:15:35
问题 I have tried running this in a asp.net core 3.1 app inside a docker container based on mcr.microsoft.com/dotnet/core/sdk:3.1-bionic (Ubuntu 18.04). also tried with mcr.microsoft.com/dotnet/core/sdk:3.1-buster. I'm trying to connect to a database with the following code: using var connection = new SqlConnection(connectionString); connection.Open(); If i use an ip adress it works fine. If i run this outside of a docker container it works fine. If i run in a container and use System.Data

Connect to Postresql database from Google Colab

♀尐吖头ヾ 提交于 2020-08-03 09:46:09
问题 I am trying to connect my Google Colab to my Postgres DB. When I try to connect to from Jupyter Notebook it's working, so I'm guessing that my credentials are fine. This is the error that I got: could not connect to server: No such file or directory Is the server running locally and accepting connections on Unix domain socket "/var/run/postgresql/.s.PGSQL.5432"? How can I solve it? My Postgres running on my machine. Thanks! 回答1: You can also install PostgreSQL in Colab. # install !apt install

Cannot establish connection with AWS RDS Oracle database instance from Oracle SQL Developer

主宰稳场 提交于 2020-07-10 09:27:19
问题 I created an Oracle database in the AWS RDS console. I'm unable to connect to it from the Oracle SQL Developer program despite following all the instructions in the Amazon Developer Guides (see item #3 in this webpage in particular). I get this error: IO Error: the network adapter could not establish the connection (vendor code 17002). I have opened Port 1521 in my firewall settings. Screenshots of my SQL Developer connection properties pane and the database properties from the AWS RDS

how to solve java.net.SocketException: socket failed: EPERM (Operation not permitted)

ε祈祈猫儿з 提交于 2020-07-10 03:38:05
问题 When I was using my Android Studio to create a simple registration to my local database I met the problem that shows on the title, and here is my code: public class registerInterface extends AppCompatActivity { private EditText editTextUsername, editTextPassword, editTextEmail; private Button buttonRegister, backToLogin; private ProgressDialog progressDialog; @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.registration

How do I solve “Keyword not supported: 'metadata' ”?

我的梦境 提交于 2020-07-06 10:46:47
问题 I can't connect to SQL Server and connection string of my project is: <add name="Teleport_DEVEntities" connectionString="metadata=res://*/Data.Model.AdvertisingModel.csdl|res://*/Data.Model.AdvertisingModel.ssdl|res://*/Data.Model.AdvertisingModel.msl;provider=System.Data.SqlClient;provider connection string="data source=*****;initial catalog=****;integrated security=True;MultipleActiveResultSets=True;App=EntityFramework"" providerName="System.Data.EntityClient" /> I get this error: Keyword

How do I solve “Keyword not supported: 'metadata' ”?

不羁的心 提交于 2020-07-06 10:46:20
问题 I can't connect to SQL Server and connection string of my project is: <add name="Teleport_DEVEntities" connectionString="metadata=res://*/Data.Model.AdvertisingModel.csdl|res://*/Data.Model.AdvertisingModel.ssdl|res://*/Data.Model.AdvertisingModel.msl;provider=System.Data.SqlClient;provider connection string="data source=*****;initial catalog=****;integrated security=True;MultipleActiveResultSets=True;App=EntityFramework"" providerName="System.Data.EntityClient" /> I get this error: Keyword

How to connect SqliteDB using BLToolkit on ASP.NET?

拥有回忆 提交于 2020-06-28 14:33:39
问题 Hi i got an error while connection to my sqlitedb. I create my sqlitedb using Firefox Sqlite Addon. MyConn : (webconfig) <connectionStrings> <add name="TARKMANCAS_CONNECTION" connectionString="Data Source=C:/TARKMANCAS_DB.sqlite;"/> </connectionStrings> MyClass: public TarkBaseDb() : base("TARKMANCAS_CONNECTION") { } // start // public Table<TarkBaseSchema.KadroGrubuCls> KadroGrubu { get { return GetTable<TarkBaseSchema.KadroGrubuCls>(); } } TarkBaseSchema: [TableName("EGITIM_KADROSU_GRUBU

.NET Core 2 - Connection string with instance name and port number

这一生的挚爱 提交于 2020-06-28 08:15:47
问题 In my application I have a connection string in the config. This application created using .NET core 2.11 and SQL Server. This is the connection string: Data Source=servername\instancename, portnumber;Initial Catalog=dbname;Persist Security Info=True;User ID=username;Password=password; This string causes an error as shown here: This error happens if I use instance name and port number in the string. If I remove either one, it is working. So, how do I make it work to used both instance name