I am using Oracle.EntityFrameWork package and with below connection string in my dbContext.
我使用的是Oracle.EntityFrameWork包,在我的dbContext中有以下连接字符串。
protected override void OnConfiguring(DbContextOptionsBuilder options){
options.UseOracle(@"Data Source=sampleip:port/serviceName;User Id=sample; Password=sample;")
}
It works but I need specify database name. I tried "Initial Catalog" but it doesn't work.
它有效,但我需要指定数据库名称。我试过“初始目录”,但它不起作用。
更多回答
You wanna specify database name in your connection string?
你想在连接字符串中指定数据库名称吗?
I am not sure if i get your point, Why don't you put the database name in {serviceName}
part?
我不确定我是否理解你的观点,为什么不把数据库名称放在{serviceName}部分?
优秀答案推荐
我是一名优秀的程序员,十分优秀!