I'm developing rails app on windows 10. I want a GUI for default sqlite database for my app, for this I've downloaded SQLyog software: https://www.webyog.com/
Now SQLyog is asking for some credentials (e.g. host, username, password, port) to connect to my rails app database. Here, I don't know where to find these credentials for my app database.
I've checked database.yml file but there is no such information. Where do I find this information?
Related
I have a rails application running on mac and an MS Access database located on windows server PC which data are changing daily.
Both may mac and windows PC are in the same network and also I have permission to connect to server remotely by telnet.
How may I just read data from my mac using ruby to publish it?
In database.yml, you should configure the db parameter, like adapter, host, port, username, password. I am not sure if there is Access DB adapter for Rails. And then, you can create your models corresponding to the DB tables. Please refer to this
I did the almost same thing, except I use Sqlite tables in local host and PSQL tables in remote server in development. Ater you finish the configure and models creation, you can use the model as normal, almost no any difference.
I'm trying to deploy a ruby on rails app to dotcloud. The app is deployed but when I try to access the url, I get this error:
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"? (PG::Error)
I'm using a postgresql database. What all changes do I need to make in the database.yml file?
I've also followed the steps outlined here:
http://docs.dotcloud.com/services/postgresql/
Can anyone please help on this?
It looks like your app is configured to use a local PostgreSQL database (local as in "running on the same machine"). You should make sure that your dotcloud.yml file contains a section for a PosgreSQL database, e.g.:
db:
type: postgresql
Then use either dotcloud info to retrieve the host, port, and credentials of the database, or parse them from environment.json in your Ruby app.
This last step is explained in the dotCloud PostgreSQL service documentation.
I'm having a problem trying to deploy a Rails application
a FreeBSD server, I am using unixODBC and FreeTDS to
access the database that sits on a server with windows server
Sqlsever 2003 and 2000.
The problem is that the application can only access the database
when using the SA user sqlserver, when I try to use another user,
the application can not access. But when I test the DSN created outside
the application I can access the database with other users,
DSN using the same application.
Does anyone have an idea what might be? Ja I even put the
I created user to access the application with all rights ..
db_owner .. and so on .. and still can not access when I try to run
application with this user.
tanks!
:) Alessandra
I realized that if I omit the user or placing a user who does not exist, but the password being the same as in SA it connects too.
I am using postgresql database for my Heroku Application.
I have very large database on AmazonAws as heroku not providing the Postgresql Database.
Now my client want to switch to EngineYard from Heroku.
Can i use same database (w/o taking backup and then reload) for my application on the EngineYard?
If YES
How can i use or steps for using the Existing AmazonAws Database with the new EngineYard Application.
You can, but only if you are using a dedicated database. From the Heroku database FAQ
Shared Database
No, connecting to your database from machines outside of Heroku is not
supported. We recommend that you encapsulate data access in an API to
manipulate it.
Dedicated Database
It's possible to connect to our dedicated databases using our
pg:ingress feature. Please see using the PG console for more
information.
The database connection string is available in the DATABASE_URL config. You can run
$ heroku config --long
to view it. However, it won't probably work if you use a shared database because it seems connection is restricted to the Heroku net.
Surely this is just a case of getting the correct connection credentials for the DB regardless of where it's hosted?
For instance, if the DB is on Heroku, then ENV['DATABASE_URL'] give you everything you need. All these details then go in your database.yml as normal (assuming you're using ActiveRecord)
For the record, Heroku do provide Postgres and it's part of their core business.
I have an application made with Delphi 2006 and Firebird 2.5. For connection a use Interbase components from Delphi. I setting up in design time a TIBDatabase with username, password tc, and work ok, but when i want to run application in another pc (first i install Firebird 2.5 on it), i received this error:
Statement failed, SQLSTATE = 28000
Your user name and password are not defined. Ask your database administrator to set up a Firebird login.
What is this? How can I resolve that?
The message clearly states the username and password you're using to connect at design time in your development machine are not valid to the database server you're trying to connect on the other machine (let's call it production). From your message it seems it is not the same server you connect to at design time.
I suggest you to test this issue with ease to put the LoginPrompt property to true on the TIBDatabase component to allow it to ask the user for propper credentials before connecting. You will be able to connect using any valid username/password combination for that server. To be sure the combination are valid, try to connect using the isql command line tool, for example the command
c:\test>isql test.fdb -u sysdba -p masterkey
will connect to c:\test\test.fdb using default username and password. (the firebird root directory must be in the path environment variable for this to work)
Also, you can use the gsec command line tool to adjust the password for this engine or you can provide the create users and change passwords on that production machine before trying to connect to it.
On Windows, firebird default sysdba password is masterkey.
The solution that finally worked for me on windows was starting cmd.exe as administrator and running "C:\Program Files (x86)\Firebird\Firebird_3_0\gsec.exe" -user sysdba -password masterkey -mo sysdba -pw masterkey
This error is because the credentials for Firebird db is simply not stored in the database file. It's stored in the configuration file on the Firebird Server. If you copy over the DB file, and not the password -- you will have a different password.
On Ubuntu machines you can find out the password and username in the file, /etc/firebird/<version>/SYSDBA.password
It'll look something like,
ISC_USER=sysdba
ISC_PASSWORD="password"
Use those credentials to connect to the database file.
At 'isql-fb' from linux terminal and after the 'CONNECT' on database:
- I solved after delete(drop) and recreate the 'SYSDBA' user.
Observation: I had problems with file and folder permission at '/tmp/firebird' and I needed to use 'sudo' or root to open 'isql-fb'
Thanks.
I once got this error trying to connect to a Firebird 3.0.3 database using the Firebird 2.5 client libraries. I just forgot to update the client libraries to 3.0.3. Maybe this will help someone.