The first version is rough
Http://blog.csdn.net/happyflystone/archive/2008/07/23/2700649.aspx
This record is detailed and forms are stored in the database.
Friends who need it can download and use it from my resources.
Http://download.csdn.net/user/happyflystone
Actually, there is no technical content
-
- ------------------------------------
-
- -- Author: flystone
-
- -- Version: v1.001
-
- -- Date: 2008-08-04 21:56:11
-
- -- Reprinted and indicated the source
-
- ------------------------------------
-
- Alter function f_getinfo (@ CID varchar (18 ))
-
- Returns varchar (100)
-
- As
-
- Begin
-
- -- No legality check
-
- Declare @ s varchar (100)
-
- Select @ s = isnull (@ s,'') +CaseWhen demo-='Region'Then'' ElseDemo-end
-
- From sfz_info
- Where dm = left (@ CID, 2) +'123'Or dm = left (@ CID, 4) +'00'Or dm = left (@ CID, 6)
-
- Order by DM
-
- Return@ S
-
- End
-
-
- Go
-
-
-
- Select DBO. f_getinfo ('123')
- /*
-
- Bytes ----------------------------------------------------------------------------------------------------
-
- Yanqing County, Beijing
-
- (The number of affected rows is 1)
-
- */
-
-
- Select DBO. f_getinfo ('123')
-
- /*
-
- Bytes ----------------------------------------------------------------------------------------------------
-
- Xicheng District, Beijing
-
-
- (The number of affected rows is 1)
-
-
- */
- Select DBO. f_getinfo ('123')
-
- /*
-
- Bytes ----------------------------------------------------------------------------------------------------
-
- Jinzhou Miao and Dong Autonomous County, HuaiHua City, Hunan Province
-
-
- (The number of affected rows is 1)
-
-
- */
-