Old to New table and export

P

Pierre

I have a table built with some information I would like to use on a new
table. The new table will be used for export use only and not for
information to be entered via a new form. But I would like to have it update
as information is updated to TABLE1. A detail of what is trying to be done
is:
TABL1 have fields called [Given Name], [Other ID], [Tax ID], and [Location]
TABLE2 have fields called [Entry Name], [ID INFO], and [State]
I need [Entry Name] = [Given Name]
[ID INFO] = [Other ID] &â€, “& [Tax ID] (w/ a comma space between if possible)
[State] = [Location]
Information from TABLE2 well be used in a Query then exported to Excel.

Note: Colum headers on Excel most READ field name from TABLE2. My reason
for making new table is to include some fields that will not be used, but
need to be displayed on excel sheet.

Any and all assistance in this matter will be greatly appreciated.
 
K

Klatuu

If you are only using Table 2 to export to Excel, you don't need it. You can
create a select query that include the field you need. You can change the
field names that are exported by creating aliases in the query. For example
if you want Given Name to be Entry Name in the Excel file, you would to that
in your query builder

[Entry Name]: [Given Name]
 
P

Pierre

Thank you for the reply. This seems as if it would work, but what about the
blank fields that I am going to need.

Klatuu said:
If you are only using Table 2 to export to Excel, you don't need it. You can
create a select query that include the field you need. You can change the
field names that are exported by creating aliases in the query. For example
if you want Given Name to be Entry Name in the Excel file, you would to that
in your query builder

[Entry Name]: [Given Name]

--
Dave Hargis, Microsoft Access MVP


Pierre said:
I have a table built with some information I would like to use on a new
table. The new table will be used for export use only and not for
information to be entered via a new form. But I would like to have it update
as information is updated to TABLE1. A detail of what is trying to be done
is:
TABL1 have fields called [Given Name], [Other ID], [Tax ID], and [Location]
TABLE2 have fields called [Entry Name], [ID INFO], and [State]
I need [Entry Name] = [Given Name]
[ID INFO] = [Other ID] &â€, “& [Tax ID] (w/ a comma space between if possible)
[State] = [Location]
Information from TABLE2 well be used in a Query then exported to Excel.

Note: Colum headers on Excel most READ field name from TABLE2. My reason
for making new table is to include some fields that will not be used, but
need to be displayed on excel sheet.

Any and all assistance in this matter will be greatly appreciated.
 
K

Klatuu

What blank fields? Did I miss something in your original post?
--
Dave Hargis, Microsoft Access MVP


Pierre said:
Thank you for the reply. This seems as if it would work, but what about the
blank fields that I am going to need.

Klatuu said:
If you are only using Table 2 to export to Excel, you don't need it. You can
create a select query that include the field you need. You can change the
field names that are exported by creating aliases in the query. For example
if you want Given Name to be Entry Name in the Excel file, you would to that
in your query builder

[Entry Name]: [Given Name]

--
Dave Hargis, Microsoft Access MVP


Pierre said:
I have a table built with some information I would like to use on a new
table. The new table will be used for export use only and not for
information to be entered via a new form. But I would like to have it update
as information is updated to TABLE1. A detail of what is trying to be done
is:
TABL1 have fields called [Given Name], [Other ID], [Tax ID], and [Location]
TABLE2 have fields called [Entry Name], [ID INFO], and [State]
I need [Entry Name] = [Given Name]
[ID INFO] = [Other ID] &â€, “& [Tax ID] (w/ a comma space between if possible)
[State] = [Location]
Information from TABLE2 well be used in a Query then exported to Excel.

Note: Colum headers on Excel most READ field name from TABLE2. My reason
for making new table is to include some fields that will not be used, but
need to be displayed on excel sheet.

Any and all assistance in this matter will be greatly appreciated.
 
P

Pierre

Klatuu

