GetAllDocumentsbykey

Hi,

I have a view with a first sorted column by username category. I need to be able to do Getalldocuementsbykey with multiple keys and collect them in one collection. For example, The first column values can be “Sonal Patel” and “All Users”. I need to return all documents that have “Sonal Patel” in first column and also all documents that have “All Users” in first column and collect them in one collection and process them in a loop.

any suggestions?

Subject: GetAllDocumentsbykey

You can take an array of select items

like key(0-1) as string

key(0)=“sonal”

key(1) =“All”

doc.getAlldocumentbykey(key)

‘’‘’’

process through documents

Dev

Subject: RE: GetAllDocumentsbykey

Right, you can pass an array to GetAllDocumentsByKey, but it will not return what he’s looking for.

LS is really different from formulas here. If you pass an array, the first element of the array will be compared with the first sorted column, the second element will be compared to the second sorted column and so on.

The only way to get documents belonging to multiple categories is either to loop through them all (and in a further loop add the documents one by one to the original collection) or to change the view (or add a view) that will show all required docs under one category (or sort keyword).