Guest User

Guest User

  • Tech Writer
  • 2.1k
  • 479.7k

How to create table definition using NUGET command?

May 12 2020 12:35 PM
Hi Team
 
I have new table definition on my database, now i cant seem to access the context using this command on my NuGet.  NB: I have followed this link here, i am unable to achieve this well and need some help https://docs.microsoft.com/en-us/ef/core/miscellaneous/cli/powershell
  1. Scaffold-DBContext "Data Source=GcobaniM-L\SQLEXPRESS;Database=eNtsaRegistration;Integrated Security=True" Microsoft.EntityFrameworkCore.SqlServer -OutputDir Models  
  2. Scaffold-DBContext : 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   
  3. if a path was included, verify that the path is correct and try again.  
  4. At line:1 char:1  
  5. + Scaffold-DBContext "Data Source=GcobaniM-L\SQLEXPRESS;Database=eNtsaR ...  
  6. + ~~~~~~~~~~~~~~~~~~  
  7.     + CategoryInfo          : ObjectNotFound: (Scaffold-DBContext:String) [], CommandNotFoundException  
  8.     + FullyQualifiedErrorId : CommandNotFoundException  
 

Answers (4)