Why Doesn't This Work?

S

Stewart Berman

Access 2007

Table1:
Field: ABC (AutoNumber)
PrimaryKey: ABC
Field: Data (Text)
Values:
ABC Data
1 abc
2 def


Table2:
Field: Lower (Long Integer)
Field: Upper (Long Integer)
Values:
Lower: 1
Upper: 3

Query:
DELETE Table1.*, Table1.ABC
FROM Table1, Table2
WHERE (((Table1.ABC)>[LOwer] And (Table1.ABC)<[Upper]));

When I run the above query I get:

Could not delete from specified table.

Any suggestions/help would be appreciated.
 
K

Krzysztof Naworyta

You can use DISTINCTROW word:

DELETE DISTINCTROW Table1.*
FROM Table1, Table2
WHERE (((Table1.ABC)>[LOwer] And (Table1.ABC)<[Upper]));

--
KN


Juzer Stewart Berman <[email protected]> napisa³
| Access 2007
|
| Table1:
| Field: ABC (AutoNumber)
| PrimaryKey: ABC
| Field: Data (Text)
| Values:
| ABC Data
| 1 abc
| 2 def
|
|
| Table2:
| Field: Lower (Long Integer)
| Field: Upper (Long Integer)
| Values:
| Lower: 1
| Upper: 3
|
| Query:
| DELETE Table1.*, Table1.ABC
| FROM Table1, Table2
| WHERE (((Table1.ABC)>[LOwer] And (Table1.ABC)<[Upper]));
|
| When I run the above query I get:
|
| Could not delete from specified table.
|
| Any suggestions/help would be appreciated.

--
KN

archiwum grupy:
http://groups.google.pl/advanced_search
(grupa: pl*msaccess)
 

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