473,399 Members | 3,401 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,399 software developers and data experts.

ddl for union queries

Greetings Access gurus.

I have clients with Access databases in the field that I need to update
-- new tables, new indices, new queries, the works. Since these clients
may have only the Access runtime, automation isn't an option for me; I
need to rely on DDL (through Oledb at the moment but if necessary I
could use something else). My DDL works fine with the exception of
views (queries) that have union clauses. Any DDL of the form

CREATE VIEW ... SELECT ... UNION SELECT ...

produces a "union operation is not supported in subqueries" error. The
queries themselves are valid; I can create them in the query designer,
or programmatically in an Access module, and they save and run just
fine. It's only DDL that's giving me the problem.

Any suggestions or workarounds?

Regards,
Aaron

Nov 13 '05 #1
2 2440

"Aaron Haspel" <ah*****@gmail.com> wrote in message
news:11*********************@f14g2000cwb.googlegro ups.com...
Greetings Access gurus.

I have clients with Access databases in the field that I need to update -- new tables, new indices, new queries, the works. Since these clients may have only the Access runtime, automation isn't an option for me; I need to rely on DDL (through Oledb at the moment but if necessary I
could use something else). My DDL works fine with the exception of
views (queries) that have union clauses. Any DDL of the form
Just the CREATE VIEWs with queries that have UNION clauses? Really?
That's pretty wild. :/ I'd have thought you'd have trouble with *any*
CREATE VIEW.


CREATE VIEW ... SELECT ... UNION SELECT ...
Aaron Haspel,

That's becasue CREATE VIEW is not supported by JET.

Check JETSQL40.CHM

Type "view" in the index field. Select "View keyworld"

"Note The Microsoft Jet database engine does not support the use of
CREATE VIEW, [...]."


Any suggestions or workarounds?


The closest is to just use a QueryDef.
Sincerely,

Chris O.
Nov 13 '05 #2
Chris--

Thanks for the reply. I know the docs say that Jet does not support
"CREATE VIEW" and I was surprised myself. But nevertheless a simple
"CREATE VIEW" statement will execute correctly through OleDb against at
least an Access 2000 db or higher.

As I was saying, I can't use a QueryDef, much as I would like to,
because that requires automating the Access object, right? Since some
of my clients have only the runtime I can't take that approach, if I
understand this correctly.

Aaron

Nov 13 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

10
by: KENNY L. CHEN | last post by:
Dear experts, I have two tables in my Oracle 8i database: TEST (COL1,COl2,REC_NO) and TEST1 (COL1,COL2,REC_NO). Both tables are unique-indexed on (COL1,COL2,REC_NO). I think the following...
8
by: lyn.duong | last post by:
Hi, I have a large table (about 50G) which stores data for over 7 years. I decided to split this table up into a yearly basis and in order to allow minimum changes to the applications which...
6
by: _link98 | last post by:
Problem: getting SQL0181N for queries on nicknames to remote Union-All-View. Can't see what I'm doing wrong yet, maybe someone has seen this before. Environment: UDB ESE 8.1 + FIXPAK 9A, on...
2
by: Fred Zuckerman | last post by:
I have a union query joining two other queries, each with 62 fields. Interestingly, when I open the query it has the correct number of 2850 records. But if I then set a filter (using filter by...
0
by: s_gregory | last post by:
The mdb is considerable size 70 +- mb. A complex union query was working well, but when an additional union select... was added into the query, selecting identical fields from a different source,...
5
by: Alicia | last post by:
Hello everyone based on the data, I created a union query which produces this. SELECT ,,, 0 As ClosedCount FROM UNION SELECT ,, 0 AS OpenedCount, FROM ORDER BY , ;
4
by: shaun palmer | last post by:
when or Where do you use a union query ? how can I wright sql, tblPopulation,* tblcustomer,* one to one with all the appropriate attributes(field). Your help would be greatly...
12
by: Susan Bricker | last post by:
For those of you who have been following my posts - they all pertain to a Dog Competition Organization's Database. There are three classes that the dogs can participate: NOVICE, OPEN, and...
3
by: mikes | last post by:
I have 2 separate queries, which effectively are the same except they draw data from separate tables. Both tables are (design-wise) identical, only the data is different. for each query, there are...
5
by: BillCo | last post by:
I've encountered a problem while using ADO to save query objects. Union queries created normally (via the interface) appear in adox catelog.procedures rather than catelog.views. This is reasonably...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.