Using query results as criteria

  • Thread starter Thread starter Troy Carroll
  • Start date Start date
T

Troy Carroll

I have a select query that returns a list of active
UserID's for my database. I'd like to run an append query
that will add tasks for each of those ID's to a table by
running the query once for each ID in the select query,
placing that number in the criteria of UserID field of the
append query. Any advice?

(I apologize if this is answered here somewhere already.
I really really tried to find it first.)

TIA,
Troy
 
I have a select query that returns a list of active
UserID's for my database. I'd like to run an append query
that will add tasks for each of those ID's to a table by
running the query once for each ID in the select query,
placing that number in the criteria of UserID field of the
append query. Any advice?

(I apologize if this is answered here somewhere already.
I really really tried to find it first.)

Well, you don't need to do it this way. You can do it all in one
Append query! Just join the Select query to the append query, and
include the UserID as one of the fields to append.

If this doesn't make sense, please post the SQL view of the select
query and of the append query.
 
-----Original Message-----


Well, you don't need to do it this way. You can do it all in one
Append query! Just join the Select query to the append query, and
include the UserID as one of the fields to append.

If this doesn't make sense, please post the SQL view of the select
query and of the append query.


.


Thanks for the response. I should probably back up, give
you a little more of the picture.

I'm using Access 2003. I started off appending all rows at
once to my table. The table is linked to a list on
bCentral Sharepoint Services. The query contains 7 fields
and was returning 85 rows. I kept getting a error:
"Numeric field overflow. (Error 3349)
The data in a Btrieve field is too large to represent in
your application."

Ultimately I want to fix this problem, but since I'm
unsure right now if it's a Sharepoint or Access issue, I
needed a work around for the next week or so while I
investigate. I discovered that appending the Tasks to the
list one employee's worth at a time (there are only 15 of
us) returned results sets that didn't give me the error.
That's why I wanted to cycle through several smaller
append queries.

Given this larger issue, do you have any new advice?
Thanks for your help,
Troy
 
I'm using Access 2003. I started off appending all rows at
once to my table. The table is linked to a list on
bCentral Sharepoint Services. The query contains 7 fields
and was returning 85 rows. I kept getting a error:
"Numeric field overflow. (Error 3349)
The data in a Btrieve field is too large to represent in
your application."

Try changing this append query into a simple Select query (you can
change it back without losing anything if you don't save it). Open it
in datasheet view. Are there numbers greater than 32768 that you're
intending to append to an Integer field, or greater than two billion
odd intended for a Long Integer? That would cause this error. You may
want to try appending the numbers to a Currency datatype (which can
accommodate numbers into the trillions), or a Text datatype (if the
"number" is in fact an identifier or label rather than a value to be
used in mathematical expressions).
 
Try changing this append query into a simple Select query (you can
change it back without losing anything if you don't save it). Open it
in datasheet view. Are there numbers greater than 32768 that you're
intending to append to an Integer field, or greater than two billion
odd intended for a Long Integer? That would cause this error. You may
want to try appending the numbers to a Currency datatype (which can
accommodate numbers into the trillions), or a Text datatype (if the
"number" is in fact an identifier or label rather than a value to be
used in mathematical expressions).


.



Well, actually I received that error on a query appending
all Text fields.

I finally got frustrated enough to create a new list on
bCentral Sharepoint that had the same columns as the
orginal list. I connected to it and ran my queries just
fine. Go figure.

Anyway, thanks for your help. The currency trick is a
great one I'd never thought of before. I'll definately be
tucking that on in the quiver.

Troy
 
Back
Top