Re: Create Table?
- From: "Lyle Fairfield" <lylefairfield@xxxxxxx>
- Date: 11 Jul 2006 06:17:30 -0700
DFS wrote:
GCM wrote:
Hi,
I have a table that has the following fields; LName, FName and MName.
Also there are other fields in the table. I need to create another
table with those fields combined as "Trim([LName] & " " & [FName] & "
" & [MName]). How can I create this table?
Thanks in advance...
GCM
SELECT (Trim(LName) & ' ' & Trim(FName) & ' ' & Trim(MName)) AS FullName
INTO NewTable
FROM ExistingTable
WHERE ...
Years ago SELECT (Trim(LName) & ' ' & Trim(FName) & ' ' & Trim(MName))
might result in two spaces in some cases where a field was null or held
a zero length string. I don't know if that is the case anymore but a
solution has been discussed many times here as in:
http://groups.google.ca/group/comp.databases.ms-access/msg/a807ea4bc514ad10
where Arvin writes:
"Try:
=[Street1] & (", " + [Street2]) & (", " + [Town]) & (", " + [County]) &
(",
" + [PostCode])
The "+" operator will not concatenate with a null, while the "&" will."
Regardless, I am with Keith in wondering if creatig this table is
REALLY necessaryfor the original poster as the first part of your query
gives all that the new table gives.
.
- Follow-Ups:
- Re: Create Table?
- From: DFS
- Re: Create Table?
- References:
- Create Table?
- From: GCM
- Re: Create Table?
- From: DFS
- Create Table?
- Prev by Date: Re: Dates
- Next by Date: Re: Table Relationship Problem
- Previous by thread: Re: Create Table?
- Next by thread: Re: Create Table?
- Index(es):
Relevant Pages
|