IDE stands for Integrated Development Environment is a software application that is used to build software...
You can use the following format to build a connection string for named SQL Server instance:
jdbc:jtds:sqlserver://ComputerName/DatabaseName;instance=InstanceName
Where Computer name is the name of computer on which SQL Server installed, it can be DNS or IP address.
Database name is the name of database to which you want to connect.
Instance Name is the name of the SQL Server instance.
Example
...
Unit test tests single unit of code without communicating with the external dependencies i.e. file system, network or database.
Connection resiliency is used to describe a scenario where some resource becomes unavailable for short period of time, if we try to connect that resource like SQL Server during that time our connection should not throw exception instead it should retry.
Lazy loading should typically be disabled for web applications, since its use will result in additional ...
In web applications, it’s recommended to use the async/await pattern with the async methods, ...
In ASP.NET core by default logged in user’s email is shown in header after login.
We can show any other information like First or Last Name or even full name (by combining these two).
To achieve this we need to make the following changes:
Customize your Identity User
Customize the identity user and identity role (if needed) as shown below:
public class ApplicationUser: IdentityUser<int>
{
public
... Here are the commands to install or update ...
In previous articles Get enumeration items as a list in C# and Populate dropdown with enumeration items in ASP.NET Core we that saw how to get enumeration items as a collection to bind it to data controls like dropdown etc.
In this article we will see that how can we get the description given as an attribute with an item. We may need this information on various places, say we have listing of users and we need to show each user’s status but in a descriptive way.
Here is our example enumeration:
enum UserStatus
{
[Description("Pending Verification")]
... We can bind a dropdown with enumeration items without creating a look up table.
In Get enumeration items as a list in C# article we saw that how we can get enumeration items as a list to bind it to a data control.
Here is the enumeration we have been working with:
enum UserStatus
{
[Description("Pending Verification")]
...