生成像A0001,....的系列 [英] Generating series like A0001,....

查看:89
本文介绍了生成像A0001,....的系列的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想生成A0001,A0002等系列...... A9999,B0001,B0002 ...... B9999,C0001 .... C9999,





在sql server 2008中使用自动增量编号



请帮助我....这是紧急的

解决方案

以下是您的需求:

http://msdn.microsoft.com/en-us/library/8wch342y%28v=vs.110%29.aspx [ ^ ](可能是任何其他方法的对应方法)整数类型),

http:// msdn .microsoft.com / zh-CN / library / dwhawy9k(v = vs.110).aspx [ ^ ],

http://msdn.microsoft.com/en-us/library/0c899ak8(v = vs.110).aspx [ ^ ]。



格式化将帮助您自动填充具有适当数量的零的数字,以具有固定的字符串长度。



-SA

检查以下链接

Sql Server中的编号系统 [ ^ ]


I want to generate series like A0001,A0002....A9999,B0001,B0002......B9999,C0001....C9999,


using auto incremental number in sql server 2008

Please help me....it's urgent

解决方案

Here is what you need:
http://msdn.microsoft.com/en-us/library/8wch342y%28v=vs.110%29.aspx[^] (could be a corresponding method of any other integer type),
http://msdn.microsoft.com/en-us/library/dwhawy9k(v=vs.110).aspx[^],
http://msdn.microsoft.com/en-us/library/0c899ak8(v=vs.110).aspx[^].

Formatting will help you to automatically pad digits with appropriate number of zeros, to have a fixed string length.

—SA


check below link
Numbering system in Sql Server[^]


这篇关于生成像A0001,....的系列的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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