Table of Contents

Class SqlServerExtensions

Namespace
LinqToDB.DataProvider.SqlServer
Assembly
linq2db.dll
public static class SqlServerExtensions
Inheritance
SqlServerExtensions

Methods

Contains(ISqlServerExtensions?, string, params object?[])

Applies full-text search condition using CONTAINS predicate against specified full-text columns or all FTS columns in table. Example: "CONTAINS((col1, col2), N'search')".

[Sql.Extension("CONTAINS(({tableOrColumns, ', '}), {search})", IsPredicate = true, ServerSideOnly = true)]
public static bool Contains(this ISqlServerExtensions? ext, string search, params object?[] tableOrColumns)

Parameters

ext ISqlServerExtensions

Extension point.

search string

Full-text search condition.

tableOrColumns object[]

Full-text columns that should be queried or table, if all FST columns should be queried.

Returns

bool

Returns true if full-text search found matching records.

ContainsProperty(ISqlServerExtensions?, object?, string, string)

Applies full-text search condition using CONTAINS(PROPERTY(...)) predicate against specified full-text column property. Example: "CONTAINS(PROPERTY(column, 'property'), N'search')".

[ExpressionMethod("ContainsPropertyImpl1")]
public static bool ContainsProperty(this ISqlServerExtensions? ext, object? column, string property, string search)

Parameters

ext ISqlServerExtensions

Extension point.

column object

Full-text column that should be queried.

property string

Name of document property to search in.

search string

Full-text search condition.

Returns

bool

Returns true if full-text search found matching records.

ContainsPropertyWithLanguage(ISqlServerExtensions?, object?, string, string, int)

Applies full-text search condition using CONTAINS(PROPERTY(...)) predicate against specified full-text column property. Example: "CONTAINS(PROPERTY(column, 'property'), N'search', LANGUAGE language_code)".

[ExpressionMethod("ContainsPropertyImpl3")]
public static bool ContainsPropertyWithLanguage(this ISqlServerExtensions? ext, object? column, string property, string search, int language)

Parameters

ext ISqlServerExtensions

Extension point.

column object

Full-text column that should be queried.

property string

Name of document property to search in.

search string

Full-text search condition.

language int

Language LCID code (see syslanguages.lcid).

Returns

bool

Returns true if full-text search found matching records.

ContainsPropertyWithLanguage(ISqlServerExtensions?, object?, string, string, string)

Applies full-text search condition using CONTAINS(PROPERTY(...)) predicate against specified full-text column property. Example: "CONTAINS(PROPERTY(column, 'property'), N'search', LANGUAGE N'language')".

[ExpressionMethod("ContainsPropertyImpl2")]
public static bool ContainsPropertyWithLanguage(this ISqlServerExtensions? ext, object? column, string property, string search, string language)

Parameters

ext ISqlServerExtensions

Extension point.

column object

Full-text column that should be queried.

property string

Name of document property to search in.

search string

Full-text search condition.

language string

Language name (see syslanguages.alias).

Returns

bool

Returns true if full-text search found matching records.

ContainsTableWithLanguage<TTable, TKey>(ISqlServerExtensions?, ITable<TTable>, Expression<Func<TTable, object?>>, string, int)

Performs full-text search query using CONTAINSTABLE function against specified full-text columns. Example: "CONTAINSTABLE(table, (col1, col2), N'search', LANGUAGE language_code)".

[ExpressionMethod("ContainsTableImpl12")]
public static IQueryable<SqlServerExtensions.FreeTextKey<TKey>> ContainsTableWithLanguage<TTable, TKey>(this ISqlServerExtensions? ext, ITable<TTable> table, Expression<Func<TTable, object?>> columns, string search, int language) where TTable : notnull

Parameters

ext ISqlServerExtensions

Extension point.

table ITable<TTable>

Table to perform full-text search query against.

columns Expression<Func<TTable, object>>

Selector expression for full-text columns that should be queried.

search string

Full-text search condition.

language int

Language LCID code (see syslanguages.lcid).

Returns

IQueryable<SqlServerExtensions.FreeTextKey<TKey>>

Returns full-text search ranking table.

Type Parameters

TTable

Queried table mapping class.

TKey

Full-text index key type.