I tried to combined two fields and rename a field names with no
avail. So I’m thinking that I did not convey my intent. I need to provide
an excel document to some receivers upon request. The headers most be the
same due to the shared information with all users of the excel document(s).
When it comes to admin information, i.e. Name, SSN, Location and a few
others, I will provided this. I currently have this information in a working
database. I want to add it to a table or query so that the information can
be merged to an excel doc. The small issue is that there are some fields
that need to be combined into one field. (TABLE1 has [FirstName] and
[LastName] and I need it to read [Full Name] on the Query or TABLE2) I also
need additional fields that are going to have a header when viewed on the
excel doc. I hope this helps add more clarity to my intent.
 
K

Klatuu

You shouldn't really need a second table for this. You can create a query to
use in your TransferSpreadsheet.

You can construct the query to provide the header names you want in the
Excel sheet by using aliases. For example, to combine the first and last
names into one field:

SELECT [FirstName] & " " & [LastName] AS [Full Name], ...

The same would be true for other fields or combination of fields that have
to have a different name.
 
P

Pierre

I'm getting a msg that reads
"The syntax of the subquery in this expression is incorrect.
Check the subquery's syntax and enclose the subquery in parentheses."

This is what I have entered - in the Query Window I have table1 open

Field: [First Name] & " " & [Last Name] AS [Full Name]
Table:
Sort:
Show: Check Mark
Critera:
or:

NOTE: I used Build... to add the information in the field. When I try to
check on anything else I get that msg. Any additional help

Klatuu said:
You shouldn't really need a second table for this. You can create a query to
use in your TransferSpreadsheet.

You can construct the query to provide the header names you want in the
Excel sheet by using aliases. For example, to combine the first and last
names into one field:

SELECT [FirstName] & " " & [LastName] AS [Full Name], ...

The same would be true for other fields or combination of fields that have
to have a different name.
--
Dave Hargis, Microsoft Access MVP


Pierre said:
Klatuu

I tried to combined two fields and rename a field names with no
avail. So I’m thinking that I did not convey my intent. I need to provide
an excel document to some receivers upon request. The headers most be the
same due to the shared information with all users of the excel document(s).
When it comes to admin information, i.e. Name, SSN, Location and a few
others, I will provided this. I currently have this information in a working
database. I want to add it to a table or query so that the information can
be merged to an excel doc. The small issue is that there are some fields
that need to be combined into one field. (TABLE1 has [FirstName] and
[LastName] and I need it to read [Full Name] on the Query or TABLE2) I also
need additional fields that are going to have a header when viewed on the
excel doc. I hope this helps add more clarity to my intent.
 
K

Klatuu

Post the SQL of your query so I can have a look.
--
Dave Hargis, Microsoft Access MVP


Klatuu said:
You shouldn't really need a second table for this. You can create a query to
use in your TransferSpreadsheet.

You can construct the query to provide the header names you want in the
Excel sheet by using aliases. For example, to combine the first and last
names into one field:

SELECT [FirstName] & " " & [LastName] AS [Full Name], ...

The same would be true for other fields or combination of fields that have
to have a different name.
--
Dave Hargis, Microsoft Access MVP


Pierre said:
Klatuu

I tried to combined two fields and rename a field names with no
avail. So I’m thinking that I did not convey my intent. I need to provide
an excel document to some receivers upon request. The headers most be the
same due to the shared information with all users of the excel document(s).
When it comes to admin information, i.e. Name, SSN, Location and a few
others, I will provided this. I currently have this information in a working
database. I want to add it to a table or query so that the information can
be merged to an excel doc. The small issue is that there are some fields
that need to be combined into one field. (TABLE1 has [FirstName] and
[LastName] and I need it to read [Full Name] on the Query or TABLE2) I also
need additional fields that are going to have a header when viewed on the
excel doc. I hope this helps add more clarity to my intent.
 
P

Pierre

SELECT Table1.[Given Name], Table1.[Sur Name], Table1.Alias, Table1.Country
FROM Table1;


--
Work is sometimes hard....but someone has to do it.


Klatuu said:
Post the SQL of your query so I can have a look.
--
Dave Hargis, Microsoft Access MVP


