using excel get TOU values

Avatar

sdg.matiaan
2022-02-25 08:33

you can get a provisional bill in excel using the =WEBSERVICE function.
You can enter this function into A1 (using your username and password and the meter Account number at 1092):

=WEBSERVICE('https://adam.pnpscada.com/getProvisionalBill.jsp?LOGIN=testme.testme&PWD=testme&startdate=2022-01-01&enddate=2022-02-01&key1=1092')

Then, for the different TOU values, you can use the following:
Peak:
=FILTERXML(A1,'//tname[contains(translate(.,'PEAK','peak'),'peak') and not(contains(translate(.,'OF','of'),'off'))]/../units')
Standard:
=FILTERXML(A1,'//tname[contains(translate(.,'STANDR','standr'),'standard') or contains(translate(.,'STD','std'),'std')]/../units')
Off Peak:
=FILTERXML(A1,'//tname[contains(translate(.,'OFPEAK','ofpeak'),'off peak')]/../units')

This requires the words Peak, Off Peak, Standard/Std to be in the name of line item, regardless of capitalization.


Tags: excel
Please log in to post a comment