ContainsTableWithLanguage<TTable, TKey>(ISqlServerExtensions?, ITable<TTable>, Expression<Func<TTable, object?>>, string, int, int)

Performs full-text search query using CONTAINSTABLE function against specified full-text columns. Example: "CONTAINSTABLE(table, (col1, col2), N'search', LANGUAGE language_code, top)".

[ExpressionMethod("ContainsTableImpl11")]
public static IQueryable<SqlServerExtensions.FreeTextKey<TKey>> ContainsTableWithLanguage<TTable, TKey>(this ISqlServerExtensions? ext, ITable<TTable> table, Expression<Func<TTable, object?>> columns, string search, int language, int top) where TTable : notnull

Parameters

ext ISqlServerExtensions

Extension point.

table ITable<TTable>

Table to perform full-text search query against.

columns Expression<Func<TTable, object>>

Selector expression for full-text columns that should be queried.

search string

Full-text search condition.

language int

Language LCID code (see syslanguages.lcid).

top int

Top filter to return top N ranked results.

Returns

IQueryable<SqlServerExtensions.FreeTextKey<TKey>>

Returns full-text search ranking table.

Type Parameters

TTable

Queried table mapping class.

TKey

Full-text index key type.

ContainsTableWithLanguage<TTable, TKey>(ISqlServerExtensions?, ITable<TTable>, Expression<Func<TTable, object?>>, string, string)

Performs full-text search query using CONTAINSTABLE function against specified full-text columns. Example: "CONTAINSTABLE(table, (col1, col2), N'search', LANGUAGE N'language')".

[ExpressionMethod("ContainsTableImpl10")]
public static IQueryable<SqlServerExtensions.FreeTextKey<TKey>> ContainsTableWithLanguage<TTable, TKey>(this ISqlServerExtensions? ext, ITable<TTable> table, Expression<Func<TTable, object?>> columns, string search, string language) where TTable : notnull

Parameters

ext ISqlServerExtensions

Extension point.

table ITable<TTable>

Table to perform full-text search query against.

columns Expression<Func<TTable, object>>

Selector expression for full-text columns that should be queried.

search string

Full-text search condition.

language string

Language name (see syslanguages.alias).

Returns

IQueryable<SqlServerExtensions.FreeTextKey<TKey>>

Returns full-text search ranking table.

Type Parameters

TTable

Queried table mapping class.

TKey

Full-text index key type.

ContainsTableWithLanguage<TTable, TKey>(ISqlServerExtensions?, ITable<TTable>, Expression<Func<TTable, object?>>, string, string, int)

Performs full-text search query using CONTAINSTABLE function against specified full-text columns. Example: "CONTAINSTABLE(table, (col1, col2), N'search', LANGUAGE N'language', top)".

[ExpressionMethod("ContainsTableImpl9")]
public static IQueryable<SqlServerExtensions.FreeTextKey<TKey>> ContainsTableWithLanguage<TTable, TKey>(this ISqlServerExtensions? ext, ITable<TTable> table, Expression<Func<TTable, object?>> columns, string search, string language, int top) where TTable : notnull

Parameters

ext ISqlServerExtensions

Extension point.

table ITable<TTable>

Table to perform full-text search query against.

columns Expression<Func<TTable, object>>

Selector expression for full-text columns that should be queried.

search string

Full-text search condition.

language string

Language name (see syslanguages.alias).

top int

Top filter to return top N ranked results.

Returns

IQueryable<SqlServerExtensions.FreeTextKey<TKey>>

Returns full-text search ranking table.

Type Parameters

TTable

Queried table mapping class.

TKey

Full-text index key type.

ContainsTableWithLanguage<TTable, TKey>(ISqlServerExtensions?, ITable<TTable>, string, int)

Performs full-text search query using CONTAINSTABLE function against all full-text columns in table. Example: "CONTAINSTABLE(table, *, N'search', LANGUAGE language_code, top)".

[ExpressionMethod("ContainsTableImpl6")]
public static IQueryable<SqlServerExtensions.FreeTextKey<TKey>> ContainsTableWithLanguage<TTable, TKey>(this ISqlServerExtensions? ext, ITable<TTable> table, string search, int language) where TTable : notnull

