TYPE=VIEW
query=select `heatwatch`.`v_milk`.`milk_Date` AS `milk_Date`,round(ifnull((`heatwatch`.`v_milk`.`day_milk` + `heatwatch`.`v_milk`.`xh_wt`),\'\'),0) AS `day_milk`,ifnull(`heatwatch`.`v_milk`.`sale_wt`,\'\') AS `sale_wt`,ifnull(round(((`heatwatch`.`v_milk`.`day_milk` + `heatwatch`.`v_milk`.`xh_wt`) / `heatwatch`.`eventcount`.`todayTotal`),1),\'\') AS `milk_wt`,ifnull(round(((`heatwatch`.`v_milk`.`day_milk` + `heatwatch`.`v_milk`.`xh_wt`) / `heatwatch`.`eventcount`.`monthTotal`),1),\'\') AS `adult_wt`,`heatwatch`.`v_milk`.`intPastureId` AS `intPastureId` from (`heatwatch`.`v_milk` join `heatwatch`.`eventcount` on(((to_days(`heatwatch`.`v_milk`.`milk_Date`) = to_days(`heatwatch`.`eventcount`.`created`)) and (`heatwatch`.`eventcount`.`reporttype` = \'milkcount\') and (`heatwatch`.`v_milk`.`intPastureId` = `heatwatch`.`eventcount`.`intPastureId`)))) order by `heatwatch`.`v_milk`.`milk_Date` desc
md5=c14afb311ad6e1f8e221395001f88198
updatable=1
algorithm=0
definer_user=roo
definer_host=%
suid=1
with_check_option=0
timestamp=2022-12-14 10:07:38
create-version=1
source=select `v_milk`.`milk_Date` AS `milk_Date`,round(ifnull(`v_milk`.`day_milk` + `v_milk`.`xh_wt`,\'\'),0) AS `day_milk`,ifnull(`v_milk`.`sale_wt`,\'\') AS `sale_wt`,ifnull(round((`v_milk`.`day_milk` + `v_milk`.`xh_wt`) / `eventcount`.`todayTotal`,1),\'\') AS `milk_wt`,ifnull(round((`v_milk`.`day_milk` + `v_milk`.`xh_wt`) / `eventcount`.`monthTotal`,1),\'\') AS `adult_wt`,`v_milk`.`intPastureId` AS `intPastureId` from (`v_milk` join `eventcount` on(to_days(`v_milk`.`milk_Date`) = to_days(`eventcount`.`created`) and `eventcount`.`reporttype` = \'milkcount\' and `v_milk`.`intPastureId` = `eventcount`.`intPastureId`)) order by `v_milk`.`milk_Date` desc
client_cs_name=utf8
connection_cl_name=utf8_general_ci
view_body_utf8=select `heatwatch`.`v_milk`.`milk_Date` AS `milk_Date`,round(ifnull((`heatwatch`.`v_milk`.`day_milk` + `heatwatch`.`v_milk`.`xh_wt`),\'\'),0) AS `day_milk`,ifnull(`heatwatch`.`v_milk`.`sale_wt`,\'\') AS `sale_wt`,ifnull(round(((`heatwatch`.`v_milk`.`day_milk` + `heatwatch`.`v_milk`.`xh_wt`) / `heatwatch`.`eventcount`.`todayTotal`),1),\'\') AS `milk_wt`,ifnull(round(((`heatwatch`.`v_milk`.`day_milk` + `heatwatch`.`v_milk`.`xh_wt`) / `heatwatch`.`eventcount`.`monthTotal`),1),\'\') AS `adult_wt`,`heatwatch`.`v_milk`.`intPastureId` AS `intPastureId` from (`heatwatch`.`v_milk` join `heatwatch`.`eventcount` on(((to_days(`heatwatch`.`v_milk`.`milk_Date`) = to_days(`heatwatch`.`eventcount`.`created`)) and (`heatwatch`.`eventcount`.`reporttype` = \'milkcount\') and (`heatwatch`.`v_milk`.`intPastureId` = `heatwatch`.`eventcount`.`intPastureId`)))) order by `heatwatch`.`v_milk`.`milk_Date` desc
