Liz-
Did you try:
SELECT [Item] AS ItemAdded FROM PNAdded
UNION SELECT [Item] AS ItemDropped FROM PNDropped
Item is an Access keyword. Note that the name of the column will be ItemAdded.
John Viescas, author
Microsoft Office Access 2010 Inside Out
Microsoft Office Access 2007 Inside Out
Building Microsoft Access Applications
Microsoft Office Access 2003 Inside Out
SQL Queries for Mere Mortals
http://www.viescas.com/
(Nashua, NH)
-----Original Message-----
From: MS_Access_Professionals@yahoogroups.com [mailto:MS_Access_Professionals@yahoogroups.com] On Behalf Of Liz Ravenwood
Sent: Friday, March 02, 2012 3:11 PM
To: 'MS_Access_Professionals@yahoogroups.com'
Subject: RE: [MS_AccessPros] Union of same field but from 2 different query results
It is John. It's kinda got me tripped out.
In the interest of moving forward I opted for 2 different reports instead of the combined report for now though, so I can look at it later.
Liz Ravenwood
Database Developer / Programmer
Super First Class Products
B/E Aerospace
O: 1.520.239.4808
www.beaerospace.com
-----Original Message-----
From: MS_Access_Professionals@yahoogroups.com [mailto:MS_Access_Professionals@yahoogroups.com] On Behalf Of John Viescas
Sent: Friday, March 02, 2012 1:01 PM
To: MS_Access_Professionals@yahoogroups.com
Subject: RE: [MS_AccessPros] Union of same field but from 2 different query results
Liz-
That looks OK. Is Item a field in ItemDropped and PNAdded?
John Viescas, author
Microsoft Office Access 2010 Inside Out
Microsoft Office Access 2007 Inside Out
Building Microsoft Access Applications
Microsoft Office Access 2003 Inside Out
SQL Queries for Mere Mortals
http://www.viescas.com/
(Nashua, NH)
-----Original Message-----
From: MS_Access_Professionals@yahoogroups.com [mailto:MS_Access_Professionals@yahoogroups.com] On Behalf Of Liz Ravenwood
Sent: Friday, March 02, 2012 1:27 PM
To: 'MS_Access_Professionals@yahoogroups.com'
Subject: [MS_AccessPros] Union of same field but from 2 different query results
See John et. al.,
I want to do something like this:
SELECT Item AS ItemAdded FROM PNAdded UNION SELECT Item AS ItemDropped FROM PNDropped;
But am getting prompted to enter the item as a parameter.
I could have sworn I'd done this before, but can't remember nor can't find any record.
Liz Ravenwood
Database Developer / Programmer
Super First Class Products
B/E Aerospace
O: 1.520.239.4808
www.beaerospace.com
-----Original Message-----
From: MS_Access_Professionals@yahoogroups.com [mailto:MS_Access_Professionals@yahoogroups.com] On Behalf Of Liz Ravenwood
Sent: Friday, March 02, 2012 11:24 AM
To: 'MS_Access_Professionals@yahoogroups.com'
Subject: RE: [MS_AccessPros] The sql to create a table
AHA! I just learned today that so is "Level" I'm not trying to do a union query and coming up with problems.
But... that is a different thread.
Liz Ravenwood
Database Developer / Programmer
Super First Class Products
B/E Aerospace
O: 1.520.239.4808
www.beaerospace.com
-----Original Message-----
From: MS_Access_Professionals@yahoogroups.com [mailto:MS_Access_Professionals@yahoogroups.com] On Behalf Of John Viescas
Sent: Friday, March 02, 2012 11:05 AM
To: MS_Access_Professionals@yahoogroups.com
Subject: RE: [MS_AccessPros] The sql to create a table
Liz-
Yes, TimeStamp is a reserved SQL word.
John Viescas, author
Microsoft Office Access 2010 Inside Out
Microsoft Office Access 2007 Inside Out
Building Microsoft Access Applications
Microsoft Office Access 2003 Inside Out
SQL Queries for Mere Mortals
http://www.viescas.com/
(Nashua, NH)
-----Original Message-----
From: MS_Access_Professionals@yahoogroups.com [mailto:MS_Access_Professionals@yahoogroups.com] On Behalf Of Liz Ravenwood
Sent: Friday, March 02, 2012 8:36 AM
To: 'MS_Access_Professionals@yahoogroups.com'
Subject: RE: [MS_AccessPros] The sql to create a table
John, I did, and it still didn't work.
I'm doing this:
strsql = "Create TABLE tmpIndBOMFirstDate (ID COUNTER, ProgSS TEXT, TimeStamp DATETIME)"
and am still getting a syntax error in field definition. TimeStamp isn't some type of DDL reserved word is it?
Liz Ravenwood
Database Developer / Programmer
Super First Class Products
B/E Aerospace
O: 1.520.239.4808
www.beaerospace.com
-----Original Message-----
From: MS_Access_Professionals@yahoogroups.com [mailto:MS_Access_Professionals@yahoogroups.com] On Behalf Of John Viescas
Sent: Thursday, March 01, 2012 4:59 PM
To: MS_Access_Professionals@yahoogroups.com
Subject: RE: [MS_AccessPros] The sql to create a table
Liz-
Try using COUNTER instead of AutoNumber.
John Viescas, author
Microsoft Office Access 2010 Inside Out
Microsoft Office Access 2007 Inside Out
Building Microsoft Access Applications
Microsoft Office Access 2003 Inside Out
SQL Queries for Mere Mortals
http://www.viescas.com/
(Boston, MA)
-----Original Message-----
From: MS_Access_Professionals@yahoogroups.com [mailto:MS_Access_Professionals@yahoogroups.com] On Behalf Of Liz Ravenwood
Sent: Thursday, March 01, 2012 1:52 PM
To: 'MS_Access_Professionals@yahoogroups.com'
Subject: [MS_AccessPros] The sql to create a table
Pros, I'm trying to get the sql to create a table with an autonumber, and I'm getting a syntax error. Actually, I'm getting a syntax error with just a regular integer. I went to the knowledgebase and it was using text and datetime and I saw nothing on an autonumber field. How do you do this?
strsql = "Create TABLE tmpIndBOMFirstDate (ID autonumber, ProgSS Text, TimeStamp DATETIME)"
Liz Ravenwood
Database Developer / Programmer
Super First Class Products
B/E Aerospace
O: 1.520.239.4808
www.beaerospace.com
This email (and all attachments) is for the sole use of the intended recipient(s) and may contain privileged and/or proprietary information. Any unauthorized review, use, disclosure or distribution is prohibited. If you are not the intended recipient, please contact the sender by reply e-mail and destroy all copies of the original message.
------------------------------------
Yahoo! Groups Links
------------------------------------
Yahoo! Groups Links
This email (and all attachments) is for the sole use of the intended recipient(s) and may contain privileged and/or proprietary information. Any unauthorized review, use, disclosure or distribution is prohibited. If you are not the intended recipient, please contact the sender by reply e-mail and destroy all copies of the original message.
------------------------------------
Yahoo! Groups Links
------------------------------------
Yahoo! Groups Links
This email (and all attachments) is for the sole use of the intended recipient(s) and may contain privileged and/or proprietary information. Any unauthorized review, use, disclosure or distribution is prohibited. If you are not the intended recipient, please contact the sender by reply e-mail and destroy all copies of the original message.
------------------------------------
Yahoo! Groups Links
This email (and all attachments) is for the sole use of the intended recipient(s) and may contain privileged and/or proprietary information. Any unauthorized review, use, disclosure or distribution is prohibited. If you are not the intended recipient, please contact the sender by reply e-mail and destroy all copies of the original message.
------------------------------------
Yahoo! Groups Links
------------------------------------
Yahoo! Groups Links
This email (and all attachments) is for the sole use of the intended recipient(s) and may contain privileged and/or proprietary information. Any unauthorized review, use, disclosure or distribution is prohibited. If you are not the intended recipient, please contact the sender by reply e-mail and destroy all copies of the original message.
------------------------------------
Yahoo! Groups Links
Jumat, 02 Maret 2012
RE: [MS_AccessPros] Union of same field but from 2 different query results
__._,_.___
.
__,_._,___
Langganan:
Posting Komentar (Atom)
Tidak ada komentar:
Posting Komentar