Parameters

ext ISqlServerExtensions

Extension point.

table ITable<TTable>

Table to perform full-text search query against.

search string

Full-text search condition.

language int

Language LCID code (see syslanguages.lcid).

Returns

IQueryable<SqlServerExtensions.FreeTextKey<TKey>>

Returns full-text search ranking table.

Type Parameters

TTable

Queried table mapping class.

TKey

Full-text index key type.

ContainsTableWithLanguage<TTable, TKey>(ISqlServerExtensions?, ITable<TTable>, string, int, int)

Performs full-text search query using CONTAINSTABLE function against all full-text columns in table. Example: "CONTAINSTABLE(table, *, N'search', LANGUAGE language_code)".

[ExpressionMethod("ContainsTableImpl5")]
public static IQueryable<SqlServerExtensions.FreeTextKey<TKey>> ContainsTableWithLanguage<TTable, TKey>(this ISqlServerExtensions? ext, ITable<TTable> table, string search, int language, int top) where TTable : notnull

Parameters

ext ISqlServerExtensions

Extension point.

table ITable<TTable>

Table to perform full-text search query against.

search string

Full-text search condition.

language int

Language LCID code (see syslanguages.lcid).

top int

Top filter to return top N ranked results.

Returns

IQueryable<SqlServerExtensions.FreeTextKey<TKey>>

Returns full-text search ranking table.

Type Parameters

TTable

Queried table mapping class.

TKey

Full-text index key type.

ContainsTableWithLanguage<TTable, TKey>(ISqlServerExtensions?, ITable<TTable>, string, string)

Performs full-text search query using CONTAINSTABLE function against all full-text columns in table. Example: "CONTAINSTABLE(table, *, N'search', LANGUAGE N'language')".

[ExpressionMethod("ContainsTableImpl3")]
public static IQueryable<SqlServerExtensions.FreeTextKey<TKey>> ContainsTableWithLanguage<TTable, TKey>(this ISqlServerExtensions? ext, ITable<TTable> table, string search, string language) where TTable : notnull

Parameters

ext ISqlServerExtensions

Extension point.

table ITable<TTable>

Table to perform full-text search query against.

search string

Full-text search condition.

language string

Language name (see syslanguages.alias).

Returns

IQueryable<SqlServerExtensions.FreeTextKey<TKey>>

Returns full-text search ranking table.

Type Parameters

TTable

Queried table mapping class.

TKey

Full-text index key type.

ContainsTableWithLanguage<TTable, TKey>(ISqlServerExtensions?, ITable<TTable>, string, string, int)

Performs full-text search query using CONTAINSTABLE function against all full-text columns in table. Example: "CONTAINSTABLE(table, *, N'search', LANGUAGE N'language', top)".

[ExpressionMethod("ContainsTableImpl4")]
public static IQueryable<SqlServerExtensions.FreeTextKey<TKey>> ContainsTableWithLanguage<TTable, TKey>(this ISqlServerExtensions? ext, ITable<TTable> table, string search, string language, int top) where TTable : notnull

Parameters

ext ISqlServerExtensions

Extension point.

table ITable<TTable>

Table to perform full-text search query against.

search string

Full-text search condition.

language string

Language name (see syslanguages.alias).

top int

Top filter to return top N ranked results.

Returns

IQueryable<SqlServerExtensions.FreeTextKey<TKey>>

Returns full-text search ranking table.

Type Parameters

TTable

Queried table mapping class.

TKey

Full-text index key type.

ContainsTable<TTable, TKey>(ISqlServerExtensions?, ITable<TTable>, Expression<Func<TTable, object?>>, string)

Performs full-text search query using CONTAINSTABLE function against specified full-text columns. Example: "CONTAINSTABLE(table, (col1, col2), N'search')".

[ExpressionMethod("ContainsTableImpl7")]
public static IQueryable<SqlServerExtensions.FreeTextKey<TKey>> ContainsTable<TTable, TKey>(this ISqlServerExtensions? ext, ITable<TTable> table, Expression<Func<TTable, object?>> columns, string search) where TTable : notnull

Parameters

ext ISqlServerExtensions

Extension point.

table ITable<TTable>

Table to perform full-text search query against.

