惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

cs.AI updates on arXiv.org
cs.AI updates on arXiv.org
P
Palo Alto Networks Blog
S
Securelist
Threat Intelligence Blog | Flashpoint
Threat Intelligence Blog | Flashpoint
NISL@THU
NISL@THU
L
Lohrmann on Cybersecurity
有赞技术团队
有赞技术团队
The GitHub Blog
The GitHub Blog
C
Cisco Blogs
B
Blog
Microsoft Azure Blog
Microsoft Azure Blog
Recent Announcements
Recent Announcements
Simon Willison's Weblog
Simon Willison's Weblog
T
Tenable Blog
Know Your Adversary
Know Your Adversary
Spread Privacy
Spread Privacy
WordPress大学
WordPress大学
月光博客
月光博客
Latest news
Latest news
C
CXSECURITY Database RSS Feed - CXSecurity.com
T
Threat Research - Cisco Blogs
Cisco Talos Blog
Cisco Talos Blog
I
InfoQ
D
Darknet – Hacking Tools, Hacker News & Cyber Security
W
WeLiveSecurity
Hacker News - Newest:
Hacker News - Newest: "LLM"
酷 壳 – CoolShell
酷 壳 – CoolShell
U
Unit 42
C
Cybersecurity and Infrastructure Security Agency CISA
博客园 - 聂微东
人人都是产品经理
人人都是产品经理
Google DeepMind News
Google DeepMind News
Apple Machine Learning Research
Apple Machine Learning Research
Attack and Defense Labs
Attack and Defense Labs
罗磊的独立博客
T
The Exploit Database - CXSecurity.com
I
Intezer
GbyAI
GbyAI
Jina AI
Jina AI
www.infosecurity-magazine.com
www.infosecurity-magazine.com
Blog — PlanetScale
Blog — PlanetScale
博客园 - 司徒正美
Google Online Security Blog
Google Online Security Blog
Engineering at Meta
Engineering at Meta
D
Docker
Recent Commits to openclaw:main
Recent Commits to openclaw:main
小众软件
小众软件
云风的 BLOG
云风的 BLOG
爱范儿
爱范儿
Project Zero
Project Zero

博客园 - hi-justin

O.O 一次蛮搞笑的面试 为什么老是这么忙呢? 祝自己生日快乐:) 反省一下 实现了一个一直以来梦想 Time 如何用正确的方法来写出质量好的软件的75条体会[收藏] 還有一塊錢哪去了? 爆強ERP Never forget :) 終於可以稍微輕松一下了 遇到這種問題,你會怎麼做? 美好的一天,耶 [備忘]动态显示图片 寫下來,免得下次又忘了 小記一下 過梅林海關的幾次有趣經歷
[備忘]用於分解字符串的自定義函數
hi-justin · 2004-11-21 · via 博客园 - hi-justin

/*
function name:decStoreCode
purporse:分解以逗號分開的StoreCode字符串
author:seven
create date:2004/11/20
modifer:seven
modified date:2004/8/21
use exam:
*/

CREATE FUNCTION decStoreCode
 (
    @StoreCode 
nvarchar(255)--傳入BillNo字符串
)  
RETURNS @TabStoreCode Table(StoreCode nvarchar(20))

AS  
BEGIN 
    
declare @strCurSub varchar(60)--當前的截取部分
    declare @strBehindSub varchar(255)--後面的截取部分
    declare @intCurPost int--當前的位置
    declare @intLefLen int--剩下部分的長度

    
set @intCurPost = charindex(',',@StoreCode)--得到分號的位置
    if(@intCurPost>0)
        
begin
            
set @strCurSub=substring(@StoreCode,1,@intCurPost-1);
            
set @intLefLen=len(@StoreCode)-@intCurPost
            
set @strBehindSub=substring(@StoreCode,@intCurPost+1,@intLefLen)
        
end
    
else
        
begin
            
set @strCurSub=@StoreCode
        
end

        
insert @TabStoreCode values(@strCurSub)--分解到table中
    while @intCurPost>0
        
begin
            
set @intCurPost=charindex(',',@strBehindSub)

            
if @intCurPost!=0
                
begin
                    
set @intLefLen=@intLefLen-@intCurPost
                    
set @strCurSub=substring(@strBehindSub,1,@intCurPost-1)
                    
set @strBehindSub=substring(@strBehindSub,@intCurPost+1,@intLefLen)
                
end 
            
else
                
begin
                    
set @strCurSub=@strBehindSub
                
end
                
                
insert @TabStoreCode values(@strCurSub)--分解到table中
        end
        
return--返回资料集合
END