I am developing a Windows desktop app that connects to a Postgres database. When testing connections and environmental variables, I have been just going to Component Services and restarting the Postgres service. Does that reload pg_env.bat? What is the command prompt way of restarting the Postgres server and reloading a revised pg_env.bat? Thank you.
Related
Postgres db provisioned at Heroku runs out of DB connections very frequently which hinders debugging the application on local system.
While try killing the connection via Heroku CLI, nothing happens. It pops "Not Found" message. It seems the command is not able to locate the db within the heroku app.
Need some help on killing postgre DB connections, so as to debug the application.
I tried executing
heroku pg:info -a heroku-sizing-roi-dev
It returns
But the database is provisioned already with DB schema and tables created. I can browse the DB on heroku dashboard and connect it via Java application.
I m trying to restore a MongoDB dump file present on my windows machine into MongoDB server created inside azure portal as azure virtual machine, I have created this virtual machine and named it mongodbserver then I m connecting via SSH with the client for this case is the power shell CMD that I'm connecting with form my windows machine, now my questions are:
1.In order for me to restore MongoDB dump file where should it be in the server side? or either on my windows machine still I will be able to get it from there and restore it successfully in the server?
2.Can I use Filezilla client to move the database dump file into the server but the problem with this i don't have the password for the virtual machine created since I'm connecting via SSH and Filezilla will require password for it to connect.
3.After restoring the database successfully how can I connect this virtual machine with the MongoDB compass and also how can i get the database Uri in order for me to connect it with my spring application.
Any suggestions will be much appreciated!
I have developed a c# windows application which uses SQL server 2012 database in Visual Studio 2015 which is running well on my pc.
I am to install this application on a number of computers without SQL server installed on it, but when I run the application, its gives me database connection error.
My question is, how can I create the setup file to be able to run the app on those clients pc without installing SQL server on all those computers. Please I need your help.
Thank you.
Am Emmanuel.
Use an Azure database and have the clients connect to that.
Have a look at https://azure.microsoft.com/en-us/services/sql-database/
Alter your application connection string and make sure you keep the connection string secret.
Server=tcp:myserver.database.windows.net,1433;Database=myDataBase;User ID=mylogin#myserver;Password=myPassword;Trusted_Connection=False;Encrypt=True;MultipleActiveResultSets=True;
An important fact is that the clients need to allow communication via port 1433.
If this is not an option create an API application and query the database via that.
If you need a private database per client you can use a database file and connect to the file
https://learn.microsoft.com/en-us/sql/database-engine/configure-windows/sql-server-express-localdb?view=sql-server-ver15
Update based on reply
You can create a pop-up on the application allowing the users to add valid settings and credentials when your appsettings.json is blank or "a test connect" to the database fails.
I have an AWS server (MS SQL SERVER EXPRESS 2008 R2 with IIS), with an elastic IP of 54.214.8.111, security groups configured with HTTP, MS SQL and FTP, and I can connect to the remote virtual machine using the rdp file that amazon gives you in the console.
However when I try to connect via visual studio to test if the database is working, it gives me a "Login failed for user 'dbuser' error. I have a user called dbuser on my SQL Server (on the server side of course) with full access permissions etc. I also cannot connect to an ftp on the server, despite all guides and help doc. Something seems to be simply blocking my connection. I have tried the same thing on multiple computers.
Everything seems to be configured correctly except I suspect the server instance.
Can anyone help? PS I'm fairly new to web development, this is my first AWS EC2 server.
[UPDATE] I just tried to create a new instance in a different location, same thing, maybe I don't know how to configure the SQL Server on the EC2?
It appears that by default EC2 SQL instances have SQL authentication disabled.
In SQL Management Studio, connect as the built in Administrator account, then go to
Server Properties>Security>
Under Server Authentication, change to "SQL Server and Windows Authentication Mode"
Restart SQL
Your local accounts should now work
Try running in elevated mode (right click Visual studio and run as Administrator), solved some issues I was having recently.
I try to install Postgres on Windows (Server 2003). Both versions I tried (8.3, 8.4) fail at the end of the installation because the service cannot be started. I tried with different users for the service without success.
Any ideas anyone?
It's usually a permissions issue. Check that the installer set up the permissions correctly for the user running the service (usually "postgres").