columns Expression<Func<TTable, object>>

Selector expression for full-text columns that should be queried.

search string

Full-text search condition.

Returns

IQueryable<SqlServerExtensions.FreeTextKey<TKey>>

Returns full-text search ranking table.

Type Parameters

TTable

Queried table mapping class.

TKey

Full-text index key type.

ContainsTable<TTable, TKey>(ISqlServerExtensions?, ITable<TTable>, Expression<Func<TTable, object?>>, string, int)

Performs full-text search query using CONTAINSTABLE function against specified full-text columns. Example: "CONTAINSTABLE(table, (col1, col2), N'search', top)".

[ExpressionMethod("ContainsTableImpl8")]
public static IQueryable<SqlServerExtensions.FreeTextKey<TKey>> ContainsTable<TTable, TKey>(this ISqlServerExtensions? ext, ITable<TTable> table, Expression<Func<TTable, object?>> columns, string search, int top) where TTable : notnull

Parameters

ext ISqlServerExtensions

Extension point.

table ITable<TTable>

Table to perform full-text search query against.

columns Expression<Func<TTable, object>>

Selector expression for full-text columns that should be queried.

search string

Full-text search condition.

top int

Top filter to return top N ranked results.

Returns

IQueryable<SqlServerExtensions.FreeTextKey<TKey>>

Returns full-text search ranking table.

Type Parameters

TTable

Queried table mapping class.

TKey

Full-text index key type.

ContainsTable<TTable, TKey>(ISqlServerExtensions?, ITable<TTable>, string)

Performs full-text search query using CONTAINSTABLE function against all full-text columns in table. Example: "CONTAINSTABLE(table, *, N'search')".

[ExpressionMethod("ContainsTableImpl1")]
public static IQueryable<SqlServerExtensions.FreeTextKey<TKey>> ContainsTable<TTable, TKey>(this ISqlServerExtensions? ext, ITable<TTable> table, string search) where TTable : notnull

Parameters

ext ISqlServerExtensions

Extension point.

table ITable<TTable>

Table to perform full-text search query against.

search string

Full-text search condition.

Returns

IQueryable<SqlServerExtensions.FreeTextKey<TKey>>

Returns full-text search ranking table.

Type Parameters

TTable

Queried table mapping class.

TKey

Full-text index key type.

ContainsTable<TTable, TKey>(ISqlServerExtensions?, ITable<TTable>, string, int)

Performs full-text search query using CONTAINSTABLE function against all full-text columns in table. Example: "CONTAINSTABLE(table, *, N'search', top)".

[ExpressionMethod("ContainsTableImpl2")]
public static IQueryable<SqlServerExtensions.FreeTextKey<TKey>> ContainsTable<TTable, TKey>(this ISqlServerExtensions? ext, ITable<TTable> table, string search, int top) where TTable : notnull

Parameters

ext ISqlServerExtensions

Extension point.

table ITable<TTable>

Table to perform full-text search query against.

search string

Full-text search condition.

top int

Top filter to return top N ranked results.

Returns

IQueryable<SqlServerExtensions.FreeTextKey<TKey>>

Returns full-text search ranking table.

Type Parameters

TTable

Queried table mapping class.

TKey

Full-text index key type.

ContainsWithLanguage(ISqlServerExtensions?, string, int, params object?[])

Applies full-text search condition using CONTAINS predicate against specified full-text columns or all FTS columns in table. Example: "CONTAINS((col1, col2), N'search', LANGUAGE language_code)".

[Sql.Extension("CONTAINS(({tableOrColumns, ', '}), {search}, LANGUAGE {language})", IsPredicate = true, ServerSideOnly = true)]
public static bool ContainsWithLanguage(this ISqlServerExtensions? ext, string search, int language, params object?[] tableOrColumns)

Parameters

ext ISqlServerExtensions

Extension point.

search string

Full-text search condition.

language int

Language LCID code (see syslanguages.lcid).

tableOrColumns object[]

Full-text columns that should be queried or table, if all FST columns should be queried.

Returns

bool

Returns true if full-text search found matching records.

ContainsWithLanguage(ISqlServerExtensions?, string, string, params object?[])

