Hi

I have the extract of code below

I want certain fields from the serviceschedule table

Where the Start Date >= to parameter pe_DateFrom and <= parameter pe_DateTo

and where branchid equals parameter pe_ Branch id or -1

I am not sure I have got the or part of teh code correct - what do I need to do?

Thanks

Allister



Source = Json.Document(
    Web.Contents(
      "https://api2.bre.com/table/serviceschedule?select=branchid, id,  inactive,  endtime, starttime, servicetypeid , status, teamid, eventid, timefrom, timeto, totalhours,  servicefees&$top=1000&$filter=starttime >= "
        & pe_DateFrom
        & " and endtime <= "
        & pe_DateTo
        & " and branchid="
        & #"pe_ Branch id" & " or branchid=-1" 
    )
  ),