Bonjour,
pas facile de travailler avec des cellules fusionnées
rien que pour une "tranche" de E à H (test1)
=arrayformula(query(split(flatten('Planning Profs'!A8:A&"~"&'Planning Profs'!E1&"~"&'Planning Profs'!E4&"~"&'Planning Profs'!E6&"~"&'Planning Profs'!E8:E&"~"&'Planning Profs'!G8:G&"~"&'Planning Profs'!H8:H);"~");"select Col5,Col1,Col2,Col6,Col4,Col3 where Col7 = '"&$A$2&"' ";0))
ou (test2)
=sort(arrayformula(query(split(flatten('Planning Profs'!A8:A&"~"&'Planning Profs'!E1&"~"&'Planning Profs'!E4&"~"&'Planning Profs'!E6&"~"&'Planning Profs'!E8:E&"~"&'Planning Profs'!G8:G&"~"&'Planning Profs'!H8:H);"~");"select Col7,Col5,Col1,Col2,Col6,Col4,Col3 where Col7 is not null";0)))
il faudra maintenant empiler le reste des colonnes ... et il y a 39 dates !!
pour 2 semaines (test2)
=sort({
arrayformula(query(split(flatten('Planning Profs'!A8:A&"~"&'Planning Profs'!E1&"~"&'Planning Profs'!E4&"~"&'Planning Profs'!E6&"~"&'Planning Profs'!E8:E&"~"&'Planning Profs'!G8:G&"~"&'Planning Profs'!H8:H);"~");"select Col7,Col5,Col1,Col2,Col6,Col4,Col3 where Col7 is not null";0));
arrayformula(query(split(flatten('Planning Profs'!A8:A&"~"&'Planning Profs'!I1&"~"&'Planning Profs'!I4&"~"&'Planning Profs'!I6&"~"&'Planning Profs'!I8:I&"~"&'Planning Profs'!K8:K&"~"&'Planning Profs'!L8:L);"~");"select Col7,Col5,Col1,Col2,Col6,Col4,Col3 where Col7 is not null";0))
})
en bleu le critère, en jaune la formule à compléter
j'ai limité le nombre de lignes sinon cela ramait déjà trop !