Applies full-text search condition using CONTAINS predicate against specified full-text columns or all FTS columns in table. Example: "CONTAINS((col1, col2), N'search', LANGUAGE N'language')".

[Sql.Extension("CONTAINS(({tableOrColumns, ', '}), {search}, LANGUAGE {language})", IsPredicate = true, ServerSideOnly = true)]
public static bool ContainsWithLanguage(this ISqlServerExtensions? ext, string search, string language, params object?[] tableOrColumns)

Parameters

ext ISqlServerExtensions

Extension point.

search string

Full-text search condition.

language string

Language name (see syslanguages.alias).

tableOrColumns object[]

Full-text columns that should be queried or table, if all FST columns should be queried.

Returns

bool

Returns true if full-text search found matching records.

FreeText(ISqlServerExtensions?, string, params object?[])

Applies full-text search condition using FREETEXT predicate against specified full-text columns or all FTS columns in table. Example: "FREETEXT((col1, col2), N'search')".

[Sql.Extension("FREETEXT(({tableOrColumns, ', '}), {term})", IsPredicate = true, ServerSideOnly = true)]
public static bool FreeText(this ISqlServerExtensions? ext, string term, params object?[] tableOrColumns)

Parameters

ext ISqlServerExtensions

Extension point.

term string

Full-text search term.

tableOrColumns object[]

Full-text columns that should be queried or table, if all FST columns should be queried.

Returns

bool

Returns true if full-text search found matching records.

FreeTextTableWithLanguage<TTable, TKey>(ISqlServerExtensions?, ITable<TTable>, Expression<Func<TTable, object?>>, string, int)

Performs full-text search query using FREETEXTTABLE function against specified full-text columns. Example: "FREETEXTTABLE(table, (col1, col2), N'search', LANGUAGE language_code)".

[ExpressionMethod("FreeTextTableImpl12")]
public static IQueryable<SqlServerExtensions.FreeTextKey<TKey>> FreeTextTableWithLanguage<TTable, TKey>(this ISqlServerExtensions? ext, ITable<TTable> table, Expression<Func<TTable, object?>> columns, string term, int language) where TTable : notnull

Parameters

ext ISqlServerExtensions

Extension point.

table ITable<TTable>

Table to perform full-text search query against.

columns Expression<Func<TTable, object>>

Selector expression for full-text columns that should be queried.

term string

Full-text search term.

language int

Language LCID code (see syslanguages.lcid).

Returns

IQueryable<SqlServerExtensions.FreeTextKey<TKey>>

Returns full-text search ranking table.

Type Parameters

TTable

Queried table mapping class.

TKey

Full-text index key type.

FreeTextTableWithLanguage<TTable, TKey>(ISqlServerExtensions?, ITable<TTable>, Expression<Func<TTable, object?>>, string, int, int)

Performs full-text search query using FREETEXTTABLE function against specified full-text columns. Example: "FREETEXTTABLE(table, (col1, col2), N'search', LANGUAGE language_code, top)".

[ExpressionMethod("FreeTextTableImpl11")]
public static IQueryable<SqlServerExtensions.FreeTextKey<TKey>> FreeTextTableWithLanguage<TTable, TKey>(this ISqlServerExtensions? ext, ITable<TTable> table, Expression<Func<TTable, object?>> columns, string term, int language, int top) where TTable : notnull

Parameters

ext ISqlServerExtensions

Extension point.

table ITable<TTable>

Table to perform full-text search query against.

columns Expression<Func<TTable, object>>

Selector expression for full-text columns that should be queried.

term string

Full-text search term.

language int

Language LCID code (see syslanguages.lcid).

top int

Top filter to return top N ranked results.

Returns

IQueryable<SqlServerExtensions.FreeTextKey<TKey>>

Returns full-text search ranking table.

Type Parameters

TTable

Queried table mapping class.

TKey

Full-text index key type.

FreeTextTableWithLanguage<TTable, TKey>(ISqlServerExtensions?, ITable<TTable>, Expression<Func<TTable, object?>>, string, string)

Performs full-text search query using FREETEXTTABLE function against specified full-text columns. Example: "FREETEXTTABLE(table, (col1, col2), N'search', LANGUAGE N'language')".

