{"action":"created","issue":{"url":"https://api.github.com/repos/elixir-lang/ecto/issues/781","labels_url":"https://api.github.com/repos/elixir-lang/ecto/issues/781/labels{/name}","comments_url":"https://api.github.com/repos/elixir-lang/ecto/issues/781/comments","events_url":"https://api.github.com/repos/elixir-lang/ecto/issues/781/events","html_url":"https://github.com/elixir-lang/ecto/issues/781","id":94913794,"number":781,"title":"ecto.migrate says database does not exist","user":{"login":"mesosteros","id":1943233,"avatar_url":"https://avatars.githubusercontent.com/u/1943233?v=3","gravatar_id":"","url":"https://api.github.com/users/mesosteros","html_url":"https://github.com/mesosteros","followers_url":"https://api.github.com/users/mesosteros/followers","following_url":"https://api.github.com/users/mesosteros/following{/other_user}","gists_url":"https://api.github.com/users/mesosteros/gists{/gist_id}","starred_url":"https://api.github.com/users/mesosteros/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mesosteros/subscriptions","organizations_url":"https://api.github.com/users/mesosteros/orgs","repos_url":"https://api.github.com/users/mesosteros/repos","events_url":"https://api.github.com/users/mesosteros/events{/privacy}","received_events_url":"https://api.github.com/users/mesosteros/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":5,"created_at":"2015-07-14T10:21:27Z","updated_at":"2015-07-14T11:24:49Z","closed_at":"2015-07-14T11:11:14Z","body":"I'm working with Windows 8.1 64 bits and Phoenix Framework.\r\nHowever following the guide (http://www.phoenixframework.org/docs/ecto-models) for Ecto Models hands me this error when I get to ```mix ecto.migrate```.\r\nSteps to recreate:\r\n1. Create new project (```mix phoenix.new ectoTest```).\r\n2. Compile and run (```mix phoenix.server```)\r\n3. Stop the execution after localhost:4000 is served with Ctrl+C.\r\n4. ```mix phoenix.gen.html User users name:string email:string bio:string number_of_pets:integer```\r\n5. Add ```resources \"/users\", UserController``` to the router.ex file.\r\n6. (this step is not even mentioned in that guide) ```mix ecto.create```\r\n7. ```mix ecto.migrate```\r\n\r\n\r\nThis outputs the following error:\r\n\r\n```C:\\Users\\mesos_000\\Desktop\\elixir Projects\\ectoTest>mix ecto.migrate\r\n** (exit) exited in: GenServer.call(#PID<0.134.0>, {:query, \"SELECT count(1) FROM pg_class c\\n  JOIN pg_namespace n ON n.oid = c.relnamespace\\n WHERE c.relkind IN ('r','v\r\n','m')\\n       AND c.relname = 'schema_migrations'\\n       AND n.nspname = ANY (current_schemas(false))\\n\", []}, :infinity)\r\n    ** (EXIT) %Postgrex.Error{message: nil, postgres: %{code: :invalid_catalog_name, file: \"src\\\\backend\\\\utils\\\\init\\\\postinit.c\", line: \"794\", message: \"database \\\"ecto\r\nTest_dev\\\" does not exist\", pg_code: \"3D000\", routine: \"InitPostgres\", severity: \"FATAL\"}}\r\n    (elixir) lib/gen_server.ex:356: GenServer.call/3\r\n    (postgrex) lib/postgrex/connection.ex:87: Postgrex.Connection.query/4\r\n    (ecto) lib/ecto/adapters/postgres/connection.ex:40: Ecto.Adapters.Postgres.Connection.query/4\r\n    (ecto) lib/ecto/adapters/sql.ex:201: Ecto.Adapters.SQL.query/7\r\n    (ecto) lib/ecto/adapters/pool.ex:274: Ecto.Adapters.Pool.do_run/4\r\n    (ecto) lib/ecto/adapters/sql.ex:189: Ecto.Adapters.SQL.query/5\r\n    (ecto) lib/ecto/adapters/sql.ex:164: Ecto.Adapters.SQL.query/4\r\n    (ecto) lib/ecto/adapters/postgres.ex:61: Ecto.Adapters.Postgres.ddl_exists?/3```\r\n\r\nHowever in my pgAdminIII I get the database. I also connected it in the pgAdmin GUI and tried ```ecto.migrate``` again, with no results.\r\n\r\n![ectotest](https://cloud.githubusercontent.com/assets/1943233/8671127/746f3836-2a1a-11e5-8112-1a5a1a0a3cc4.jpg)\r\n"},"comment":{"url":"https://api.github.com/repos/elixir-lang/ecto/issues/comments/121206594","html_url":"https://github.com/elixir-lang/ecto/issues/781#issuecomment-121206594","issue_url":"https://api.github.com/repos/elixir-lang/ecto/issues/781","id":121206594,"user":{"login":"mesosteros","id":1943233,"avatar_url":"https://avatars.githubusercontent.com/u/1943233?v=3","gravatar_id":"","url":"https://api.github.com/users/mesosteros","html_url":"https://github.com/mesosteros","followers_url":"https://api.github.com/users/mesosteros/followers","following_url":"https://api.github.com/users/mesosteros/following{/other_user}","gists_url":"https://api.github.com/users/mesosteros/gists{/gist_id}","starred_url":"https://api.github.com/users/mesosteros/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mesosteros/subscriptions","organizations_url":"https://api.github.com/users/mesosteros/orgs","repos_url":"https://api.github.com/users/mesosteros/repos","events_url":"https://api.github.com/users/mesosteros/events{/privacy}","received_events_url":"https://api.github.com/users/mesosteros/received_events","type":"User","site_admin":false},"created_at":"2015-07-14T11:24:49Z","updated_at":"2015-07-14T11:24:49Z","body":"It's always the simple things. :+1: Managed to get through that step now."}}