如何加入两个字段 [英] How to join two fields

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

问题描述

您好,


这可能是一个已经解决的愚蠢问题,但

我试过搜索但什么都没发现。如何将两个字段合并为一个?

假设我有一张具有此记录的表格:


JOHN |史密斯| 555-1234


我想加入前两个字段,以便得到的表格具有

的记录:


JOHN SMITH | 555-1234

我该怎么办?谢谢!


迭戈

Hello,

This is probably a silly question that has been addressed already, but
I tried searching and found nothing. How do I join two fields into one?
Suppose I have a table that has this record:

JOHN | SMITH | 555-1234

and I want to join the first two fields so that the resulting table has
the record:

JOHN SMITH | 555-1234

How can I do it? Thanks!

Diego

推荐答案

2005年12月23日19:52:57 - 0800, co****@ironcito.com 写道:
On 23 Dec 2005 19:52:57 -0800, co****@ironcito.com wrote:
你好,

这可能是一个已经解决的愚蠢问题,但是我试过搜索却一无所获。如何将两个字段合并为一个?
假设我有一张具有此记录的表格:

JOHN |史密斯| 555-1234

我想加入前两个字段,以便得到的表格有记录:

JOHN SMITH | 555-1234

我该怎么办?谢谢!

迭戈
Hello,

This is probably a silly question that has been addressed already, but
I tried searching and found nothing. How do I join two fields into one?
Suppose I have a table that has this record:

JOHN | SMITH | 555-1234

and I want to join the first two fields so that the resulting table has
the record:

JOHN SMITH | 555-1234

How can I do it? Thanks!

Diego




您打算在哪里使用连锁数据?


如果在查询中使用类似的东西 -


SELECT [FirstName]& " " &安培; [LastName]作为FullName来自tblSomeTable;


在查询构建器中,您可以将其输入为FullName:[FirstName]& " " &安培;下一个网格顶行的[LastName]。

如果要在表单或报表中用作控件的ControlSource -


= [FirstName]& " " &安培; [LastName]


如果您的数据有可能包含尾随空格,您可以使用 -


Trim([FirstName])& ; " " & Trim([LastName])


删除尾随空格。


Wayne Gillespie

Gosford NSW澳大利亚



Where do you intend to use the concatenated data?

If in a query use something like -

SELECT [FirstName] & " " & [LastName] As FullName From tblSomeTable;

In the query builder you would enter this as FullName:[FirstName] & " " & [LastName] in the top line of the lower grid.

If it is to be used as the ControlSource of a control in a form or report -

=[FirstName] & " " & [LastName]

If there is a chance that your data may contain trailing spaces you can use -

Trim([FirstName]) & " " &Trim([LastName])

to remove the trailing spaces.

Wayne Gillespie
Gosford NSW Australia


2005年12月23日19:52:57 -0800, co *** *@ironcito.com 写道:
On 23 Dec 2005 19:52:57 -0800, co****@ironcito.com wrote:
你好,

这可能是一个已经解决的愚蠢问题,但是
我试着搜索,一无所获。如何将两个字段合并为一个?
假设我有一张具有此记录的表格:

JOHN |史密斯| 555-1234

我想加入前两个字段,以便得到的表格有记录:

JOHN SMITH | 555-1234

我该怎么办?谢谢!

迭戈
Hello,

This is probably a silly question that has been addressed already, but
I tried searching and found nothing. How do I join two fields into one?
Suppose I have a table that has this record:

JOHN | SMITH | 555-1234

and I want to join the first two fields so that the resulting table has
the record:

JOHN SMITH | 555-1234

How can I do it? Thanks!

Diego



预先警告......有人可能会责骂你没有搜索谷歌

或访问帮助。你可以说[FName]& " " &安培; [LName]加入

名字和由空格分隔的姓氏。看起来你

让电话号码部分拍下来。顺便说一句,如果你搜索google

,你将在加入字段中获得大约1.15亿次点击。有些人可能会告诉你

这是一个很好的信息来源。我不会。


Be forewarned... someone may scold you for not searching google
or Access HELP. You can just say [FName] & " " & [LName] to join
first name and the last name separated by a space. Looks like you
have the phone number part down pat. BTW, if you do search google
you''ll get about 115-million hits on "join fields". Some may tell you
that''s a good information source. I won''t.


2005年12月29日星期四00:25:31 -0500,MLH< CR ** @ NorthState.net>写道:

On Thu, 29 Dec 2005 00:25:31 -0500, MLH <CR**@NorthState.net> wrote:

预先警告......有人可能会责骂你没有搜索谷歌
或访问帮助。你可以说[FName]& " " &安培; [LName]加入
名字和姓氏用空格分隔。看起来你好了电话号码部分。顺便说一句,如果你搜索google
你将在加入字段中获得大约1.15亿次点击。有些人可能会告诉你
这是一个很好的信息来源。我不会。
Be forewarned... someone may scold you for not searching google
or Access HELP. You can just say [FName] & " " & [LName] to join
first name and the last name separated by a space. Looks like you
have the phone number part down pat. BTW, if you do search google
you''ll get about 115-million hits on "join fields". Some may tell you
that''s a good information source. I won''t.




MLH


我知道你讨厌阅读,但我真的建议你阅读 http://www.mvps.org/access/netiquette.htm

如果你想乘坐你的高马,最终结果是你会得到越来越少的常客,他们愿意为你提供帮助(即:你输了)。 CDMA是一个巨大的资源,许多非常有才华的人愿意提供帮助,

但是没有人喜欢做别人的家庭作业。


我建议你a)精益有效使用帮助文件,b)学会有效地搜索Google(特别是Google

组)和c)最重要的是,学会倾听。

Wayne Gillespie
Gosford NSW Australia



MLH

I know you hate to read but I really recommend you read http://www.mvps.org/access/netiquette.htm
If you want to ride your ride your high horse the end result is that you will get less and less regulars who are willing
to offer you help (ie: you lose). CDMA is a tremendous resource with many highly talented people willing to offer help,
but nobody likes to do someone else homework.

I suggest you a) lean to use the help files effectively, b) learn to search Google effectively (especially Google
groups) and c) most importantly, learn to listen.
Wayne Gillespie
Gosford NSW Australia


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

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