[ExpressionMethod("FreeTextTableImpl9")]
public static IQueryable<SqlServerExtensions.FreeTextKey<TKey>> FreeTextTableWithLanguage<TTable, TKey>(this ISqlServerExtensions? ext, ITable<TTable> table, Expression<Func<TTable, object?>> columns, string term, string language) where TTable : notnull

Parameters

ext ISqlServerExtensions

Extension point.

table ITable<TTable>

Table to perform full-text search query against.

columns Expression<Func<TTable, object>>

Selector expression for full-text columns that should be queried.

term string

Full-text search term.

language string

Language name (see syslanguages.alias).

Returns

IQueryable<SqlServerExtensions.FreeTextKey<TKey>>

Returns full-text search ranking table.

Type Parameters

TTable

Queried table mapping class.

TKey

Full-text index key type.

FreeTextTableWithLanguage<TTable, TKey>(ISqlServerExtensions?, ITable<TTable>, Expression<Func<TTable, object?>>, string, string, int)

Performs full-text search query using FREETEXTTABLE function against specified full-text columns. Example: "FREETEXTTABLE(table, (col1, col2), N'search', LANGUAGE N'language', top)".

[ExpressionMethod("FreeTextTableImpl10")]
public static IQueryable<SqlServerExtensions.FreeTextKey<TKey>> FreeTextTableWithLanguage<TTable, TKey>(this ISqlServerExtensions? ext, ITable<TTable> table, Expression<Func<TTable, object?>> columns, string term, string language, int top) where TTable : notnull

Parameters

ext ISqlServerExtensions

Extension point.

table ITable<TTable>

Table to perform full-text search query against.

columns Expression<Func<TTable, object>>

Selector expression for full-text columns that should be queried.

term string

Full-text search term.

language string

Language name (see syslanguages.alias).

top int

Top filter to return top N ranked results.

Returns

IQueryable<SqlServerExtensions.FreeTextKey<TKey>>

Returns full-text search ranking table.

Type Parameters

TTable

Queried table mapping class.

TKey

Full-text index key type.

FreeTextTableWithLanguage<TTable, TKey>(ISqlServerExtensions?, ITable<TTable>, string, int)

Performs full-text search query using FREETEXTTABLE function against all full-text columns in table. Example: "FREETEXTTABLE(table, *, N'search', LANGUAGE language_code)".

[ExpressionMethod("FreeTextTableImpl6")]
public static IQueryable<SqlServerExtensions.FreeTextKey<TKey>> FreeTextTableWithLanguage<TTable, TKey>(this ISqlServerExtensions? ext, ITable<TTable> table, string term, int language) where TTable : notnull

Parameters

ext ISqlServerExtensions

Extension point.

table ITable<TTable>

Table to perform full-text search query against.

term string

Full-text search term.

language int

Language LCID code (see syslanguages.lcid).

Returns

IQueryable<SqlServerExtensions.FreeTextKey<TKey>>

Returns full-text search ranking table.

Type Parameters

TTable

Queried table mapping class.

TKey

Full-text index key type.

FreeTextTableWithLanguage<TTable, TKey>(ISqlServerExtensions?, ITable<TTable>, string, int, int)

Performs full-text search query using FREETEXTTABLE function against all full-text columns in table. Example: "FREETEXTTABLE(table, *, N'search', LANGUAGE language_code, top)".

[ExpressionMethod("FreeTextTableImpl5")]
public static IQueryable<SqlServerExtensions.FreeTextKey<TKey>> FreeTextTableWithLanguage<TTable, TKey>(this ISqlServerExtensions? ext, ITable<TTable> table, string term, int language, int top) where TTable : notnull

Parameters

ext ISqlServerExtensions

Extension point.

table ITable<TTable>

Table to perform full-text search query against.

term string

Full-text search term.

language int

Language LCID code (see syslanguages.lcid).

top int

Top filter to return top N ranked results.

Returns

IQueryable<SqlServerExtensions.FreeTextKey<TKey>>

Returns full-text search ranking table.

Type Parameters

TTable

Queried table mapping class.

TKey

Full-text index key type.

FreeTextTableWithLanguage<TTable, TKey>(ISqlServerExtensions?, ITable<TTable>, string, string)

