主键自定义使用C#或数据库顺序更新..... [英] Primary key customize using C#or database to update sequentially .....

查看:148
本文介绍了主键自定义使用C#或数据库顺序更新.....的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我现在需要如何使用C#创建自定义主键。示例:AB001。我需要从这个数字开始然后它需要自动更新....请有人帮助我

i need to now how to make a customize primary key using C#. Example : AB001. i need to start with this number then it need automatically update....please someone help me

推荐答案

它被称为计算专栏 [ ^ ]。



如需了解更多信息,请参阅:

使用SQL Server自定义自动生成的序列 [ ^ ]

http://stackoverflow.com/questions/1996831/custom-primarykey-generation-with -autoincrement [ ^ ]
It is known as a computed column[^].

For further informatio, please, see:
Custom Auto-Generated Sequences with SQL Server[^]
http://stackoverflow.com/questions/1996831/custom-primarykey-generation-with-autoincrement[^]


这篇关于主键自定义使用C#或数据库顺序更新.....的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