将两个字段合并为一个 [英] joining two field into one

查看:86
本文介绍了将两个字段合并为一个的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

大家好!

这是我的奎里酒

hi to all!

here is my querry

insert into TableName values(@id,@Name,cast(@id as varchar(50))+@Name)


e.g. id= 123 name=asdf then iname=123asdf but i want like this asdf123 how to do this

推荐答案

只需将其互换.
Just interchange it.
insert into TableName values(@id,@Name,@Name+cast(@id as varchar(50)))


为什么不先取名字然后再添加ID
why dont you take name first and then id to add


这篇关于将两个字段合并为一个的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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