Scaffold-DbContext

실제..많이 쓰는데..자꾸 옵션을 까먹어서 정리를..
나중에 추가는 계속 하고

기본

Session
1
Scaffold-DbContext "Server=.;Database={DB명};User ID={계정아이디};Password={비밀번호};" Microsoft.EntityFrameworkCore.SqlServer

One Table

Session
1
Scaffold-DbContext "Server=.;Database={DB명};User ID={계정아이디};Password={비밀번호};" Microsoft.EntityFrameworkCore.SqlServer -Table 테이블명

Context명

Session
1
Scaffold-DbContext "Server=.;Database={DB명};User ID={계정아이디};Password={비밀번호};" Microsoft.EntityFrameworkCore.SqlServer -Context 컨텍스트명

Output Dir

Session
1
Scaffold-DbContext "Server=.;Database={DB명};User ID={계정아이디};Password={비밀번호};" Microsoft.EntityFrameworkCore.SqlServer -OutputDir 경로/하위경로/...

Author: jklee@lenscloth.io
Link: https://lenscloth-ko.github.io.git/2019/03/06/Scaffold-DbContext/
Copyright Notice: All articles in this blog are licensed under CC BY-NC-SA 4.0 unless stating additionally.