[Home]   [FAQ]   [Search]   [Memberlist]   [Usergroups]   [Register]

Author Message
kaybrimar
Newbie

Joined: 25 Jul 2012
Posts: 2

Posted: Wed Jul 25, 2012 1:10 pm    Post subject: Need help on a multiple occurrence array formula

This is what I have presently:

 Code: =IF(ISERROR(INDEX(EventsList;SMALL(IF(EventsList=A\$1;ROW(EventsList));ROW(1:1));2));"";INDEX(EventsList;SMALL(IF(EventsList=A\$1;ROW(EventsList));ROW(1:1));2))

It isn't pulling up the next occurrence in the "EventsList" range; what am I missing or doing wrong?
ken johnson
Super User

Joined: 23 Apr 2009
Posts: 1988
Location: Sydney, Australia

 Posted: Wed Jul 25, 2012 5:44 pm    Post subject: Immediately identifiable problem is your use of ROW(1:1). This works in xl but not in Calc, where A1:AMJ1 must be used instead of 1:1. However, I don't think using ROW(A1:AMJ1) will be any good either as it will simply keep returning 1 and SMALL(IF(EventsList=A\$1;ROW(EventsList));ROW(1:1)) will only return the smallest value in the array generated by IF(EventsList=A\$1;ROW(EventsList)) Perhaps you should be using something like SMALL(IF(EventsList=A\$1;ROW(EventsList);"");ROW(EventsList)-MIN(ROW(EventsList))+1) instead of SMALL(IF(EventsList=A\$1;ROW(EventsList));ROW(1:1)). Also, how many columns makes up the EventsList named range? The 2 in your formula (the INDEX function's third parameter) implies more than one column, while "EventsList=A\$1" (the IF function's first parameter) implies one column. Ken Johnson_________________If your problem has been solved please add "[Solved]" to the beginning of your first post title (edit button).
 Display posts from previous: All Posts1 Day7 Days2 Weeks1 Month3 Months6 Months1 Year Oldest FirstNewest First
 All times are GMT - 8 Hours Page 1 of 1

 Jump to: Select a forum OpenOffice.org Forums----------------Setup and TroubleshootingOpenOffice.org WriterOpenOffice.org CalcOpenOffice.org ImpressOpenOffice.org DrawOpenOffice.org MathOpenOffice.org BaseOpenOffice.org Macros and APIOpenOffice.org Code Snippets Community Forums----------------General DiscussionSite Feedback
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum