- UID
- 12776740
- 阅读权限
- 100
- 帖子
- 32031
- 精华贴数
- 12
- 技术排名
- 18
- 技术积分
- 56495
- 社区排名
- 223
- 社区积分
- 11402
- 注册时间
- 2008-1-16
- 精华贴数
- 12
- 技术积分
- 56495
- 社区积分
- 11402
- 注册时间
- 2008-1-16
- 论坛徽章:
- 237
|
发表于 2009-11-7 14:21:32
|显示全部楼层
他的语法貌似不常见
18.1.3 Impure SQL Solution
You can split the string into letters recursively in a CTE without using
the concatenated SUBSTRING() calls.
WITH Letters (place, letter)
AS (-- Break up the string into single characters
VALUES (1, SUBSTRING(:test_string FROM 1 FOR 1)
UNION ALL
SELECT place+1, SUBSTRING (:test_string FROM place FOR 1)
FROM Wordlist
WHERE place < CHARLENGTH(:test_string)),
The bad news is that this works for only one str |
|