Click here to Skip to main content
15,559,459 members
Home / Discussions / C#
   

C#

 
AnswerRe: Entity Framework Core 6 Problem Pin
Dave Kreskowiak24-Nov-22 10:41
mveDave Kreskowiak24-Nov-22 10:41 
GeneralRe: Entity Framework Core 6 Problem Pin
Kevin Marois24-Nov-22 11:19
professionalKevin Marois24-Nov-22 11:19 
GeneralRe: Entity Framework Core 6 Problem Pin
Dave Kreskowiak24-Nov-22 15:48
mveDave Kreskowiak24-Nov-22 15:48 
GeneralRe: Entity Framework Core 6 Problem Pin
Kevin Marois24-Nov-22 16:57
professionalKevin Marois24-Nov-22 16:57 
GeneralRe: Entity Framework Core 6 Problem Pin
Dave Kreskowiak24-Nov-22 17:03
mveDave Kreskowiak24-Nov-22 17:03 
GeneralRe: Entity Framework Core 6 Problem Pin
Kevin Marois25-Nov-22 20:16
professionalKevin Marois25-Nov-22 20:16 
GeneralRe: Entity Framework Core 6 Problem Pin
Dave Kreskowiak26-Nov-22 6:20
mveDave Kreskowiak26-Nov-22 6:20 
GeneralRe: Entity Framework Core 6 Problem Pin
Kevin Marois26-Nov-22 10:20
professionalKevin Marois26-Nov-22 10:20 
That's what I thought too.

I have created a new login and still get the same error. Here's my Conn string
protected override void OnConfiguring(DbContextOptionsBuilder optionsBuilder)
{
    var connectionString = @"Server=MAROIS_KEVIN_1\SQLEXPRESS;Database=Test;User Id=FatALbert;Password=AlbertIsFat!;;Encrypt=false;";
    optionsBuilder.UseSqlServer(connectionString, options => options.EnableRetryOnFailure());
}
and the exception
Microsoft.EntityFrameworkCore.Storage.RetryLimitExceededException
  HResult=0x80131500
  Message=The maximum number of retries (6) was exceeded while executing database operations with 'SqlServerRetryingExecutionStrategy'. See the inner exception for the most recent failure.
  Source=Microsoft.EntityFrameworkCore
  StackTrace:
   at Microsoft.EntityFrameworkCore.Storage.ExecutionStrategy.ExecuteImplementation[TState,TResult](Func`3 operation, Func`3 verifySucceeded, TState state)
   at Microsoft.EntityFrameworkCore.Storage.ExecutionStrategy.Execute[TState,TResult](TState state, Func`3 operation, Func`3 verifySucceeded)
   at Microsoft.EntityFrameworkCore.ChangeTracking.Internal.StateManager.SaveChanges(Boolean acceptAllChangesOnSuccess)
   at Microsoft.EntityFrameworkCore.DbContext.SaveChanges(Boolean acceptAllChangesOnSuccess)
   at Program.<Main>$(String[] args) in C:\Projects\SandBox\Learning\EF6Core\Database First\EFCoreDBFirstExample\Program.cs:line 11

  This exception was originally thrown at this call stack:
    [External Code]

Inner Exception 1:
SqlException: Cannot open database "Test" requested by the login. The login failed.
Login failed for user 'FatAlbert'.

I also tried creating the DB 'Test' first in SQL and assigning it to FatAlbert and the same exception.

Again, I have other apps running on my Dev PC that don't use SQL Authentication and they connect just fine. So I has to be something with EF.
If it's not broken, fix it until it is.
Everything makes sense in someone's mind.
Ya can't fix stupid.

GeneralRe: Entity Framework Core 6 Problem Pin
Dave Kreskowiak26-Nov-22 10:24
mveDave Kreskowiak26-Nov-22 10:24 
GeneralRe: Entity Framework Core 6 Problem Pin
Kevin Marois26-Nov-22 11:24
professionalKevin Marois26-Nov-22 11:24 
GeneralRe: Entity Framework Core 6 Problem Pin
Dave Kreskowiak26-Nov-22 12:31
mveDave Kreskowiak26-Nov-22 12:31 
GeneralRe: Entity Framework Core 6 Problem Pin
Kevin Marois26-Nov-22 12:50
professionalKevin Marois26-Nov-22 12:50 
GeneralRe: Entity Framework Core 6 Problem Pin
Kevin Marois27-Nov-22 8:56
professionalKevin Marois27-Nov-22 8:56 
GeneralRe: Entity Framework Core 6 Problem Pin
Dave Kreskowiak27-Nov-22 9:38
mveDave Kreskowiak27-Nov-22 9:38 
GeneralRe: Entity Framework Core 6 Problem Pin
Kevin Marois27-Nov-22 10:16
professionalKevin Marois27-Nov-22 10:16 
GeneralRe: Entity Framework Core 6 Problem Pin
Kevin Marois27-Nov-22 10:31
professionalKevin Marois27-Nov-22 10:31 
GeneralRe: Entity Framework Core 6 Problem Pin
Dave Kreskowiak27-Nov-22 10:32
mveDave Kreskowiak27-Nov-22 10:32 
GeneralRe: Entity Framework Core 6 Problem Pin
Kevin Marois27-Nov-22 10:39
professionalKevin Marois27-Nov-22 10:39 
GeneralRe: Entity Framework Core 6 Problem Pin
Dave Kreskowiak26-Nov-22 12:40
mveDave Kreskowiak26-Nov-22 12:40 
GeneralRe: Entity Framework Core 6 Problem Pin
Kevin Marois26-Nov-22 12:50
professionalKevin Marois26-Nov-22 12:50 
AnswerRe: Entity Framework Core 6 Problem Pin
Sam Hobbs24-Nov-22 12:23
Sam Hobbs24-Nov-22 12:23 
GeneralRe: Entity Framework Core 6 Problem Pin
Kevin Marois24-Nov-22 13:22
professionalKevin Marois24-Nov-22 13:22 
QuestioniTextSharp to Append QRCode to an Existing PDF File Pin
Fezih523-Nov-22 22:27
Fezih523-Nov-22 22:27 
AnswerRe: iTextSharp to Append QRCode to an Existing PDF File Pin
Richard Deeming23-Nov-22 23:00
mveRichard Deeming23-Nov-22 23:00 
QuestionTriangles count in Graph Pin
Member 1177893019-Nov-22 16:20
Member 1177893019-Nov-22 16:20 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.