Change Query from Top 100 to ALL?

rhaas128

Board Regular
Joined
Jul 5, 2013
Messages
84
I have a sql query in Access 2010. I am trying to figure out how to pull all records instead of the top 100. Can anyone advise how to alter the current query?

Code:
SELECT TOP 100 dbo_Users.FirstName, dbo_Users.LastName, dbo_tbl_PersonnelActive.TSOID, dbo_Transactions.System, dbo_Transactions.OrderNbr, dbo_Project.ProjectNbr
FROM (dbo_Project RIGHT JOIN (dbo_Users INNER JOIN (dbo_Transactions INNER JOIN dbo_WorkOrder ON dbo_Transactions.OrderNbr = dbo_WorkOrder.OrderNbr) ON dbo_Users.SSN = dbo_Transactions.SecID) ON dbo_Project.OrderNbr = dbo_Transactions.OrderNbr) INNER JOIN dbo_tbl_PersonnelActive ON (dbo_Users.LastName = dbo_tbl_PersonnelActive.LastName) AND (dbo_Users.FirstName = dbo_tbl_PersonnelActive.FirstName)
WHERE (((dbo_Transactions.SecClose)>=Date()-3 And (dbo_Transactions.SecClose)<date()-2) (dbo_Users.LastName)="user2" Or="" ((dbo_Users.LastName)="user1" AND="" ))
GROUP BY dbo_Users.FirstName, dbo_Users.LastName, dbo_tbl_PersonnelActive.TSOID, dbo_Transactions.System, dbo_Transactions.OrderNbr, dbo_Project.ProjectNbr;
</date()-2)>
 

Excel Facts

Which Excel functions can ignore hidden rows?
The SUBTOTAL and AGGREGATE functions ignore hidden rows. AGGREGATE can also exclude error cells and more.
Just remove the words "TOP 100" after "SELECT".
 
Upvote 0

Forum statistics

Threads
1,215,444
Messages
6,124,891
Members
449,194
Latest member
JayEggleton

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top