By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
434,997 Members | 2,841 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 434,997 IT Pros & Developers. It's quick & easy.

Parameter query with IIF

P: 6
I have a query I am trying to create based on another query
(inventory) and a table. The inventory query shows the date, shift,
Die set and the # of shifts remaining for each die set in inventory.
The table has a corresponding date and shift field as well as two more
fields that tell me what die set was left in the line at the end of
the previous shift and what die set is staged to go in next (again
left from the previous shift). When the inventory query is run it
tells me what die set has the lowest inventory to the highest.
However, the die set with the lowest inventory may not be the one
already in line or the one staged to go in line next. I need to be
able to sort the new query so that the die set in line and the die set
staged to go next are 1st and second in the query followed by the
remaining die sets in ascending order. I'm thinking that I should set
criteria based on an IIF statement, but I'm not sure where to begin.
Can anyone provide some advice?

I am running Access 2003 on Windows XP.
Oct 14 '07 #1
Share this Question
Share on Google+
2 Replies


MMcCarthy
Expert Mod 10K+
P: 14,534
I can't quite follow your structure but I need to know how you determine in the table the order that the dies are set. You need to work this out logically before ever looking at it programatically.

It would help if you gave the SQL of the query you are using as well as the meta data of the table.

Here is an example of how to post table MetaData :
Table Name=tblBookings
Expand|Select|Wrap|Line Numbers
  1. Field; Type; IndexInfo
  2. StudentID; Autonumber; PK
  3. Family; String; FK
  4. Name; String
  5. University; String; FK
  6. Mark; Numeric
  7. LastAttendance; Date/Time
Oct 14 '07 #2

P: 6
I can't quite follow your structure but I need to know how you determine in the table the order that the dies are set. You need to work this out logically before ever looking at it programatically.

It would help if you gave the SQL of the query you are using as well as the meta data of the table.

Here is an example of how to post table MetaData :
Table Name=tblBookings
Expand|Select|Wrap|Line Numbers
  1. Field; Type; IndexInfo
  2. StudentID; Autonumber; PK
  3. Family; String; FK
  4. Name; String
  5. University; String; FK
  6. Mark; Numeric
  7. LastAttendance; Date/Time
Its okay, I was able to work out something that will work.
Oct 14 '07 #3

Post your reply

Sign in to post your reply or Sign up for a free account.