ISqlParameter.Name Property
.NET Standard 2.x
Gets the name of the SQL parameter.
Namespace: SnapObjects.Data
Assembly: SnapObjects.Data.dll
Syntax
string Name { get; }
Property Value
System.String
The name of the SQL parameter.
Examples
The following code example gets the name of the SQL query parameter.
using SnapObjects.Data;
using System;
namespace Appeon.ApiDoc.ISqlParameterExamples
{
public class NameExample
{
private readonly SchoolContext _context;
public NameExample(SchoolContext context)
{
_context = context;
}
public void Example()
{
ISqlParameter param = SqlBuilder.Parameter(typeof(int), "id");
var name = param.Name;
Console.WriteLine("Data Name = {0}", name);
/*This code produces the following output:
Data Name = id
*/
}
}
}
Applies to
.NET Standard
2.x