Klatuu said:
You shouldn't really need a second table for this. You can create a query to
use in your TransferSpreadsheet.

You can construct the query to provide the header names you want in the
Excel sheet by using aliases. For example, to combine the first and last
names into one field:

SELECT [FirstName] & " " & [LastName] AS [Full Name], ...

The same would be true for other fields or combination of fields that have
to have a different name.
--
Dave Hargis, Microsoft Access MVP


Pierre said:
Klatuu

I tried to combined two fields and rename a field names with no
avail. So I’m thinking that I did not convey my intent. I need to provide
an excel document to some receivers upon request. The headers most be the
same due to the shared information with all users of the excel document(s).
When it comes to admin information, i.e. Name, SSN, Location and a few
others, I will provided this. I currently have this information in a working
database. I want to add it to a table or query so that the information can
be merged to an excel doc. The small issue is that there are some fields
that need to be combined into one field. (TABLE1 has [FirstName] and
[LastName] and I need it to read [Full Name] on the Query or TABLE2) I also
need additional fields that are going to have a header when viewed on the
excel doc. I hope this helps add more clarity to my intent.
 
K

Klatuu

The SQL you posted is pretty straight forward. I don't see why it isn't
working for you. Is Alias is field in your table?

To combine the Given Name and Sur Name field into one field it should be:
SELECT Table1.[Given Name] & " " & Table1.[Sur Name] As [Full Name], Table1.Alias, Table1.Country
FROM Table1;
--
Dave Hargis, Microsoft Access MVP


Pierre said:
SELECT Table1.[Given Name], Table1.[Sur Name], Table1.Alias, Table1.Country
FROM Table1;


--
Work is sometimes hard....but someone has to do it.


Klatuu said:
Post the SQL of your query so I can have a look.
--
Dave Hargis, Microsoft Access MVP


Klatuu said:
You shouldn't really need a second table for this. You can create a query to
use in your TransferSpreadsheet.

You can construct the query to provide the header names you want in the
Excel sheet by using aliases. For example, to combine the first and last
names into one field:

SELECT [FirstName] & " " & [LastName] AS [Full Name], ...

The same would be true for other fields or combination of fields that have
to have a different name.
--
Dave Hargis, Microsoft Access MVP


:

Klatuu

I tried to combined two fields and rename a field names with no
avail. So I’m thinking that I did not convey my intent. I need to provide
an excel document to some receivers upon request. The headers most be the
same due to the shared information with all users of the excel document(s).
When it comes to admin information, i.e. Name, SSN, Location and a few
others, I will provided this. I currently have this information in a working
database. I want to add it to a table or query so that the information can
be merged to an excel doc. The small issue is that there are some fields
that need to be combined into one field. (TABLE1 has [FirstName] and
[LastName] and I need it to read [Full Name] on the Query or TABLE2) I also
need additional fields that are going to have a header when viewed on the
excel doc. I hope this helps add more clarity to my intent.
 
P

Pierre

That was so helpful, Thank you so much.
You didn't say anything about the blank fields, but I should be able to
figure that out. And Yes Alias is one of the fields in the table.
--
Work is sometimes hard....but someone has to do it.


Klatuu said:
The SQL you posted is pretty straight forward. I don't see why it isn't
working for you. Is Alias is field in your table?

To combine the Given Name and Sur Name field into one field it should be:
SELECT Table1.[Given Name] & " " & Table1.[Sur Name] As [Full Name], Table1.Alias, Table1.Country
FROM Table1;
--
Dave Hargis, Microsoft Access MVP


Pierre said:
SELECT Table1.[Given Name], Table1.[Sur Name], Table1.Alias, Table1.Country
FROM Table1;


--
Work is sometimes hard....but someone has to do it.


Klatuu said:
Post the SQL of your query so I can have a look.
--
Dave Hargis, Microsoft Access MVP


:

You shouldn't really need a second table for this. You can create a query to
use in your TransferSpreadsheet.

You can construct the query to provide the header names you want in the
Excel sheet by using aliases. For example, to combine the first and last
names into one field:

