Table of Contents

Class CompatibilitySchema.ForeignKey

Namespace
LinqToDB.Tools.DataProvider.SqlServer.Schemas
Assembly
linq2db.Tools.dll

sys.sysforeignkeys (Transact-SQL)

Applies to: √ SQL Server (all supported versions)

Contains information about the FOREIGN KEY constraints that are in the definitions of tables in the database.

important


This SQL Server 2000 system table is included as a view for backward compatibility. We recommend that you use the current SQL Server system views instead. To find the equivalent system view or views, see Mapping System Tables to System Views (Transact-SQL). This feature will be removed in a future version of Microsoft SQL Server. Avoid using this feature in new development work, and plan to modify applications that currently use this feature.


See sys.sysforeignkeys.

[Table(Schema = "sys", Name = "sysforeignkeys", IsView = true)]
public class CompatibilitySchema.ForeignKey
Inheritance
CompatibilitySchema.ForeignKey
Extension Methods

Properties

ConstraintID

ID of the FOREIGN KEY constraint.

[Column("constid")]
[NotNull]
public int ConstraintID { get; set; }

Property Value

int

FKey

ID of the referencing column.

[Column("fkey")]
[Nullable]
public short? FKey { get; set; }

Property Value

short?

FKeyID

Object ID of the table with the FOREIGN KEY constraint.

[Column("fkeyid")]
[NotNull]
public int FKeyID { get; set; }

Property Value

int

KeyNo

Position of the column in the reference column list.

[Column("keyno")]
[Nullable]
public short? KeyNo { get; set; }

Property Value

short?

RKey

ID of the referenced column.

[Column("rkey")]
[Nullable]
public short? RKey { get; set; }

Property Value

short?

RKeyID

Object ID of the table referenced in the FOREIGN KEY constraint.

[Column("rkeyid")]
[NotNull]
public int RKeyID { get; set; }

Property Value

int