Closed adayIvey closed 8 years ago
Did you install the EntityFramework.Commands package? That is the package that brings in that command.
BTW, best to view the docs at http://docs.efproject.net/en/latest/ as they are RST. GitHub partially renders them as MarkDown... but you don't get all the content.
Yes i did install the commands
Sent from my Samsung device
-------- Original message -------- From: Rowan Miller notifications@github.com Date: 12-23-2015 4:15 PM (GMT-05:00) To: "aspnet/EntityFramework.Docs" EntityFramework.Docs@noreply.github.com Cc: "Day, Andrew" aday@ivey.uwo.ca Subject: Re: [EntityFramework.Docs] Example: To enable reverse engineering from an existing database does not work (#99)
Did you install the EntityFramework.Commands package? That is the package that brings in that command.
BTW, best to view the docs at http://docs.efproject.net/en/latest/ as they are RST. GitHub partially renders them as MarkDown... but you don't get all the content.
Reply to this email directly or view it on GitHubhttps://github.com/aspnet/EntityFramework.Docs/issues/99#issuecomment-166991023.
Couple more questions:
I tried this in a class library and a console app.
Using the latest 4.x framework
Sent from my Samsung device
-------- Original message -------- From: Rowan Miller notifications@github.com Date: 12-23-2015 6:24 PM (GMT-05:00) To: "aspnet/EntityFramework.Docs" EntityFramework.Docs@noreply.github.com Cc: "Day, Andrew" aday@ivey.uwo.ca Subject: Re: [EntityFramework.Docs] Example: To enable reverse engineering from an existing database does not work (#99)
Couple more questions:
Reply to this email directly or view it on GitHubhttps://github.com/aspnet/EntityFramework.Docs/issues/99#issuecomment-167008093.
For you, are the steps to reproduce as simple as:
.NET Framework 4.6.1
from dropdownInstall-Package EntityFramework.MicrosoftSqlServer.Design -Pre
(installs 7.0.0-rc1-final)Install-Package EntityFramework.Commands -Pre
(installs 7.0.0-rc1-final)Scaffold-DbContext -provider EntityFramework.MicrosoftSqlServer -connection "Server=(localdb)\mssqllocaldb;Database=Blogging;Trusted_Connection=True;"
If so, there must be something specific to your installation. A couple of initial questions to help narrow things down:
Get-ExecutionPolicy
in Package Manager Console and see what it returns. Sometimes when commands don't work it's because the execution policy gets set to Restricted.Help -> About Microsoft Visual Studio
- the latest version would be 14.0.24720.00 Update 1
.Also just confirming that these are not ASP.NET 5 class libraries/console apps... since Package Manager Console commands do not work with those project types yet.
I will try when i am back in the office in the new year.... thanks
Sent from my Samsung device
-------- Original message -------- From: Rowan Miller notifications@github.com Date: 12-28-2015 3:03 PM (GMT-05:00) To: "aspnet/EntityFramework.Docs" EntityFramework.Docs@noreply.github.com Cc: "Day, Andrew" aday@ivey.uwo.ca Subject: Re: [EntityFramework.Docs] Example: To enable reverse engineering from an existing database does not work (#99)
For you, are the steps to reproduce as simple as:
If so, there must be something specific to your installation. A couple of initial questions to help narrow things down:
Also just confirming that these are not ASP.NET 5 class libraries/console apps... since Package Manager Console commands do not work with those project types yet.
Reply to this email directly or view it on GitHubhttps://github.com/aspnet/EntityFramework.Docs/issues/99#issuecomment-167643390.
I am having exactly the same problems. I have followed the steps above except that I am creating a WinForms application. Get-Execution returns RemoteSigned, I am using VS 2015 version 14.0.24720.00 Update 1.
The only thing of note is that on executing the Install-Package EntityFramework.Commands -Pre command, it shows a Red error "Cannot bind parameter 'FilterScript'..." but continues and eventually says "Successfully installed 'EntityFramework.Commands 7.0.0-rc1-final' to
Andy
Thanks for your help I am going to give this a try.
I just noticed that my PS Version is only 2.0 should I go to 3.0 for should I go to the latest and greatest.
From: Rowan Miller [mailto:notifications@github.com] Sent: Monday, December 28, 2015 3:04 PM To: aspnet/EntityFramework.Docs EntityFramework.Docs@noreply.github.com Cc: Day, Andrew aday@ivey.uwo.ca Subject: Re: [EntityFramework.Docs] Example: To enable reverse engineering from an existing database does not work (#99)
For you, are the steps to reproduce as simple as:
If so, there must be something specific to your installation. A couple of initial questions to help narrow things down:
Also just confirming that these are not ASP.NET 5 class libraries/console apps... since Package Manager Console commands do not work with those project types yet.
— Reply to this email directly or view it on GitHubhttps://github.com/aspnet/EntityFramework.Docs/issues/99#issuecomment-167643390.
Update…
I installed PS v4 amd that looks to have fixed my issue.
But while running Scaffold-DbContext I got error ‘The given key was not present in the dictionary.’
This looks to be a known issue https://github.com/aspnet/EntityFramework/issues/3861 Do you know if there are plans for a rc2 or a work around for this issue?
From: Rowan Miller [mailto:notifications@github.com] Sent: Monday, December 28, 2015 3:04 PM To: aspnet/EntityFramework.Docs EntityFramework.Docs@noreply.github.com Cc: Day, Andrew aday@ivey.uwo.ca Subject: Re: [EntityFramework.Docs] Example: To enable reverse engineering from an existing database does not work (#99)
For you, are the steps to reproduce as simple as:
If so, there must be something specific to your installation. A couple of initial questions to help narrow things down:
Also just confirming that these are not ASP.NET 5 class libraries/console apps... since Package Manager Console commands do not work with those project types yet.
— Reply to this email directly or view it on GitHubhttps://github.com/aspnet/EntityFramework.Docs/issues/99#issuecomment-167643390.
I just noticed that my PS Version is only 2.0 should I go to 3.0 for should I go to the latest and greatest.
I installed PS v4 and that looks to have fixed my issue.
@bricelam we do require PS 3.0 right?
@aday12345 - Regarding #3861 that is fixed and will ship in RC2 (planned for next month). In the meantime you could get out nightly builds that include the fix https://www.myget.org/Gallery/aspnetvnext
Thanks for all your help
From: Rowan Miller [mailto:notifications@github.com] Sent: Monday, January 04, 2016 1:32 PM To: aspnet/EntityFramework.Docs EntityFramework.Docs@noreply.github.com Cc: Day, Andrew aday@ivey.uwo.ca Subject: Re: [EntityFramework.Docs] Example: To enable reverse engineering from an existing database does not work (#99)
I just noticed that my PS Version is only 2.0 should I go to 3.0 for should I go to the latest and greatest.
I installed PS v4 and that looks to have fixed my issue.
@bricelamhttps://github.com/bricelam we do require PS 3.0 right?
@aday12345https://github.com/aday12345 - Regarding aspnet/EntityFramework#3861 that is fixed and will ship in RC2 (planned for next month). In the meantime you could get out nightly builds that include the fix https://www.myget.org/Gallery/aspnetvnext
— Reply to this email directly or view it on GitHubhttps://github.com/aspnet/EntityFramework.Docs/issues/99#issuecomment-168761234.
Yes, upgraded to PS4 and all seems to be fine now :-) Many thanks.
Andy
Great - I have https://github.com/aspnet/EntityFramework.Docs/pull/103 our for review to add this as a pre-requisite
Thanks all for your work getting to the bottom of this one
we do require PS 3.0 right?
Yes, it's required by our module. Our module should fail to load without it; I wonder if the error is getting swallowed/hidden by NuGet...
do you know when we will see RC2????
https://github.com/aspnet/EntityFramework.Docs/blob/master/docs/getting-started/full-dotnet/existing-db.rst
The example to enable reverse engineering from an existing database does not work: Scaffold-DbContext -provider EntityFramework.MicrosoftSqlServer -connection "Server=(localdb)\mssqllocaldb;Database=Blogging;Trusted_Connection=True;"
when I tried this is vs2015 I get
The term 'Scaffold-DbContext' is not recognized as the name of a cmdlet, function, script file, or operable program. Check the spelling of the name, or if a path was included, verify that the path is correct and try again. At line:1 char:19