text:
Preview: City Council agenda (May 29)
May 28, 2018 UncategorizedMike Benedetti
This week: Boards, commissions, and lots of small stuff.
Stop Selling the Tax Liens of the Elderly: Norman Guertin and 18 others have a citizen petition requesting that the city "stop selling tax liens of owner occupied houses of elderly persons over the age of 62 years to third parties."
Boards and Commissions: Paul Franco and Cathy Rao will be appointed to the Elder Affairs Commission; Eric Goldstein to the Parks Commission; Zachary Washburn to the G. A. R. Memorial Hall Board of Trustees; and Amy Skrzek to the Memorial Auditorium Board of Trustees. For other boards and commissions, the Council will vote to approve (or not): Stephen Quist to the Cable Advisory Committee; Priscilla Elsass to the Advisory Committee on the
Status of Women; Devin Canton to the Conservation Commission; and Albert LaValley to the Planning Board.
Preserving More Watershed Land: The city will spend $360,000 to take over, via "friendly eminent domain," 48 acres in Princeton that drain into one of our reservoirs.
Problem Properties: The Finance Committee has recommended the full Council vote on Councilor Rivera's request that the Manager create "a holistic task force that could focus on combating issues with properties consistently creating neighborhood and community problems." Presumably this would have a somewhat different focus than the existing Problem Properties and Quality of Life taskforces.
Held over from last week:
Notre Dame des Canadiens: Ted Conna (et al) have a bunch of proposals for the City Council, which if the Council approved them would help the effort to preserve this striking downtown church, currently long-vacant and scheduled for demolition.
Let's Not Crack Down So Hard On Flavored Tobacco: Councilor Bergman would like the Board of Health to hold back on restricting flavored tobacco sales to adult-only establishments, and instead consider other measures, like prohibiting the display of these products.
The Destructive Foul Balls of Vernon Hill Park: Councilor Rosen would like "additional steps" taken at the Verning Hill Park baseball field "to prevent foul balls from striking and damaging the homes and parked cars of neighbors on adjacent Ames Street."
This week: The budget begins, foul balls, Notre Dame.
Zoning: Agrand Realty LLC would like 223 Greenwood St (in Quinsig Village, adjacent to Rand Whitney) rezoned from single family residential to manufacturing. This matter will now go before the Planning Board.
Rectangular Fields: Cassie Giardina would like the city to allocate funding for rectangular sports fields as in the Tacoma St. and Great Brook Valley Master Plans.
Better Dump Access: Councilor Russell would like the city to consider letting people drop off large items and yellow bags of trash at the Millbury St DPW facility without making an appointment.
Garbage Can Ads: Councilor Russell would like a private company to maintain our public trash cans and fund this by putting ads on the trash cans.
Rideshare Money for Experimental Transit: So the city gets like ten cents for every Uber or Lyft ride originating in Worcester. For 2017, this was $85,000. Councilor Lukes would like the WRTA to spend this money to develop "pilot programs for alternative and innovative modes of transportation in place of the current transportation services and to include evaluation tools to measure the effectiveness of the pilot program."
Local Labor to Build South High?: The Mayor would like to know if the city can negotiate that local labor be used to build (the new) South High, and would also like to know more about our options for Doherty High.
The Budget: The City Manager has proposed a $650 million budget. The Council can now theoretically make some changes to this.
Rezoning 5 Reeves St: The Planning Board likes the proposal to clean up the zoning around 5 Reeves St., extending the amount that is residential and excluding all of it from the Commericial Corridors Overlay District. This proposal now goes to the Economic Development Committee for more debate.
Public and Private Streets: The Planning Board likes the proposal to make the private Weldon Street a public street. This now goes to the Public Works Committee for more debate.
The agenda is posted here.
There are recognitions and such.
The report of the Superintendent is "An Overview of the Process for District Site Visits" and I don't know what that means.
Teaching, Learning, and Student Supports is meeting Monday afternoon and is reporting out (on gifted programs, ice hockey, Mandarin Chinese, summer programs, and the future teachers' program at Worcester State).
There will be (only one is posted) responses from administration on free drivers' ed and on Earth Day.
Miss McCullough is requesting a report on vocational programs not at Worcester Tech.
Mr. O'Connell wants to appropriate the funding the state has allocated for students evacuated due to Hurricane Maria; he's going to be told that they'll do that at the FY19 budget hearing, as that's been said several times.
Mr. O'Connell (co-sponsored by five other members of the committee) has an item: "review the recommendations of the proposed Strategic Plan and assign them to appropriate Standing Committees of the School Committee, and/or to the Administration, for further analysis, consideration, discussion, and development." Two things: that puts the strategic plan on the agenda (important if you'd like to comment) and sets up a committee public process of review (which we haven't had so far).
Mr. O'Connell also wants to set up an English Learner Parent Advisory Council, per the LOOK bill; maybe we should have regulations first. Comments are due this Friday!
There is a request for approval of a prior fiscal year payment of $1,496.50 for services rendered to a Special Education student who was placed in the Uxbridge Public Schools.
There is a request that the Committee accept donations of:
– $4,000.00 from the WEDF for the Leap Program in collaboration with the Worcester Art Museum
– $250.00 from donors to Heard Street Discovery Academy for the purchase of a new classroom rug
– $1,000.00 from donors to a Doherty Memorial High School football player in memory of Thomas Walles
– $1,000.00 from Alliance Energy LLC to Grafton Street School
– $1,000.00 from a Foundation to the Goddard Scholars Academy for the purchase of a tuba for the their Band
– to Woodland Academy:
– $122.31 from CEC Entertainment Inc.
– $250.00 from the College of the Holy Cross
– $2,583.87 from the City of Worcester for being selected as a recipient of a Worcester Arts Council 2018 Award for their project "Making the Impossible Possible"
– to Tatnuck Magnet School:
– $4.50 from Box Tops for Education
– $85.00 from various donors
– $300.00 from I.U.O.E Local No. 4 Social Action Committee
– $500.00 from Country Bank
There is a request for approval of a High-Quality Instruction grant of $20,000 for working groups on curriculum.
There is an annoucement about Reading in our City week from Mr. Monfredo.
Mr. Comparetto has three related items on middle school sports: one on partnering with Recreation Worcester, and two on reports.
There is also (THIS IS IMPORTANT) a request that the committee accept a donation and approve an agreement with/from Berkshire Bank, successor to Commerce, of $500,000 for naming rights to Foley Stadium (extending the agreement) and replacing the turf field.
There is a non-specific posting around collective bargaining and/or litigation for executive session.


Sitting on the beach, enjoying some coconut water, and reading a book sounds pretty perfect right now… but unfortunately, it is the peak of the Spring season and we still have a few more months till Summer is officially here.
That doesn't mean you can't have the perks of coconuts. However, it just means we need to incorporate the healthy use of coconut oil into our lives since it has tons of benefits! Here are 10 reasons you need to go out and buy some coconut oil now!
Coconut oil has properties that are antiviral, antifungal, and antibacterial.
You can cook with it, plus it has great value in nutrition!
Since it's so healthy for your skin it can be used as a lotion, makeup remover, and even as a shaving cream.
It can be used to treat dandruff and as a conditioner.
It can help boost metabolism!
Coconut oil can be used as an underarm odor killer due to lauric acid within it.
It allows our bodies to absorb more calcium and vitamin D.
Coffee & Tea both go great with coconut oil!


Small Acreage Mowing specialises in lawn mowing in Sunshine Coast for over 13 years. Trusted and offers cheaper rates than ride on.
A one-man band that targets hard to reach places and caters custom jobs.


text:
Home / Cricket / Kapil Dev presents 'report card' on Virat Kohli-Ravi Shastri era of Indian cricket, highlights 'big thing lacking'
Kapil Dev presents 'report card' on Virat Kohli-Ravi Shastri era of Indian cricket, highlights 'big thing lacking'
Former India captain Kapil Dev shared a report card, summing up Indian cricket team's performance during the Virat Kohli-Ravi Shastri era.
Kapil Dev has given his assessment of Indian cricket under Virat Kohl and Ravi Shastri's era. (Getty/Screengrab)
Byhindustantimes.com, New Delhi
Former India captain Kapil Dev has shared a report card, summing up the Indian cricket team's performance during the Virat Kohli-Ravi Shastri era. Kohli and Shastri had worked together as captain and coach since 2017 for four years, during which Indian cricket achieved phenomenal success.
However, their stint ended on a disappointing note with India getting knocked out of the T20 World Cup, failing to qualify for the semifinals for the first time in eight ICC events.
Kapil pointed out that although the team has done a superb job, changing the way Indian cricket is looked at, the absence of an ICC title is what will make Shastri and Kohli's tenure incomplete. Weighing in on India's performance at the T20 World Cup, Kapil mentioned how this was the first time since the 2007 50-over World Cup, that India returned with a poor show.
Also Read | 'The earlier it happens, the more it will help us': Deepti Sharma joins chorus for women's IPL
"I think both have done a super job. I understand that they could not win India a major trophy but if we look at the last five years, since Kohli took over, there has been nothing lack. The big thing lacking is an ICC trophy. Apart from that, India have won in Australia, England… wherever they have travelled, they have beaten the other team," Kapil said in an interview with Uncut.
"Reaching the World Cup knockouts is also a huge deal. I think after the 2007 World Cup in West Indies, this T20 World Cup is where it felt that India were disappointing. Had they reached the top 4 and then lost, it is understandable. But if you don't reach the top 4, there will be criticism."
Also Read | 'He came and said to me 'you will be playing this game': Rohit recalls being 'over the moon' on India debut under Dravid
Kapil said that due to the lack of an ICC title, he would deduct 10 percent marks out of 100, but nothing more given the fact that India have played some fabulous cricket, winning the Asia Cup, reaching the final of the inaugural World Test Championship and finishing semi-finalists in the 2019 World Cup.
"If you look at it from a trophy point of view, that's a different thing altogether. But if you look at their cricket, the brand they have played in the last five years, I would give them 90 percent marks out of 100, and deduct 10 percent marks for not winning an ICC Trophy," added Kapil.
t20 world cup india vs new zealand kapil dev virat kohli ravi shastri + 3 more

redpajama_set_name: RedPajamaCommonCrawl


text:
Q: Getting Unavailable dates for renting a product that has stocks Database queries, normally so simple, yet sometimes so difficult. (brain trainer)
So I have products, stocks and rentStockOrders. These products can be rented for a set of days. The stocks also have a date when they are available. If a new product (stock) can be rented depends on the already rented stocks of that product.

*

*A stock item cannot be rented before it's available date.

*A rentStockOrder (linked between order and stocks) contains the bookings, thus rentStartDate and rentEndDate.

*A product can be rented for a set of days, where the start date is not given. The product is selected, and after that a date time picker is used to select a starting day for renting.

*An overall minimum and maximum date is applied (about a year ahead).

The idea is that the user didn't select the start date yet, before the user is able to do that I want to disable certain dates in a datetimepicker that cannot be used as starting date because there are no stocks available for the product's renting period.
To put it in a context: One product is selected, the user is given the option to specify a length in days he wants to rent this product (1 week, 2 weeks or 3 weeks). When the user has selected that, they must select a start date. Instead of every time showing an error that this date is not available, I rather disable start dates before hand.
Since it is more often that a product is available for renting then not, I think it is better to send a list of unavailable select dates to my website instead of a whole list of available dates. So the days that are not available cannot be clicked in a date time picker.
Most examples I have found so far include a input parameter for start and end date which I don't have, all I have a length in days a product wants to be rented and how many stocks are already rented for certain time frames.
EDIT:
As requested, test data and tables:
Stocks
+---------+-----------+-------------------+
| stockId | productId | availableFromDate |
+---------+-----------+-------------------+
|       1 |         1 | 1-01-2016         |
|       2 |         1 | 1-01-2016         |
+---------+-----------+-------------------+

RentStockOrders
+------------------+---------+----------------+----------------+
| rentStockOrderId | stockId | beginRentDate  |  endRentDate   |
+------------------+---------+----------------+----------------+
|                1 |       1 | 15-1-2016      | 14-2-2016      |
|                2 |       2 | 30-1-2016      | 20-2-2016      |
|                3 |       2 | 26-2-2016      | 7-3-2016       |
|                4 |       1 | 29-2-2016      | 14-3-2016      |
+------------------+---------+----------------+----------------+

Based on these records, I want to generate a list of unavailable dates. I've left out some columns for simplicity
Input is a day and a productId.
So if I would input for days: 14 and for productId: 1 I would have some of the following expected results:

*

*25-01-2016 (stockId 1 is already booked, and stock 2 is booked soon, 14 days not possible.

*30-01-2016 (both booked)

*13-02-2016 (stock 1 is not back yet)

*17-02-2016 (stock 2 already booked, stock 1 will be rented in 13 days, not enough for 14).

*..and a lot more where both stocks are already rented.

What I would NOT expect is for example 15-02-2016, because Stock 1 would be available for the next 14 days.
If it is to difficult, then perhaps getting the available dates is simpler and I will switch this around in code. In this example it would be less data to pull from the database, but in reality there are about 250 items of one product so getting the unavailable dates perhaps better.
I've tried this answer to get the available dates, with no success yet, no errors, just returns no data.
declare @startDate datetime, @endDate datetime, @days int
select @startDate = '2016/01/01', @endDate='2016/03/31', @days=2

select stockId, min(endRentDate)
from
    (
    select  stockId ,endRentDate,
            (select top 1 endRentDate
            from RentStockOrders sInner
            where sInner.endRentDate > sOuter.beginRentDate
                    and sInner.stockId = sOuter.stockId
                    and sInner.endRentDate between @startDate and @endDate
            order by sInner.endRentDate) as nextAvailableDate
    from    RentStockOrders sOuter
    where sOuter.beginRentDate between @startDate and @endDate
    ) sub
group by stockId, nextAvailableDate
having dateDiff(d, min(endRentDate), isNull(nextAvailableDate,dateAdd(d,1,@endDate))) >= @days

A: This question is pretty difficult if you want to just use SQL if not impossible. I have made an pretty optimized/performant solution using Oracle PL/SQL and SQL. You can easily translate it to TSQL.
The function returns a set/collection of dates.
I also made another version which returns one big string with space seperated date values like "01-01-2016 02-01-2016 03-01-2016" etc...
You could also make a version which return all seperate dates as date periodstrings for example "01-01-2016/10-01-2016 15-01-2016/25-01-2016" which you can then easily send to- and parse- in your application.
set serveroutput on;

drop table Product cascade constraints;
drop table Stocks cascade constraints;
drop table RentStockOrders cascade constraints;

create table Product (
  productId     number primary key,
  description   varchar2(255)
);

create table Stocks (
  stockId           number primary key,
  productId         number references Product(productId),
  availableFromDate date
);

create table RentStockOrders (
  rentStockOrderId  number primary key,
  stockId           number references Stocks(stockId),
  beginRentDate     date,
  endRentDate       date
);

insert into Product values (1,'product 1');
insert into Product values (2,'product 2');

insert into Stocks values (1,1,to_date('01-01-2016','dd-mm-yyyy'));
insert into Stocks values (2,1,to_date('01-01-2016','dd-mm-yyyy'));
insert into Stocks values (3,2,to_date('01-01-2016','dd-mm-yyyy'));
insert into Stocks values (4,2,to_date('01-01-2016','dd-mm-yyyy'));

insert into RentStockOrders values (1,1,to_date('15-01-2016','dd-mm-yyyy'),to_date('14-02-2016','dd-mm-yyyy'));
insert into RentStockOrders values (2,2,to_date('30-01-2016','dd-mm-yyyy'),to_date('20-02-2016','dd-mm-yyyy'));
insert into RentStockOrders values (3,2,to_date('26-02-2016','dd-mm-yyyy'),to_date('07-03-2016','dd-mm-yyyy'));
insert into RentStockOrders values (4,1,to_date('29-02-2016','dd-mm-yyyy'),to_date('14-03-2016','dd-mm-yyyy'));

--insert into RentStockOrders values (5,3,to_date('15-01-2016','dd-mm-yyyy'),to_date('14-02-2016','dd-mm-yyyy'));
insert into RentStockOrders values (6,4,to_date('20-01-2016','dd-mm-yyyy'),to_date('25-01-2016','dd-mm-yyyy'));
--insert into RentStockOrders values (7,4,to_date('01-01-2016','dd-mm-yyyy'),to_date('01-04-2016','dd-mm-yyyy'));
insert into RentStockOrders values (8,3,to_date('17-01-2016','dd-mm-yyyy'),to_date('25-01-2016','dd-mm-yyyy'));

--stocks with productId X which are rented for coming year from date Y with rentPeriode Z
select *
from RentStockOrders rso, Stocks s
where rso.stockId=s.stockId
and s.productId=1
and rso.beginRentDate>=to_date('01-01-2016','dd-mm-yyyy')-14
and rso.endRentDate<=to_date('01-01-2016','dd-mm-yyyy')+365
order by beginRentDate;

create or replace package my_globals
as
  --type has to be globally declared to be used as a return type
  type t_dates is table of date INDEX BY pls_integer;

  cursor c_searchRentData(p_productid number, p_beginDate date, p_endDate date, p_rentPeriod pls_integer) is
    select beginRentDate,endRentDate
    from RentStockOrders rso, Stocks s
    where rso.stockId=s.stockId
    and s.productId=p_productid
    and rso.beginRentDate>=p_beginDate-p_rentPeriod
    and rso.endRentDate<=p_endDate
    order by beginRentDate;
end;

/

--helper function tot return more future (or larger) date of two dates
create or replace function maxDate (p_date1 date, p_date2 date)
return date
is
begin
  if p_date1>=p_date2 then
    return p_date1;
  else
    return p_date2;
  end if;
end;

/

create or replace function getBlockedDates (p_productid number, p_beginDate date, p_endDate date, p_rentPeriod pls_integer)
return my_globals.t_dates
as
  v_dates     my_globals.t_dates;
  v_begindate date;
  v_enddate   date;
  i           pls_integer;
begin
  i:=1; --collection counts from 1
  v_enddate:=p_beginDate-1;
  for r_date in my_globals.c_searchRentData(p_productid, p_beginDate, p_endDate, p_rentPeriod)
  loop
    if (v_enddate < r_date.beginRentDate) or (v_enddate < r_date.endRentDate)
    then
      --if previous enddate is bigger use that one
      v_begindate:=maxDate(r_date.beginRentDate-p_rentPeriod,v_enddate+1); --first date of blocked period
      v_enddate:=maxDate(r_date.endRentDate,v_enddate+1); --last date of blocked period

      for j in 1..v_enddate-v_begindate+1 loop
        v_dates(i):=v_begindate+j-1;
        i:=i+1;
      end loop;
    end if;
  end loop;
  return v_dates;
end;

/

create or replace function getBlockedDatesAsStr (p_productid number, p_beginDate date, p_endDate date, p_rentPeriod pls_integer)
return varchar2
as
  v_dates     varchar2(4096) := ''; --should be sufficient for one year of blocked dates
  v_begindate date;
  v_enddate   date;
  i           pls_integer;
begin
  i:=1; --collection counts from 1
  v_enddate:=p_beginDate-1;
  for r_date in my_globals.c_searchRentData(p_productid, p_beginDate, p_endDate, p_rentPeriod)
  loop
    if (v_enddate < r_date.beginRentDate) or (v_enddate < r_date.endRentDate)
    then
      --if previous enddate is bigger use that one
      v_begindate:=maxDate(r_date.beginRentDate-p_rentPeriod,v_enddate+1); --first date of blocked period
      v_enddate:=maxDate(r_date.endRentDate,v_enddate+1); --last date of blocked period

      for j in 1..v_enddate-v_begindate+1 loop
        v_dates:=v_dates||' '||to_char(v_begindate+j-1,'dd-mm-yyyy');
        i:=i+1;
      end loop;
    end if;
  end loop;
  return ltrim(v_dates);
end;

/

create or replace function FindAndSplit(haystack in out varchar2, needle in varchar2)
  return varchar2
is
  s2    varchar2(1000);
  idx   pls_integer;
begin
  --dbms_output.put_line('in:'||haystack);
  idx:=instr(haystack,needle);
  if (idx=0) then
    --return full haystack when needle not found
    s2:=haystack;
    --remaining haystack is empty
    haystack:='';
    return s2;
  end if;
  --find string left at idx
  s2:=substr(haystack,1,idx-1);
  --dbms_output.put_line('out:'||s2);
  --remaining haystack is string right at idx
  haystack:=substr(haystack,idx+1,length(haystack)-idx);
  --dbms_output.put_line('return:'||haystack);
  return s2;
end;

/

--testcases
declare
 v_dates   my_globals.t_dates;
 i          pls_integer;
begin
  --store the result of stored function in local collection
  v_dates:=getBlockedDates(1, to_date('01-01-2016','dd-mm-yyyy'), to_date('01-01-2016','dd-mm-yyyy')+365, 1);
  --iterate through collection
  FOR i IN 1 .. v_dates.count LOOP
      dbms_output.put_line('Blocked date: '||v_dates(i));
  end loop;

  dbms_output.put_line('');

  --store the result of stored function in local collection
  v_dates:=getBlockedDates(2, to_date('01-01-2016','dd-mm-yyyy'), to_date('01-01-2016','dd-mm-yyyy')+365, 1);
  --iterate through collection
  FOR i IN 1 .. v_dates.count LOOP
      dbms_output.put_line('Blocked date: '||v_dates(i));
  end loop;
end;

/

declare
 v_dates    varchar2(4096);
 v_date     varchar2(10);
 i          pls_integer;
begin
  --store the result of stored function in local string
  v_dates:=getBlockedDatesAsStr(1, to_date('01-01-2016','dd-mm-yyyy'), to_date('01-01-2016','dd-mm-yyyy')+365, 1);
  dbms_output.put_line(v_dates);
  --iterate through string
  loop
      v_date:=FindAndSplit(v_dates,' ');
      dbms_output.put_line('Blocked date: '||v_date);
      exit when v_dates is null;
  end loop;

  dbms_output.put_line('');

  --store the result of stored function in local string
  v_dates:=getBlockedDatesAsStr(2, to_date('01-01-2016','dd-mm-yyyy'), to_date('01-01-2016','dd-mm-yyyy')+365, 1);
  --iterate through string
  loop
      v_date:=FindAndSplit(v_dates,' ');
      dbms_output.put_line('Blocked date: '||v_date);
      exit when v_dates is null;
  end loop;
end;

redpajama_set_name: RedPajamaStackExchange


text:
Last Updated on Wed, 16 Mar 2016 | Feeding Ecology
According to the ornithologist Oliver Austin, two features shared by Aegithina, Chloropsis, and Irena are also typical of bulbuls (Pycnonotidae): the upper tail coverts are long and fluffy, and a patch of hair-like veinless feathers is present on the nape. All are excellent vocalists.
Varying in length from 6 to 7 in (13-18 cm) and averaging half an ounce (13 g) in weight, the four iora species are quietly patterned in shades of yellow and dull green, with some black in the males. With the exception of the great iora (Aegithina lafresnayei), the wings are dark, with boldly contrasting white bars, in both males and females. They have pale gray eyes and thin, uncurved black beaks. Breeding males are generally dark and more brightly colored than females. Unlike leafbirds or fairy bluebirds, nonbreeding male ioras have a comparatively dull eclipse plumage.
Brilliant green plumage in both sexes is a striking feature of all leafbirds. Excluding the Philippine leafbird (Chloropsis flavipennis), the species are distinguished by contrasting head patterns, often involving black throats, and bright blue "moustaches" (malar stripes). Most females do not have black throats, but maintain either the "moustaches" or a blue throat. Another distinction of the males of most species are shiny malachite-green "epaulets" at the bend of the wing. The build manages to be at once graceful and compact. Tails are of moderate length. The feet are notably small in comparison to body
An Asian fairy bluebird (Irena puella) perches on a branch. (Photo by S. Lipschutz/VIREO. Reproduced by permission.)
size, and the tarsi are short and fairly strong. The beak is slender and slightly down-curved, and the tongue appears to be specialized for nectar feeding. The size range is 7-8 in (17-20 cm), and weights are 1-1.5 oz (25-40 g).
The plumage of the male Irena puella can be described as a meeting of large fields of blue and velvet-black, accented by brilliant red eyes. The female's feathers are largely greenish cobalt, with black primaries and bright blue elongate rump feathers, as well as an equally red eye. Both sexes of I. cyanogaster are patterned in a comparatively indistinct pattern of deep blue and black. The feet of both are remarkably small in proportion to the generally robust, thrush-like body. At roughly 10 in (25 cm), and 2.5 oz (75 g), the fairy bluebirds are by far the largest members of the Irenidae.
The 3 Day Thrush Cure
Black Faced Pitta