lorint / AdventureWorks-for-Postgres

Set up the AdventureWorks sample database for use with Postgres
MIT License
369 stars 185 forks source link

Installing #12

Closed captainnima closed 1 year ago

captainnima commented 2 years ago

I am on a Mac. I have everything installed. From Terminal, when I run the psql commands, it asks for my password which I type in but it fails. The problem seems to be the it defaults to my username instead of the Postgres account which is in the database. Any suggestions how I can do this?

loganphillips792 commented 2 years ago

Can you provide the command you are running?

captainnima commented 2 years ago

I run the psql -d command on my Mac. I am logged in as my super user account and when I run the command, it asks for my password. I enter it but it says “Sorry”. I connected to Postgres from the command line but when I do, I am not sure how to run the install.sql. I tried switching to root and running the command but it still asks for the root password and then it fails. I put in the Postgres password also but it fails.

On Oct 22, 2022, at 1:00 PM, Logan Phillips @.***> wrote:

Can you provide the command you are running?

— Reply to this email directly, view it on GitHub https://nam12.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Florint%2FAdventureWorks-for-Postgres%2Fissues%2F12%23issuecomment-1287855662&data=05%7C01%7C%7C1d3c568ff3bf4d897e2508dab44ee171%7C84df9e7fe9f640afb435aaaaaaaaaaaa%7C1%7C0%7C638020548129408939%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000%7C%7C%7C&sdata=t4BaXzY0iWNN%2F7T0gHeW9muVxbLeGdRjf37Nnwoo%2B00%3D&reserved=0, or unsubscribe https://nam12.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fnotifications%2Funsubscribe-auth%2FAHIB6DMMP2RN4EEPUHFX5CTWEQMRTANCNFSM6AAAAAARKYMD6Q&data=05%7C01%7C%7C1d3c568ff3bf4d897e2508dab44ee171%7C84df9e7fe9f640afb435aaaaaaaaaaaa%7C1%7C0%7C638020548129565622%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000%7C%7C%7C&sdata=aX9Mn5K%2FUgQF2FXKPpijivQHtTOUQJNKZk%2BvT%2BMjM%2F8%3D&reserved=0. You are receiving this because you authored the thread.

captainnima commented 2 years ago

I figured it out. The command needs to be “psql postgres -d adventureworks < install.sql” to include the username for the database. Would you mind modifying your ReadMe to indicate that?

On Oct 22, 2022, at 1:00 PM, Logan Phillips @.***> wrote:

Can you provide the command you are running?

— Reply to this email directly, view it on GitHub https://nam12.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Florint%2FAdventureWorks-for-Postgres%2Fissues%2F12%23issuecomment-1287855662&data=05%7C01%7C%7C1d3c568ff3bf4d897e2508dab44ee171%7C84df9e7fe9f640afb435aaaaaaaaaaaa%7C1%7C0%7C638020548129408939%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000%7C%7C%7C&sdata=t4BaXzY0iWNN%2F7T0gHeW9muVxbLeGdRjf37Nnwoo%2B00%3D&reserved=0, or unsubscribe https://nam12.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fnotifications%2Funsubscribe-auth%2FAHIB6DMMP2RN4EEPUHFX5CTWEQMRTANCNFSM6AAAAAARKYMD6Q&data=05%7C01%7C%7C1d3c568ff3bf4d897e2508dab44ee171%7C84df9e7fe9f640afb435aaaaaaaaaaaa%7C1%7C0%7C638020548129565622%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000%7C%7C%7C&sdata=aX9Mn5K%2FUgQF2FXKPpijivQHtTOUQJNKZk%2BvT%2BMjM%2F8%3D&reserved=0. You are receiving this because you authored the thread.

lorint commented 1 year ago

@captainnima -- have now added in the README the suggestion to try the -U switch: e7dad283a21a4c3c410670de45a90ffd60efe10b

Hope that this is helpful -- let me know if you think it should be further revised.