• Core
  • Infrastructure
  • Web
  • Extensions
Search Results for

    Show / Hide Table of Contents
    View Source

    Class SqlExpressionExtensions

    String extension methods used specifically to translate into SQL

    Inheritance
    System.Object
    Namespace: Umbraco.Cms.Core.Persistence
    Assembly: Umbraco.Core.dll
    Syntax
    public static class SqlExpressionExtensions

    Methods

    View Source

    SqlContains(String, String, TextColumnType)

    Declaration
    public static bool SqlContains(this string str, string txt, TextColumnType columnType)
    Parameters
    Type Name Description
    System.String str
    System.String txt
    TextColumnType columnType
    Returns
    Type Description
    System.Boolean
    View Source

    SqlEndsWith(String, String, TextColumnType)

    Declaration
    public static bool SqlEndsWith(this string str, string txt, TextColumnType columnType)
    Parameters
    Type Name Description
    System.String str
    System.String txt
    TextColumnType columnType
    Returns
    Type Description
    System.Boolean
    View Source

    SqlEquals(String, String, TextColumnType)

    Declaration
    public static bool SqlEquals(this string str, string txt, TextColumnType columnType)
    Parameters
    Type Name Description
    System.String str
    System.String txt
    TextColumnType columnType
    Returns
    Type Description
    System.Boolean
    View Source

    SqlIn<T>(IEnumerable<T>, T)

    Declaration
    public static bool SqlIn<T>(this IEnumerable<T> collection, T item)
    Parameters
    Type Name Description
    IEnumerable<T> collection
    T item
    Returns
    Type Description
    System.Boolean
    Type Parameters
    Name Description
    T
    View Source

    SqlNullableEquals<T>(Nullable<T>, Nullable<T>, T)

    Indicates whether two nullable values are equal, substituting a fallback value for nulls.

    Declaration
    public static bool SqlNullableEquals<T>(this T? value, T? other, T fallbackValue)
        where T : struct
    Parameters
    Type Name Description
    System.Nullable<T> value

    The value to compare.

    System.Nullable<T> other

    The value to compare to.

    T fallbackValue

    The value to use when any value is null.

    Returns
    Type Description
    System.Boolean
    Type Parameters
    Name Description
    T

    The nullable type.

    Remarks

    Do not use outside of Sql expressions.

    View Source

    SqlStartsWith(String, String, TextColumnType)

    Declaration
    public static bool SqlStartsWith(this string str, string txt, TextColumnType columnType)
    Parameters
    Type Name Description
    System.String str
    System.String txt
    TextColumnType columnType
    Returns
    Type Description
    System.Boolean
    View Source

    SqlWildcard(String, String, TextColumnType)

    Declaration
    public static bool SqlWildcard(this string str, string txt, TextColumnType columnType)
    Parameters
    Type Name Description
    System.String str
    System.String txt
    TextColumnType columnType
    Returns
    Type Description
    System.Boolean
    • Improve this Doc
    • View Source
    In This Article
    • Methods
      • SqlContains(String, String, TextColumnType)
      • SqlEndsWith(String, String, TextColumnType)
      • SqlEquals(String, String, TextColumnType)
      • SqlIn<T>(IEnumerable<T>, T)
      • SqlNullableEquals<T>(Nullable<T>, Nullable<T>, T)
      • SqlStartsWith(String, String, TextColumnType)
      • SqlWildcard(String, String, TextColumnType)
    Back to top Copyright © 2016-present Umbraco
    Generated by DocFX