SELECT [FirstName] & " " & [LastName] AS [Full Name], ...

The same would be true for other fields or combination of fields that have
to have a different name.
--
Dave Hargis, Microsoft Access MVP


:

Klatuu

I tried to combined two fields and rename a field names with no
avail. So I’m thinking that I did not convey my intent. I need to provide
an excel document to some receivers upon request. The headers most be the
same due to the shared information with all users of the excel document(s).
When it comes to admin information, i.e. Name, SSN, Location and a few
others, I will provided this. I currently have this information in a working
database. I want to add it to a table or query so that the information can
be merged to an excel doc. The small issue is that there are some fields
that need to be combined into one field. (TABLE1 has [FirstName] and
[LastName] and I need it to read [Full Name] on the Query or TABLE2) I also
need additional fields that are going to have a header when viewed on the
excel doc. I hope this helps add more clarity to my intent.
 
K

Klatuu

I think I asked previously about the blank fields. Can you explain them to
me, please?
--
Dave Hargis, Microsoft Access MVP


Pierre said:
That was so helpful, Thank you so much.
You didn't say anything about the blank fields, but I should be able to
figure that out. And Yes Alias is one of the fields in the table.
--
Work is sometimes hard....but someone has to do it.


Klatuu said:
The SQL you posted is pretty straight forward. I don't see why it isn't
working for you. Is Alias is field in your table?

To combine the Given Name and Sur Name field into one field it should be:
SELECT Table1.[Given Name] & " " & Table1.[Sur Name] As [Full Name], Table1.Alias, Table1.Country
FROM Table1;
--
Dave Hargis, Microsoft Access MVP


Pierre said:
SELECT Table1.[Given Name], Table1.[Sur Name], Table1.Alias, Table1.Country
FROM Table1;


--
Work is sometimes hard....but someone has to do it.


:

Post the SQL of your query so I can have a look.
--
Dave Hargis, Microsoft Access MVP


:

You shouldn't really need a second table for this. You can create a query to
use in your TransferSpreadsheet.

You can construct the query to provide the header names you want in the
Excel sheet by using aliases. For example, to combine the first and last
names into one field:

SELECT [FirstName] & " " & [LastName] AS [Full Name], ...

The same would be true for other fields or combination of fields that have
to have a different name.
--
Dave Hargis, Microsoft Access MVP


:

Klatuu

I tried to combined two fields and rename a field names with no
avail. So I’m thinking that I did not convey my intent. I need to provide
an excel document to some receivers upon request. The headers most be the
same due to the shared information with all users of the excel document(s).
When it comes to admin information, i.e. Name, SSN, Location and a few
others, I will provided this. I currently have this information in a working
database. I want to add it to a table or query so that the information can
be merged to an excel doc. The small issue is that there are some fields
that need to be combined into one field. (TABLE1 has [FirstName] and
[LastName] and I need it to read [Full Name] on the Query or TABLE2) I also
need additional fields that are going to have a header when viewed on the
excel doc. I hope this helps add more clarity to my intent.
 
P

Pierre

The blank fields were just fields that really had nothing to do with entrees
that I have in my database. I just needed them for the receiver to add their
comments. I ended up adding a [blank field] in my database and renamed it in
the SQL.
--
Work is sometimes hard....but someone has to do it.


Klatuu said:
I think I asked previously about the blank fields. Can you explain them to
me, please?
--
Dave Hargis, Microsoft Access MVP


Pierre said:
That was so helpful, Thank you so much.
You didn't say anything about the blank fields, but I should be able to
figure that out. And Yes Alias is one of the fields in the table.
--
Work is sometimes hard....but someone has to do it.


Klatuu said:
The SQL you posted is pretty straight forward. I don't see why it isn't
working for you. Is Alias is field in your table?

To combine the Given Name and Sur Name field into one field it should be:

SELECT Table1.[Given Name] & " " & Table1.[Sur Name] As [Full Name], Table1.Alias, Table1.Country
FROM Table1;
--
Dave Hargis, Microsoft Access MVP


