Hello i am trying to inject dependency of service with multiples implementations, i have this code in my Program.cs
builder.Services.AddTransient<IDBActionQuery<Period>, Select<Period>>();
And i have this interface:
public interface IDBActionQuery<T>
{
Task<List<T>> execute(string query, params (string name, object val)[] pars);
Task<List<T>> buildAndExecute();
}
However i am receiving this error:
Some services are not able to be constructed (Error while validating the service descriptor 'ServiceType:
Why is that???
Select
is? Also I recommend to follow standard C# naming conventions. - Guru Stron