Developer Tools

Convert T-SQL scripts to entity classes

Paste T-SQL table scripts and generate clean, readable C# entity models for database-driven .NET applications.

转换器工作区

在左侧粘贴您的 SQL,在右侧获取干净的 C# 实体代码。

T-SQL 输入

CREATE TABLE

C# 实体输出

Entity Framework
支持的 SQL 类型 int, bigint, smallint, tinyint, bit, decimal, numeric, money, float, real, date, datetime, datetime2, time, uniqueidentifier, nvarchar, varchar, nchar, char, text, ntext 等等。
主键检测 支持内联 (Inline) 主键和常见的表级主键定义。
最佳结果 粘贴完整的 CREATE TABLE 语句,包括 Schema、可空性和长度。

T-SQL to Entity Converter

此页面专为希望获得具有快速转换、可读输出和实用的面向 Entity Framework 选项的在线 tsql to entity 工作流的开发者而构建。

  • Convert T-SQL CREATE TABLE definitions into C# entity classes
  • Handle common SQL Server types, lengths and nullable columns
  • Generate readable properties for application-level models
  • Useful for database-first .NET and Entity Framework workflows
常见问题

常见问题解答

Can this tool convert T-SQL to C# entities?

Yes. Paste a T-SQL CREATE TABLE script and the tool generates a C# entity class from the table definition.

Does it support nullable columns?

Yes. Nullable SQL columns can be mapped to nullable C# types where appropriate.

Is this useful for database-first development?

Yes. It helps create model classes quickly from existing SQL Server table definitions.