:

SELECT Table1.[Given Name], Table1.[Sur Name], Table1.Alias, Table1.Country
FROM Table1;


--
Work is sometimes hard....but someone has to do it.


:

Post the SQL of your query so I can have a look.
--
Dave Hargis, Microsoft Access MVP


:

You shouldn't really need a second table for this. You can create a query to
use in your TransferSpreadsheet.

You can construct the query to provide the header names you want in the
Excel sheet by using aliases. For example, to combine the first and last
names into one field:

SELECT [FirstName] & " " & [LastName] AS [Full Name], ...

The same would be true for other fields or combination of fields that have
to have a different name.
--
Dave Hargis, Microsoft Access MVP


:

Klatuu

I tried to combined two fields and rename a field names with no
avail. So I’m thinking that I did not convey my intent. I need to provide
an excel document to some receivers upon request. The headers most be the
same due to the shared information with all users of the excel document(s).
When it comes to admin information, i.e. Name, SSN, Location and a few
others, I will provided this. I currently have this information in a working
database. I want to add it to a table or query so that the information can
be merged to an excel doc. The small issue is that there are some fields
that need to be combined into one field. (TABLE1 has [FirstName] and
[LastName] and I need it to read [Full Name] on the Query or TABLE2) I also
need additional fields that are going to have a header when viewed on the
excel doc. I hope this helps add more clarity to my intent.
 
K

Klatuu

Okay, don't know how you did it, but in SQL you could do this:

SELECT Null As Comments

In Query design:

Comments: Null
--
Dave Hargis, Microsoft Access MVP


Pierre said:
The blank fields were just fields that really had nothing to do with entrees
that I have in my database. I just needed them for the receiver to add their
comments. I ended up adding a [blank field] in my database and renamed it in
the SQL.
--
Work is sometimes hard....but someone has to do it.


Klatuu said:
I think I asked previously about the blank fields. Can you explain them to
me, please?
--
Dave Hargis, Microsoft Access MVP


Pierre said:
That was so helpful, Thank you so much.
You didn't say anything about the blank fields, but I should be able to
figure that out. And Yes Alias is one of the fields in the table.
--
Work is sometimes hard....but someone has to do it.


:

The SQL you posted is pretty straight forward. I don't see why it isn't
working for you. Is Alias is field in your table?

To combine the Given Name and Sur Name field into one field it should be:

SELECT Table1.[Given Name] & " " & Table1.[Sur Name] As [Full Name], Table1.Alias, Table1.Country
FROM Table1;
--
Dave Hargis, Microsoft Access MVP


:

SELECT Table1.[Given Name], Table1.[Sur Name], Table1.Alias, Table1.Country
FROM Table1;


--
Work is sometimes hard....but someone has to do it.


:

Post the SQL of your query so I can have a look.
--
Dave Hargis, Microsoft Access MVP


:

You shouldn't really need a second table for this. You can create a query to
use in your TransferSpreadsheet.

You can construct the query to provide the header names you want in the
Excel sheet by using aliases. For example, to combine the first and last
names into one field:

SELECT [FirstName] & " " & [LastName] AS [Full Name], ...

The same would be true for other fields or combination of fields that have
to have a different name.
--
Dave Hargis, Microsoft Access MVP


:

Klatuu

I tried to combined two fields and rename a field names with no
avail. So I’m thinking that I did not convey my intent. I need to provide
an excel document to some receivers upon request. The headers most be the
same due to the shared information with all users of the excel document(s).
When it comes to admin information, i.e. Name, SSN, Location and a few
others, I will provided this. I currently have this information in a working
database. I want to add it to a table or query so that the information can
be merged to an excel doc. The small issue is that there are some fields
that need to be combined into one field. (TABLE1 has [FirstName] and
[LastName] and I need it to read [Full Name] on the Query or TABLE2) I also
need additional fields that are going to have a header when viewed on the
excel doc. I hope this helps add more clarity to my intent.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top