由买买提看人间百态

boards

本页内容为未名空间相应帖子的节选和存档,一周内的贴子最多显示50字,超过一周显示500字 访问原贴
Database版 - another sql operation question
相关主题
One Q for DB expert要面试了 怎么准备
SSRS 牛人请进问一个crystal report的问题
db2 charactor 的数据类型好像没有info retrieval 的版面啊?
mysql problem in practice一个很平常的问题
求助:如何用统计的方法来描绘一个数据库数据 收集 的 问题 (转载)
[转载] Weblog: DB vs. XML?MS dynamics CRM + SSRS
问个初级问题.不要笑话RDL和RDLC的问题
处理大数据库的硬件问一下SAS SQL在大数据方面的处理
相关话题的讨论汇总
话题: col话题: 1string话题: here话题: operation话题: string
进入Database版参与讨论
1 (共1页)
c*******o
发帖数: 1722
1
have a huge dataset. dumped for 7 hours. unfortunatley, had a small mistake.
here is the problem.
col_1 is a string and col_2 is also a string but very similar to col_1. The
only difference is that col_2 has one or two more charactors than col_1. I
only need to keep the last one or two charators of col_2. How do I do it?
Here is an example:
I now have:
col_1 col_2
1string 1string1
2string 2string23
what I want:
col_1 col_2
1string
c*******o
发帖数: 1722
2
got this figured out myself. this is an easy one.
update tbl_a
set col_2 = (select replace(col_2, col_1, ''));

mistake.
The

【在 c*******o 的大作中提到】
: have a huge dataset. dumped for 7 hours. unfortunatley, had a small mistake.
: here is the problem.
: col_1 is a string and col_2 is also a string but very similar to col_1. The
: only difference is that col_2 has one or two more charactors than col_1. I
: only need to keep the last one or two charators of col_2. How do I do it?
: Here is an example:
: I now have:
: col_1 col_2
: 1string 1string1
: 2string 2string23

1 (共1页)
进入Database版参与讨论
相关主题
问一下SAS SQL在大数据方面的处理求助:如何用统计的方法来描绘一个数据库
讨论,(Big)Data Engineer到底是个什么职位[转载] Weblog: DB vs. XML?
informix==>oracle?问个初级问题.不要笑话
how to dump a file from Oracle处理大数据库的硬件
One Q for DB expert要面试了 怎么准备
SSRS 牛人请进问一个crystal report的问题
db2 charactor 的数据类型好像没有info retrieval 的版面啊?
mysql problem in practice一个很平常的问题
相关话题的讨论汇总
话题: col话题: 1string话题: here话题: operation话题: string