Performs full-text search query using FREETEXTTABLE function against all full-text columns in table. Example: "FREETEXTTABLE(table, *, N'search', LANGUAGE N'language')".

[ExpressionMethod("FreeTextTableImpl3")]
public static IQueryable<SqlServerExtensions.FreeTextKey<TKey>> FreeTextTableWithLanguage<TTable, TKey>(this ISqlServerExtensions? ext, ITable<TTable> table, string term, string language) where TTable : notnull

Parameters

ext ISqlServerExtensions

Extension point.

table ITable<TTable>

Table to perform full-text search query against.

term string

Full-text search term.

language string

Language name (see syslanguages.alias).

Returns

IQueryable<SqlServerExtensions.FreeTextKey<TKey>>

Returns full-text search ranking table.

Type Parameters

TTable

Queried table mapping class.

TKey

Full-text index key type.

FreeTextTableWithLanguage<TTable, TKey>(ISqlServerExtensions?, ITable<TTable>, string, string, int)

Performs full-text search query using FREETEXTTABLE function against all full-text columns in table. Example: "FREETEXTTABLE(table, *, N'search', LANGUAGE N'language', top)".

[ExpressionMethod("FreeTextTableImpl4")]
public static IQueryable<SqlServerExtensions.FreeTextKey<TKey>> FreeTextTableWithLanguage<TTable, TKey>(this ISqlServerExtensions? ext, ITable<TTable> table, string term, string language, int top) where TTable : notnull

Parameters

ext ISqlServerExtensions

Extension point.

table ITable<TTable>

Table to perform full-text search query against.

term string

Full-text search term.

language string

Language name (see syslanguages.alias).

top int

Top filter to return top N ranked results.

Returns

IQueryable<SqlServerExtensions.FreeTextKey<TKey>>

Returns full-text search ranking table.

Type Parameters

TTable

Queried table mapping class.

TKey

Full-text index key type.

FreeTextTable<TTable, TKey>(ISqlServerExtensions?, ITable<TTable>, Expression<Func<TTable, object?>>, string)

Performs full-text search query using FREETEXTTABLE function against specified full-text columns. Example: "FREETEXTTABLE(table, (col1, col2), N'search')".

[ExpressionMethod("FreeTextTableImpl7")]
public static IQueryable<SqlServerExtensions.FreeTextKey<TKey>> FreeTextTable<TTable, TKey>(this ISqlServerExtensions? ext, ITable<TTable> table, Expression<Func<TTable, object?>> columns, string term) where TTable : notnull

Parameters

ext ISqlServerExtensions

Extension point.

table ITable<TTable>

Table to perform full-text search query against.

columns Expression<Func<TTable, object>>

Selector expression for full-text columns that should be queried.

term string

Full-text search term.

Returns

IQueryable<SqlServerExtensions.FreeTextKey<TKey>>

Returns full-text search ranking table.

Type Parameters

TTable

Queried table mapping class.

TKey

Full-text index key type.

FreeTextTable<TTable, TKey>(ISqlServerExtensions?, ITable<TTable>, Expression<Func<TTable, object?>>, string, int)

Performs full-text search query using FREETEXTTABLE function against specified full-text columns. Example: "FREETEXTTABLE(table, (col1, col2), N'search', top)".

[ExpressionMethod("FreeTextTableImpl8")]
public static IQueryable<SqlServerExtensions.FreeTextKey<TKey>> FreeTextTable<TTable, TKey>(this ISqlServerExtensions? ext, ITable<TTable> table, Expression<Func<TTable, object?>> columns, string term, int top) where TTable : notnull

Parameters

ext ISqlServerExtensions

Extension point.

table ITable<TTable>

Table to perform full-text search query against.

columns Expression<Func<TTable, object>>

Selector expression for full-text columns that should be queried.

term string

Full-text search term.

top int

Top filter to return top N ranked results.

Returns

IQueryable<SqlServerExtensions.FreeTextKey<TKey>>

Returns full-text search ranking table.

Type Parameters

TTable

Queried table mapping class.

TKey

Full-text index key type.

FreeTextTable<TTable, TKey>(ISqlServerExtensions?, ITable<TTable>, string)

