Error using Where clause with 'or' condition inside GetDataBufferUsingFormula
Hello -
is there a way to make the below work inside GetDataBufferUsingFormula .
Getting Error processing script 'V#Periodic:F#EndBal_Input:A#:U1#USF02'.
Dim SrcDataBuffer As DataBuffer = api.Data.GetDataBufferUsingFormula("FilterMembers(V#Periodic:F#EndBal_Input:S#Actual:T#" & sLastActMth & ":U1#" & mCostCenter.Member.name & ",[A#[PNL].Base.Where((Name StartsWith '4') or (Name StartsWith '5') or (Name StartsWith '7') or (Name StartsWith 'X'))], [U3#[TopUD3].Base],[U2#[TopUD2].Base])").
Looks like not recognizing filter with 'or' inside where clause.
Below works fine without an 'or' condition.
Dim SrcDataBuffer As DataBuffer = api.Data.GetDataBufferUsingFormula("FilterMembers(V#Periodic:F#EndBal_Input:S#Actual:T#" & sLastActMth & ":U1#" & mCostCenter.Member.name & ",[A#[PNL].Base.Where(Name StartsWith '4')], [U3#[TopUD3].Base],[U2#[TopUD2].Base])").
Try this removing the square brackets from around the member name, so you don't have 2 sets.
Dim SrcDataBuffer As DataBuffer = api.Data.GetDataBufferUsingFormula("FilterMembers(V#Periodic:F#EndBal_Input:S#Actual:T#" & sLastActMth & ":U1#" & mCostCenter.Member.name & ",[A#PNL.Base.Where((Name StartsWith '4') or (Name StartsWith '5') or (Name StartsWith '7') or (Name StartsWith 'X'))], [U3#TopUD3.Base],[U2#TopUD2.Base])").