HOW TO RETRIVE MORE THAN 1000 RECORDS FROM ACTIVE DIRECTORY

  • How to retrive more than 1000 results from active directory ??

    i observed in some articles than there is max page limit of 1000 in Active directory ,

    is there any OPENQUERY Tsql to retrive more than 1000 results from ad? or any looping method

    or can we write a SSIS package to retrieve more than 1000 reuslts ?

    guys help me out

  • billa i could not find the way to get more than 1000 records via linked server;

    looks like it is much easier with powershell; by assigning it a page size, you get all the results, as it automatically requeries to get the results:

    http://www.microsoft.com/technet/scriptcenter/topics/winpsh/searchad.mspx

    ...Next we assign the value 1000 to the PageSize property. By default, an Active Directory search returns only 1000 items; if your domain includes 1001 items that last item will not be returned. The way to get around that issue is to assign a value to the PageSize property [of powershell]. When you do that, your search script will return (in this case) the first 1,000 items, pause for a split second, then return the next 1,000. This process will continue until all the items meeting the search criteria have been returned.

    Lowell


    --help us help you! If you post a question, make sure you include a CREATE TABLE... statement and INSERT INTO... statement into that table to give the volunteers here representative data. with your description of the problem, we can provide a tested, verifiable solution to your question! asking the question the right way gets you a tested answer the fastest way possible!

Viewing 2 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic. Login to reply