Hello,
I've been trying to write a formula to return an ID based on two criteria: 1. a unique premises ID, and 2. category type. The data sits on one sheet, the return info on another.
It looks like this:
DATA (In Table2):
[TABLE="width: 500"]
<tbody>[TR]
[TD]PIN[/TD]
[TD]PINStatus[/TD]
[TD]PINTYPE[/TD]
[TD]PREMISESID[/TD]
[/TR]
[TR]
[TD]01[/TD]
[TD]Revoked[/TD]
[TD]PON[/TD]
[TD]123[/TD]
[/TR]
[TR]
[TD]02[/TD]
[TD]Active[/TD]
[TD]HIPON[/TD]
[TD]223[/TD]
[/TR]
[TR]
[TD]03[/TD]
[TD]Active[/TD]
[TD]MIPON[/TD]
[TD]233[/TD]
[/TR]
[TR]
[TD]04[/TD]
[TD]Revoked[/TD]
[TD]HIPON[/TD]
[TD]123[/TD]
[/TR]
[TR]
[TD]05[/TD]
[TD]Active[/TD]
[TD]PON[/TD]
[TD]243[/TD]
[/TR]
[TR]
[TD]06[/TD]
[TD]Revoked[/TD]
[TD]MIPON[/TD]
[TD]123[/TD]
[/TR]
</tbody>[/TABLE]
Trying to organize it, in a different sheet, like so:
[TABLE="width: 500"]
<tbody>[TR]
[TD]Premises ID[/TD]
[TD]PON[/TD]
[TD]PON#[/TD]
[TD]HIPON[/TD]
[TD]HIPON#[/TD]
[TD]MIPON[/TD]
[TD]MIPON#[/TD]
[/TR]
[TR]
[TD]123[/TD]
[TD]Y[/TD]
[TD]01[/TD]
[TD]Y[/TD]
[TD]04[/TD]
[TD]Y[/TD]
[TD]06[/TD]
[/TR]
</tbody>[/TABLE]
I have this:
Which has returned results, but the wrong ones.
Any help would be appreciated.
I've been trying to write a formula to return an ID based on two criteria: 1. a unique premises ID, and 2. category type. The data sits on one sheet, the return info on another.
It looks like this:
DATA (In Table2):
[TABLE="width: 500"]
<tbody>[TR]
[TD]PIN[/TD]
[TD]PINStatus[/TD]
[TD]PINTYPE[/TD]
[TD]PREMISESID[/TD]
[/TR]
[TR]
[TD]01[/TD]
[TD]Revoked[/TD]
[TD]PON[/TD]
[TD]123[/TD]
[/TR]
[TR]
[TD]02[/TD]
[TD]Active[/TD]
[TD]HIPON[/TD]
[TD]223[/TD]
[/TR]
[TR]
[TD]03[/TD]
[TD]Active[/TD]
[TD]MIPON[/TD]
[TD]233[/TD]
[/TR]
[TR]
[TD]04[/TD]
[TD]Revoked[/TD]
[TD]HIPON[/TD]
[TD]123[/TD]
[/TR]
[TR]
[TD]05[/TD]
[TD]Active[/TD]
[TD]PON[/TD]
[TD]243[/TD]
[/TR]
[TR]
[TD]06[/TD]
[TD]Revoked[/TD]
[TD]MIPON[/TD]
[TD]123[/TD]
[/TR]
</tbody>[/TABLE]
Trying to organize it, in a different sheet, like so:
[TABLE="width: 500"]
<tbody>[TR]
[TD]Premises ID[/TD]
[TD]PON[/TD]
[TD]PON#[/TD]
[TD]HIPON[/TD]
[TD]HIPON#[/TD]
[TD]MIPON[/TD]
[TD]MIPON#[/TD]
[/TR]
[TR]
[TD]123[/TD]
[TD]Y[/TD]
[TD]01[/TD]
[TD]Y[/TD]
[TD]04[/TD]
[TD]Y[/TD]
[TD]06[/TD]
[/TR]
</tbody>[/TABLE]
I have this:
=IF(AND((INDEX(Table2[PremisesID],(MATCH(A13,Table2[PremisesID],0))))=A13,(INDEX(Table2[PINType],(MATCH(Table1[PON],Table2[PINTYPE]))))=Table1[PON]),LEFT(Table2[PIN)],999),"N")
Which has returned results, but the wrong ones.
Any help would be appreciated.