How to create multiple edmx in same project

2019-08-31 03:40发布

i am new to EF ... getting this error while adding another edmx in same project using same connection string . this is my connection string

<add name="REFLECTIONDBEntities" connectionString="metadata=res://*/;provider=System.Data.SqlClient;provider connection string=&quot;data source=SERVER;initial catalog=REFLECTIONDB;persist security info=True;user id=sa;password=Sqlsa123;multipleactiveresultsets=True;application name=EntityFramework&quot;" />

1条回答
可以哭但决不认输i
2楼-- · 2019-08-31 04:13

Same connection Strings Names are not allowed, you can have multiple Connection Strings but with separate names.

Change

name="REFLECTIONDBEntities"

To

name="REFLECTIONDBEntities2"

查看更多
登录 后发表回答