Performs full-text search query using FREETEXTTABLE function against all full-text columns in table. Example: "FREETEXTTABLE(table, *, N'search')".

[ExpressionMethod("FreeTextTableImpl1")]
public static IQueryable<SqlServerExtensions.FreeTextKey<TKey>> FreeTextTable<TTable, TKey>(this ISqlServerExtensions? ext, ITable<TTable> table, string term) where TTable : notnull

Parameters

ext ISqlServerExtensions

Extension point.

table ITable<TTable>

Table to perform full-text search query against.

term string

Full-text search term.

Returns

IQueryable<SqlServerExtensions.FreeTextKey<TKey>>

Returns full-text search ranking table.

Type Parameters

TTable

Queried table mapping class.

TKey

Full-text index key type.

FreeTextTable<TTable, TKey>(ISqlServerExtensions?, ITable<TTable>, string, int)

Performs full-text search query using FREETEXTTABLE function against all full-text columns in table. Example: "FREETEXTTABLE(table, *, N'search', top)".

[ExpressionMethod("FreeTextTableImpl2")]
public static IQueryable<SqlServerExtensions.FreeTextKey<TKey>> FreeTextTable<TTable, TKey>(this ISqlServerExtensions? ext, ITable<TTable> table, string term, int top) where TTable : notnull

Parameters

ext ISqlServerExtensions

Extension point.

table ITable<TTable>

Table to perform full-text search query against.

term string

Full-text search term.

top int

Top filter to return top N ranked results.

Returns

IQueryable<SqlServerExtensions.FreeTextKey<TKey>>

Returns full-text search ranking table.

Type Parameters

TTable

Queried table mapping class.

TKey

Full-text index key type.

FreeTextWithLanguage(ISqlServerExtensions?, string, int, params object?[])

Applies full-text search condition using FREETEXT predicate against specified full-text columns or all FTS columns in table. Example: "FREETEXT((col1, col2), N'search', LANGUAGE language_code)".

[Sql.Extension("FREETEXT(({tableOrColumns, ', '}), {term}, LANGUAGE {language})", IsPredicate = true, ServerSideOnly = true)]
public static bool FreeTextWithLanguage(this ISqlServerExtensions? ext, string term, int language, params object?[] tableOrColumns)

Parameters

ext ISqlServerExtensions

Extension point.

term string

Full-text search term.

language int

Language LCID code (see syslanguages.lcid).

tableOrColumns object[]

Full-text columns that should be queried or table, if all FST columns should be queried.

Returns

bool

Returns true if full-text search found matching records.

FreeTextWithLanguage(ISqlServerExtensions?, string, string, params object?[])

Applies full-text search condition using FREETEXT predicate against specified full-text columns or all FTS columns in table. Example: "FREETEXT((col1, col2), N'search', LANGUAGE N'language')".

[Sql.Extension("FREETEXT(({tableOrColumns, ', '}), {term}, LANGUAGE {language})", IsPredicate = true, ServerSideOnly = true)]
public static bool FreeTextWithLanguage(this ISqlServerExtensions? ext, string term, string language, params object?[] tableOrColumns)

Parameters

ext ISqlServerExtensions

Extension point.

term string

Full-text search term.

language string

Language name (see syslanguages.alias).

tableOrColumns object[]

Full-text columns that should be queried or table, if all FST columns should be queried.

Returns

bool

Returns true if full-text search found matching records.

IsNull<T>(ISqlServerExtensions?, T?, T?)

Generates 'ISNULL( value, replacementValue )' function.

[Sql.Extension("ISNULL({value}, {replacementValue})", ServerSideOnly = true, IsNullable = Sql.IsNullableType.IfAllParametersNullable)]
public static T IsNull<T>(this ISqlServerExtensions? ext, T? value, T? replacementValue)

Parameters

ext ISqlServerExtensions

Extension point.

value T

Value to test whether is NULL.

replacementValue T

Value to replace.

Returns

T

Function returns a replacementValue if the value is NULL.

Type Parameters

T

Generic type.

SqlServer(ISqlExtension?)

public static ISqlServerExtensions? SqlServer(this Sql.ISqlExtension? ext)

Parameters

ext Sql.ISqlExtension

Returns

ISqlServerExtensions