Y First Minister on Business has portfolio questions. I call the first question Linda Aviani. I see you now. Maith gaf i'r ddweud yr ysgolau ysgrifennu yng Nghymru. It will next meet the UK Government to discuss matters relating to the constitution. Yesterday, I met with UK Government ministers, along with my counterpart on the Welsh Government, Mark Drakeford and civil servants in the Northern Ireland Executive in the Joint Ministerial Committee on EU Negotiations. The meeting focused on UK frameworks, the EU withdrawal bill, migration and the involvement of the devolved administrations in stage 2 of the EU negotiations. I made clear that the constitutional future of Scotland and this Parliament is very much at stake in the process of EU withdrawal unless there are amendments to the withdrawal bill. I stressed that all the powers of this Parliament affected by withdrawal must stay devolved after Brexit. I also made clear that if it is possible to create a special arrangement between Northern Ireland and the European Union, recognising the special difficulties and status of Northern Ireland, there is no logical reason why Scotland should not have the same rights, and indeed it would be unacceptable for Scotland to be placed at any economic disadvantage. Will the minister next time he meets with his UK counterparts following on from the discussions in yesterday's debate express the shock of many in Scotland to find out that under the EU withdrawal bill they are refusing to safeguard Scotland's devolution settlement, but instead legislated for the right to amend the Scotland Act 1998, along with Tory Scottish MPs who consistently refused to safeguard Scotland's interests? It was disappointing last week to see those Tory Scottish MPs refusing to support the Scottish Government and Welsh Government amendments carefully thought through amendments with regard to Clause 11. Last night, to see a repeat of that situation in which amendment 158 was voted down, an amendment that would have made sure that UK ministers could not, by secondary legislation or by action, simply by a stroke of a pen, alter legislation passed through this Parliament. It is disappointing to see that. We have made it absolutely clear that we will not bring forward a legislative consent motion unless there are similar or equivalent amendments to the bill. That is the number of the matter, and there can be no legislative consent motion without those significant and lasting changes to the bill. The Herald today reports on its front page that, at yesterday's JMC, there was, in fact, substantial agreement between the two Governments on the repatriation of powers from the European Union to this Parliament following Brexit. Yet, according to the Herald, rather than share this good news with the Scottish Parliament and, indeed, with the Scottish people, the SNP would rather keep it under wraps. Why? Does that not just serve to underscore yet again that the SNP would rather contrive grievance than get on with the job of delivering Brexit for Scotland? If Mr Tomkins had read the whole piece, he would have seen a significant statement from the Scottish Government, which said that this is not true. The exclusive tag on the story is an exclusive untrue story. What is more concerning about the story is that it may indicate that the Secretary of State of Scotland does not understand the process in which he is engaged, which is very concerning, indeed. The process in which we are engaged is to look at a list of 111 intersections between the European competence and devolved Scottish competence, and to make sure that those matters come to this Parliament. Then, of course—and we have made it absolutely clear—we can sit down and talk about those matters that should be subject to joint frameworks, co-decision making. It is not unless this is a new declaration of intent from the UK Government, it is not about re-reserving powers that should be in this Parliament. If Mr Mundell's briefing to the Herald is to be taken at face value, he believes that the actions that we are engaged in is about re-reserving powers and allowing the rest to come back here. That is at the nub of the matter. If the Secretary of State for Scotland does not understand the discussion that we had yesterday afternoon, it bodes ill to get a settlement. Fortunately, there are others around the table in the UK Government who understand it and are working to try to achieve that. I hope that that work will pay off, but I have to say that it is not helped by the Secretary of State for Scotland, who seems to think that his job is to brief the Herald rather than get a resolution. To ask the Scottish Government how it will compensate for decreasing levels of landfill tax revenues as the amount of waste to landfill decreases. Cabinet Secretary Derek Mackay As an environmental tax designed to divert material from landfill, encourage alternative waste treatment options and keep valuable resources circulating in their economy for longer, I would see declining landfill tax revenues a positive trend. It is also worth noting that the adjustment to the Scottish Government's block grants relating to landfill tax is also forecast to fall, which means that overall falling revenues do not necessarily lead to less spending power. Will Scottish rates for landfill tax continue to mirror UK rates, or will they diverge? As we were discussing over dinner last night, Mr Bowman—I do not know whose reputation that does more damage to your or mine—a very complex nature of the block grant adjustment, I hope that, across the UK and in Scotland, landfill tax revenues go down, because that will be an indicator that we are making progress in our environmental ambitions, and that will be good for the environment as well as for the economy. To ask the Scottish Government how it will ensure that sufficient funding is provided to local authorities to help them to meet the needs of their residents. The 2018-19 budget will continue to treat local government fairly, despite the cuts to the Scottish budget from the UK Government. It is then the responsibility of individual local authorities to manage their own budgets and to allocate the total financial resources that are available to them on the basis of local needs and priorities. East Remshire Council, in my region, is proposing in its coming budget to cut all classroom assistants in their primary and secondary schools and significantly reduce the number of behavioural support assistants. I accept that, if I ask the cabinet secretary what will be in tomorrow's budget, that he will ask me to wait till tomorrow, but does he accept that, without a significant change in policy from the Scottish Government, cuts such as that become impossible to avoid for councils? I have just glanced at the figures for East Dunbartonshire last year, or this East Remshire. I have looked to that as well, that is how I am a multi-talented am. I looked at East Dunbartonshire, thinking that Ross Greer would have an interest in that. Its increase was over 4 per cent, and East Remshire's was over 5 per cent. In every regard, both councils have done very well from our settlement to local government. Incidentally, both councils increased their council tax using their powers also. Touching on education is a really important point. I think that the pupil equity funding and the wider attainment funding has supported young people and pupils across the country, resulting in more teachers being employed, as well as addressing that crucial attainment gap. I can reassure Ross Greer that the local government settlement that I will propose will be fair and reasonable. He answered his own question. Full details will be released tomorrow. Can the cabinet secretary confirm that allocation of funding to councils will continue to be based on need, and there will not be an evening out process that might disadvantage the islands and Glasgow and those with greater needs? There is a very sophisticated needs-based formula for the local government settlement, which is arrived at in dialogue with the local government with COSLA. That said, there is also the floor and another technical arrangement that allows for stability and a degree of convergence around funding. Fundamentally, the answer is yes. The funding settlement for local government continues to be needs-based. Audit Scotland's recent report confirmed that local government funding from the Scottish Government had fallen in real terms by 7.6 per cent since 1011, demonstrating that the Scottish Government has enforced disproportionate cuts to local government. Can the cabinet secretary confirm that, since next year's block grant will again increase in real terms, there is no further justification for cuts to local government by the SNP Government? I do not know what is going on in the parallel universe that Alexander Stewart's mind with the rest of the Tories and their briefing notes. The reality is that the resource funding for day-to-day spending for the Scottish Government is going down by £200 million next year, £0.5 billion over two years. Do not just take my word for it. The Fraser of Allander institute says so. In terms of the previous period, it is also the case that our budget has gone down. It has gone down by £2.6 billion—that is 8 per cent in real terms. Over that period, we have protected local government as best we can. South of the border, where the Conservatives have been in control, the real terms reductions to local authorities in England has been over 20 per cent, showing that we have treated local government in Scotland fairly indeed. To ask the Scottish Government how it will ensure fair and adequate funding for all of Scotland's local authorities. The 2018-19 draft budget will continue to treat local government fairly despite the cuts to the Scottish budget from the UK Government. Local government allocations are distributed using a needs-based formula that has kept under constant review and agreed with COSLA. Lewis Macdonald I thank the cabinet secretary. He will recognise that that funding formula that he referred to previously has tended to disadvantage certain councils, including, for example, the city of Aberdeen and that provision has been made in the previous Parliament through the floor funding that he referred to in reply to Mr Mason, through that floor funding to reduce that disadvantage. Is he able to confirm today that that funding floor is set to continue? Will he now achieve the target of 85 per cent of the Scottish average, which was set for it some years ago? Lewis Macdonald is right to say that there is the needs-based formula, there is the ability for councils to raise council tax, then on top of that for Aberdeen, there has been an 85 per cent floor. Incidentally, the Labour Party never gave to Aberdeen or the north-east when they were in power, but it has been established by the SNP Government, and I am sure that Lewis Macdonald, as will many other members of the chamber, will welcome the local government settlement when they see it tomorrow. Murdo Fraser Thank you, Deputy Presiding Officer. Given that the Scottish Parliament information centre has confirmed that the Scottish Government's budget is going up in real terms from this year to next, given that yesterday, when it published its economic commentary, Fraser of Allander said notwithstanding the cabinet secretary's comments that the Scottish Government's budget is going up in real terms over the next three years. The total budget is going up over the next three years. Would the cabinet secretary agree that there is no case to make any further real terms cuts to local government spending? The Cabinet Secretary for Rural Affairs and the Constitution Can I just remind members, Mr Fraser, that I do not like props? Appropriately rebuked, I would say, Presiding Officer. The prop that Murdo Fraser has chosen to use is one such prop. I do not know why they want to ignore and dismiss the advice of the Fraser of Allander Institute. Are you suggesting that the Fraser of Allander Institute, in terms of what they have said about discretionary spend, so that is the resource for day-to-day public services? That is what funds schools and hospitals and police and fire and front-line local government services. I know that Murdo Fraser is far more intelligent than he is pretending to be in this chamber this afternoon. Murdo Fraser, like the rest of the Conservatives, knows only too well that you have cut that discretionary funding to Scotland. That is the reality, but the Tory briefing knows that it does not say so. Just like Pavlov's dogs, they follow the merry tune that we have extra resources when, in fact, our resources for front-line discretionary spend has gone down by £200 million next year and £1.5 billion over two years. Can I remind members that this will be debated this afternoon, so we do not have to reprise it all now? I have question 5 from Jeremy Balfour. Thank you, Deputy Presiding Officer. To ask the Scottish Government, in light of the UK Government's decision to do so, whether it will win forward the linking of non-domestic rates to CPI from April 2018 to 2020. That is a good question, and I will give you the answer tomorrow in the draft budget. Jeremy Balfour. Can I thank the cabinet secretary for his very full answer? I would agree that linking pounds to CPI would result in rates being more than a penny lower in just three years' time, saving the average stock hundreds of pounds in tax, and an age of increasing competition from online retailers. Does my cabinet secretary agree with me that we need to do all that we can to help us to struggle in stocks on the high street? I certainly agree with the sentiment of the question. A number of businesses have made the switch from RPI to CPI as the main ask of the budget tomorrow. The Barclay review also said that there is an argument to move from RPI to CPI, but in Barclay's view, it was at this stage unaffordable. I have been reflecting on that in many other matters, and I say again to the member that I will present my proposals to Parliament tomorrow. Willie Coffey. Can I ask you what proportion of rateable properties do not pay rates as a result of the small business bonus? Can you confirm that those businesses that qualify for that scheme will continue to benefit from it next year? As it stands today, about half of all properties in Scotland pay no rates whatsoever. 40 per cent of all properties are a consequence of the small business bonus, and I have said that the small business bonus will continue. Neil Findlay. My understanding is that we are supposed to be in an era of evidence-led policy. Can I ask the cabinet secretary for finance when he will have a proper independent analysis of the small business bonus? I believe that the small business bonus has been a lifeline, particularly to our town centres across Scotland in ensuring that smaller businesses have that relief in what has been quite turbulent times. Indeed, when I launched the last budget in terms of non-domestic rates, the property that I visited in Paisley was using the relief that they were now entitled to employ another young person. Surely Neil Findlay would welcome that kind of initiative, delivered through the small business bonus. To ask the Scottish Government what representations it received from local authorities regarding the draft budget. Cabinet secretary. Ahead of my 2018-19 draft budget announcement, I have met a number of individual council leaders and had a series of meetings with COSLA. Many local authorities in my region are facing severe financial pressures and unique rural and logistic demands. My local council Highland has a responsibility for 6,752 km o rhod, 17,000 footpaths and 1,400 bridges, and that is not counting the new home mill's bridge that opened on Monday. Will the cabinet secretary look again at the Scottish Government's funding formula and give more leeway to rural local authorities, which cover great swathes of Scotland such as Highland? I would only consider a change to the formula if COSLA, i.e. local government, wanted me to. Will that not be welcomed by members in the chamber who believe in partnership and engagement with local authorities? They determine the funding formula, there is partnership working on it and I do not propose to change that. Of course, if I did more for rural areas, urban councils would say that there is an argument around deprivation and every council, all 32 out of 32 council leaders, could present a case on how the formula could be changed to suit them. That is why we do it collectively in partnership. I propose to maintain that structure and, incidentally, Highland Council, as an example, of course, if you look at the totality of resources to support local services, also enjoyed a real-terms increase in the current financial year. Question 7, Kenneth Gibson. Thank you, Presiding Officer. To ask the Scottish Government by how much PFI, PPP payments will increase in 2018-19. Given such payments, an index-link bonds include charges that increase with inflation. Cabinet Secretary. The total estimated PFI urinary charge payments for 2018-19 will increase by almost £19 million, taking the total figure for that year to over £1 billion. Kenneth Gibson. I thank the cabinet secretary for that answer. Does he agree that inflation again exacerbates the year-on-year increases in charges, showing the folly of Labour, Lib Dem and Tory support for PFI? Cabinet secretary. Yes, it certainly is a burden that we have to live with, pay for and that is why our financial models have been much better for the public person for quality public services. Jackie Baillie. Presiding Officer, unitary charge payments applied to PFI, PPP and, of course, to NPT projects brought forward by the SNP Government. Last week, the Public Audit and Committee took evidence from the Scottish Government and the Scottish Futures Trust about changes to the classification of capital projects as a result of ESA 10. We now know that the Scottish Government has to borrow almost £1 billion to cover those projects, which are now on balance sheet. Does the cabinet secretary share my concern that this is an opportunity that lost and other capital projects have been delayed as a consequence? Cabinet secretary. Absolutely not true, and I look forward to setting out a very exciting, bold and ambitious and transformative capital investment programme tomorrow. I will take a very short one from Ivan McKee, question 8. To ask the Scottish Government what it is doing to ensure that departmental spend is delivering the most effective outcomes in terms of the national performance framework indicators. Cabinet secretary. Thank you, Presiding Officer. The national performance framework sets out the Government's priorities. The programme for government sets out the actions that the Scottish Government will take over the next year to progress those priorities, and the draft budget sets out the funding arrangements. The Scotland perform website is the reporting tool for the NPF. It provides a continually updated, impartial and transparent stocktake across a diverse range of economic, social and environmental indicators. In addition, to support the parliamentary committees in scrutinising the draft budget, we provide performance information to demonstrate the interrelationship between the Government's priorities and spending plans. I have my key briefly, please. The minister will be aware that the NPF is internationally acknowledged by a world-leading process for measuring success in public service delivery. Does the minister agree with me that content to ensure that the link between public sector spend and delivery of measurable performance is both the right approach and in accord with the principles that are determined by the Christy commission? Minister. Yes, I do. That is brevity for you. Now I move on to questions on economy, jobs and fair work. I call number one. It has not been lost for reasons explained. Number two, Fulton MacGregor, please. Thank you, Presiding Officer. To ask the Scottish Government how it supports local authorities in attracting businesses and jobs to town centres. Minister. The Scottish Government is committed to revitalising our town centres by stimulating inclusive economic growth and supporting opportunities to attract investment. We are working with local authorities to deliver plans that attract a range of businesses and services to town centres. That is supported by a number of initiatives, including the town centre action plan, which is helping to stimulate a wide range of activity in our town centres. The town centre action plan, two years on report, was published in February of 2016. The town centre first principle recognises that town centre locations are not always a suitable location, but it asks that the rationale for locating projects or investments elsewhere is evidenced and transparent. Scotland's town partnership, which has been funded to facilitate activity and share and promote learning from activity happening at a local level. In addition, Scotland's business rates package is the most attractive in the UK, with total rates relief of around £660 million in the current financial year, and more than 100,000 premises benefiting from a small business bonus scheme, including more than 4,000 in North Lanarkshire. Fulton MacGregor. I thank the minister for that response. Just last week, I held the second in my series of town centre regeneration meetings for Coatbridge town centre. There is a lot of goodwill towards the town centre and a strong desire for it to thrive again, but no single stakeholder seems to have the levers or strategy to make all the necessary changes. Can the Government advise what measures are in place to help communities, including local authorities, elected representatives, parliamentarians, local businesses, community groups, private owners and other stakeholders, to form strategy groups interested in working together to improve town centres? Can I remind everyone that it is useful to have short questions and sort of succinct answers, if I may? Yes, minister. Thank you, Presiding Officer. In response to Fulton MacGregor, clearly I know that the Parliament has a cross-party group that focuses on those issues, but aside from that one way in which parliamentarians can engage in the agenda, I refer to it briefly in my original answer. Scotland's town partnership is an excellent source of advice and information for newly established strategy groups to identify the next steps for town centre improvements, and we have established STP as the go-to body for all town centre activity in Scotland, as we recognise the need for dedicated support for town centres. The town centre toolkit that is hosted on the STP's website gives communities information and advice on how they can make their own town centres more attractive, active and accessible. Strategy groups may also wish to use the understanding Scottish Places or USP data tool, which is an online platform, again designed to help users to better understand the function of towns in the modern era and to provide the opportunity to compare and contrast towns across Scotland to learn from good practice. I do not know what succinct means any more. I call Dean Lockhart, please. I will try my best, Deputy Presiding Officer. I note the series of measures explained by the minister. Can he explain why does Scotland have the highest number of empty shops in the UK? Could it be business rates? Could it be the large business supplement? We refer to the fact that we have a competitive business rates package in Scotland, and we are taking every effort, as has been demonstrated by the Cabinet Secretary for Finance, to listen to representations that have been made to the Barclay review, to tailor the rates package that we have. Obviously, the budget tomorrow will set out more detail of the Government's plans to support businesses at a local level. However, we have a wide range of tools in our locker to be able to help small businesses. We encourage businesses through support for the enterprise and skills review to engage with enterprise agencies and to gain support. However, clearly, there is a range of measures in which the Scottish Government attempts to help small businesses and our town centres. The advice that I have given to Mr MacGregor and the points that we set out in the budget tomorrow is a complete package of support to help small business community. To ask the Scottish Government what discussions it has had with the UK Government regarding European structural funds and regional policy after Brexit. I met David Mundell, Secretary of State, for Scotland on 7 December, and asked him to confirm the UK Government's position on whether it was committed to supporting deals across Scotland and for engagement on the industrial strategy. I had a discussion with Greg Clark, Secretary of State for Business, Energy and Industrial Strategy on 16 November, and I also discussed the industrial strategy that laid to the Scottish Business Growth Group meeting on 15 November with Ian Duncan. As for the European structural funding, I met the economy's economic secretary to the Treasury Stephen Barthley on 6 October, when I stressed how vital it is that sustainable replacement for the funding is put in place. I will continue to press the UK Government to engage with us so that we can deliver the best outcome for Scotland. Whatever form these arrangements take, the UK Government must provide Scotland with no less than the current level of funding that we receive and the autonomy over that funding to align it to Scottish priorities. I commend the cabinet secretary on his workload. I wonder if he would agree with the Industrial Communities Alliance that older industrial Britain, which does not just include Scotland but the north of England and the midlands and elsewhere, has benefited greatly from the structural funds and would have a real problem if the UK did not continue them? I agree with that. There has been £395 million of European structural funding already committed, matched by more than £500 million from Scottish partners, giving a total investment of £900 million. As John Mason says, that is crucial to those communities that he has talked about. I join many of those who are benefiting from the support on 29 November in Edinburgh to celebrate and promote the progress of projects to date. I heard about, for example, Zero Waste Scotland using £30 million in grant to support the resource-efficient circular economy accelerator to programme, supporting over 2,000 SMEs and the community sector. It includes projects such as the one at Sustainable Papaw Estuary, an ordinate to restore the community centre, and the little bakery in Dumfries to replace an inefficient bakery oven. Details of the second phase of funding will be announced in the new year. To ask the Scottish Government how it encourages employers to pay at least the living wage to those under 25.  In Scotland we have now proportionately more than five times as many accredited living wage employers in the rest of the UK, which is testament to this Government's commitment to making Scotland a living wage nation. We are supporting the poverty allowance by increasing funding for the Scottish living wage accreditation initiative to £336,000 this year, and we are working with them and their leadership group to support their efforts to target low-pay sectors. I thank the minister for that answer. Could he also outline what discussions the Scottish Government has had with the UK Government in relation to including those under the age of 25 in the national living wage, given that they continue to be discriminated against by that Government? Could he also outline what actions the Scottish Government is taking forward to support young people into positive destinations, especially in light of the year of young people next year? On the three issues that Mary Gougeon has identified, the Scottish Government has ensured that the Scottish welfare fund can be used to help young people affected by changes to housing benefit entitlement, which we have opposed. In relation to the national living wage, I think that the first thing to emphasise is a contract. It is not the living wage set out by the living wage commission. Nonetheless, it is a statutory process. The Government has, in its responses to the low-pay commission, set out proposals to decrease the differential between the youth and apprentice rates and the adult rates, but we want to see the real living wage to the norm across the board. That is why we set that out as our proposal to make it a statutory proposition in our general election manifesto. That is why we continue to promote it. Ross Greer Does the Scottish Government require companies to pay the living wage to all workers, regardless of age, if they wish to receive funding from the Scottish enterprise agencies? If not, why not? We are working actively with our enterprise agencies to make sure that they are playing their part in the promotion of the real living wage. It is an effort that we take very seriously. Indeed, it is one that we are leading from the front as an administration, and it is paying dividends. That is why Scotland has the highest proportion of its working-age population of any of the UK nations paid living wage or more. Mark Griffin To ask the Scottish Government what plans it has to create targets with specific deadlines to reduce the disability employment gap. minister In a fairer Scotland for disabled people, published in December 2016, the Scottish Government set a target to at least half the disability employment gap. We are working with stakeholders to develop a timetable, along with further actions to be taken to achieve our ambitions for disability employment. We will set out more detail at the major congress on disability employment in the workplace that it plans for early next year. Mark Griffin I thank the minister for that answer. Looking ahead to the new devolved services, I can ask what on-going engagement he has had with the third sector since the decision was made to award just 20 per cent of the contracts to bids led by the public and third sector. Is the minister assured that the supply chain providers can afford to deliver such a high-quality service when the private sector has such a substantial role? Of course, it is the case that our new employment programme, Fair Start Scotland, which will begin in April 2018, is delivered by a range of partners. Contrary to the impression that Mark Griffin has just given to the chamber, when we look at the global value of the contracts awarded, the nine contracts awarded to some 95 per cent of the value of those contracts involved, the third sector either as the main contract holder or as a delivery agent of a main contract holder. The third sector has a significant role to play here. I am confident of that. I am confident that our programme will be a success. Of course, I continue to engage with the third sector and all those who have an interest in ensuring that people get the chance to get employment in Scotland. The minister mentioned the new transitional employability services of the Scottish Government. Work for Scotland and Workables Scotland in their first six months have helped more than 3,500 disabled people into work. Does the minister agree with me that that is both effective in dealing with disabled people in a dignified way? Of course, our ambition has been, through our transitional arrangements and our longer-term approach, to ensure that all people who utilise our employment programmes are treated with dignity and respect, irrespective of whether they have a disability or not. Of course, we set out an ambition of supporting up to 4,800 people into work through our transitional programme this year. As Clare Adamson has just correctly pointed out, we are halfway through that initiative. Already, we have had some 3,500 people supported by that effort. To ask the Scottish Government what action it is taking to increase workforce productivity. Cabinet secretary. Scotland's labour productivity growth has outstripped the UK's in recent years. GDP per hour's work has increased by 6.6 per cent in Scotland since 2007 compared to 0.8 per cent for the UK as a whole. The Scottish Government recognises that improving the productivity of a workforce is a central driver of inclusive economic growth, and that is why we are taking forward a range of programmes such as investment in skills, developing a young workforce, addressing inequalities in a workforce and the fair work agenda. Through the enterprise and skills review, we have also established a clear forward looking agenda to improve the system of enterprise and skills support in Scotland and make a substantial and valuable contribution in increasing our productivity and broader economic performance. I hope that those actions and the progress thus far will be welcomed by the member. Brian Whittle. I thank the cabinet secretary for that answer. He will be aware that the impact of poor physical and mental health has on productivity and therefore strategies, such as the mental health strategy, obesity and diet strategy, can have huge implications on the nation's productivity. With that in mind, what input does the cabinet secretary's team have across other portfolios? We have the regular contributions at cabinet level among cabinet colleagues and also between ministerial colleagues. I would say that the mental health strategy is much more in the portfolio of my colleague Maureen Watt. I am happy to furnish a member with answers to it, but he can be assured that there is regular collaboration between cabinet ministers and ministers across portfolios. Thank you, Deputy Presiding Officer. On declaring an interest as a farmer to ask the Scottish Government what discussions it has had with the UK Government regarding establishing schemes that aim to attract more seasonal, skilled labour across all sectors to Scotland, such as the former seasonal agricultural workers scheme. The UK Government's position on migration post-Brexit is likely to have a major impact on the availability of labour, not just on seasonal, skilled workers but across the board for high and low-skilled jobs. That is one of the reasons why the Scottish Government is lobbying the UK Government hard to maintain membership for the single market with its associated free movement of citizens. Scotland values the contribution of temporary workers in the migrant community to make to our economy and we are determined to do what we can to continue with the current arrangements. John Scott I thank the minister for his answer. The minister is aware that there is an emerging difficulty in attracting skilled labour to work in our food processing, tourism and agricultural sectors, as well as other sectors. How does he intend to address that? It is now clearly defined and growing problem, currently driven by the fall in value of the pound against the euro, which threatens to undermine the future success of our tourism and our food and drink sector. The minister I have to say that I am rather surprised that this question comes from the Conservative benches, given that the great pressure has been caused as a result of their shambolic handling of the Brexit process. As I have set out in my initial answer, we continue to lobby the UK Government hard to ensure that we can continue to access the skilled labour that we will require for economy from elsewhere in Europe. Of course, we cannot just rely on that. We certainly cannot rely on the UK Government in that regard. That is a matter that I take very seriously. I note one that also Fergus Ewing, the current Secretary for Rural Economy, considers very seriously through engagement between sectors, skills councils and Skills Development Scotland. If there is more that can be done to ensure that we have the skilled workforce that we need for those sectors, we will work towards that in that regard. I am seeing some examples of that already. I was up in Argyllun Bute recently, where I saw the local college engaging actively with the agricultural community to make sure that skilled supply of workforce can come through in the future. I apologise for my slight later arrival for the question time, but I ask the Scottish Government what immediate action it is taking to support the economies of Orkney and Shetland. This Government is committed to promoting economic growth across all of our communities, including those in Orkney and Shetland. Our substantial investment in infrastructure, regeneration and business support helps to deliver inclusive growth and economic resilience, creating and retaining jobs in communities across the Northern Isles. For example, the 2016 SNP manifesto contained a commitment to take action to reduce fares on ferry services to Orkney and Shetland, and the Government is delivering on that commitment. That is our priority. On 22 August, the Minister for Transport and the Islands announced her intention to introduce reduced passenger and car ferry fares on services in the mainland to Orkney and Shetland in the first half of 2018. The fares options identified, in line with the Clyde and Hebrides ferry network, are road equivalent tariff on the Pentland Firth routes and a variant of RET on the longer Aberdeen to Kirkwall Lerwick routes. The average reduction in fares across the Northern Isles will be more than 30 per cent for cars and 40 per cent for passengers. Liam McArthur I thank the cabinet secretary for his answer and certainly acknowledge and welcome the decision, albeit related to cheaper ferry fares on the external routes. However, as a former transport minister, he will be aware that crucial to the local economies of Orkney and Shetland are our internal ferries, a lifeline to the smaller islands in both constituencies. So when will the Scottish Government honour the commitment that it made in 2014 to provide fair funding for those lifeline services? Cabinet Secretary for Transport and the Islands We have, as the member mentioned, made that commitment. In fact, it was made as long ago as when I was a transport minister directly to the councils involved. Of course, that is being followed through by the transport minister in a matter of discussion between the transport minister and the finance cabinet secretary in relation to the discussions that they have had with the relevant local authorities. I think that it is right that those discussions are allowed to take place. Of course, the particular needs of the islands in terms of their internal ferry services are matters that have been quite rightly the preserve of those islands' authorities. The extent to which we would like to see further support in the Scottish Government is rightly a discussion between those parties involved. It may be that it depends on how the budget discussions go and that further progress can be made in relation to that, but that would be for the Cabinet Secretary for Finance to talk about in his budget proposals and, of course, for the opposition parties to play a part in that to make their own suggestions and see where they can support the Scottish Government's budget. Given that the Cabinet Secretary for Finance's protestations during and since last week's debate on ferry funding for Orkney and Shetland's internal ferries, can the cabinet secretary confirm that it is still normal protocol for the Scottish Government to put Scottish Government commitments into the Scottish Government's own budget rather than relying on opposition parties to do so on their behalf? I think that another member was not here at the start of this parliamentary session, but this is a minority Government. This is a Parliament of minorities. In that context, just as at Westminster, people have to have discussions and sometimes even make compromises. That is why it is important that the opposition parties play their full part in the budget process. I think that the implication of the question from the member is that that party wants to play no part in the budget process of this Parliament. That is their entitlement, but I think that they will lose out, as will their local electors, for not taking part in the process. Question 9, Colin Beattie. To ask the Scottish Government what progress it is making in improving productivity across the country. Scotland's labour productivity has, as I mentioned previously, outstripped the UK's in recent years. The most recent data shows that GDP per hour worked has increased by 6.6 per cent in Scotland since 2007 compared to 0.8 per cent for the UK. We have also improved our ranking against other OECD countries in that time. We believe that all areas of Scotland will make a vital contribution to improving our productivity. That is why we are working with partners across Scotland to improve our performance. For instance, we are making substantial investments in improving transport connectivity across the country. We have committed up to £1.08 billion over the next 10 to 20 years for city deals in Glasgow, Aberdeen, Inverness and Edinburgh, the biggest funder of city deals in Scotland. We are working with other city regions to develop proposals and have committed to establishing new regional economic partnerships representing every community in Scotland. I thank the cabinet secretary for his response. Will the cabinet secretary agree that, without such an improvement in productivity, income levels in Scotland may well not develop to the extent that we would like to see? I think that that is true. I think that improving our productivity is central to delivering sustainable and inclusive economic growth and to increasing wages and incomes across Scotland. That is why we are taking the actions that we meant. There are vital components of increased productivity relating to innovation, to management capacity and to the skills of our workforce and to the investment that the Government makes when we are trying to take action forward on all those fronts to increase productivity.


Hello, my name is Professor Vanille Urando at the University of Dayton School of Law. I'm Professor Emeritus there and I'm going to do a mini lecture on whether or not the out-of-school suspensions of Dayton of black children are lawful. I have been working on this issue of the school-to-prison pipeline by focusing on one of the early points in the pipeline that is the suspension of children from school, the out-of-school suspension of children from school. I mostly place my focus on working to educate the community and also on working to get the moratorium both at the state and federal level on zero tolerance policy and on out-of-school suspensions. However, recently I was asked by the NAACP legal affairs committee to give a small lecture for their group and to focus on the legal aspect and being a lawyer, I readily agreed. And so this lecture is a focus on whether or not the suspensions are legal, in my opinion. As a lawyer, you have to start the discussion of whether something is legal or not, always discuss with what law are you talking about. Are you talking about the State Civil Rights Act? Are you talking about Title VI of the Civil Rights Act of 1964? You have to be specific about the law that you're using because in order to determine whether or not something is legal, you have to know what the elements are that must be proven or disproven. In this case, I'm going to use the Title VI of the Civil Rights Act of 1964. That act made discrimination based on race by any organization that received federal funds illegal. In generally, the law makes intentional acts illegal by interpretation. The law itself doesn't limit itself to intentional acts, but the court has limited to intentional lack. By regulation, the courts have, excuse me, the law has been included to cover what's called disparate impact. Disparate impact are those things that are not intentionally done, but have a racially discriminatory effect. One of the problems with this law is that this aspect of the law is that courts have held that individuals cannot sue for disparate impact. All they can do is file a complaint with an agency. However, the federal government has indicated through their guidance that they put out that they would entertain complaints to them about disparate impact or indiscipline. So there's a window of opportunity right now. The window of opportunity is we have a federal agency who is interested in the discriminatory impact of disciplinary policies. So the elements, sort of like I would teach this class, they're basically four elements and elements can be broken up and you could say three in terms of how you break them up. So is there a method of discipline that is racially neutral on its face? Does that method of discipline in terms of its implementation have a discriminatory effect? If so, you at that point, it may be found unlawful if there is not a sufficient justification for doing it. One justification would be that it's educationally necessary. Even if that it's shown to be educational necessary, it can still be unlawful if they're equally effective and less discriminatory alternatives available. Now this most of this lecture is based on a wonderful article done by Daniel Lawson, Discipline Policies, Successful Schools, Racial Justice and the Law. The article is on my website racism.org. I highly encourage you to go to that article and read it. So the first step, is there a discriminatory effect? The racial neutral policy that we are looking at is out of school suspensions. If you look at code of conducts, if you look at what is written on their face, they're racially neutral. I am going to use Dayton, Ohio statistics because I am heavily involved in a Dayton, Ohio campaign to get things changed. But it should be known that Dayton statistics are not the worst. And that's a good thing to because if they're not the worst, think about you can think about how bad is it getting. Dayton is probably in the middle of the pack of urban schools in Ohio. It's probably in the middle of the pack for charter schools. There are both public schools and charter schools that have worse statistics. But nevertheless, Dayton provides us a good opportunity to take a look at this. So the thing right now, we're just looking, is there a discriminatory effect? That is intentionally or not black kids being treated differently than other kids in the implementation of this suspension, out of school suspensions. Now these numbers are rate per 100 kids. This rate allows you to compare different population sizes. So for instance, 65% of Dayton's population is black. So if you just compared occurrences, you would expect more occurrences in Dayton. However, what a rate does is translate makes a unit number that can be compared. And so no matter what the size of population, if there's not something else going on, you would be expecting about the same rate per 100 in different population size. And you don't see that with Dayton. Black students have a rate of 60.6 per 100. And Asian students, which have the lowest is have 8.3. That is black students are 7.3 times, has 7.3 times more suspensions per 100. Now this is not the percent of students that get suspended. I don't have that number because it's not available on the on the data that I use. We use 2012-2013 discipline reports, Ohio Advanced Report Data, and they don't release the percent of students. And the percent of students would tell you the actual risk that a particular student has to get to getting suspended because it tells you the number of students that get at least one suspension. Nevertheless, the number of suspensions per 100 students tells us that there is a racial disparity here. We see that black boys are 5.1 times more suspensions per 100 students. And surprisingly, while the number of suspensions per 100 students are lower than black boys, you see here 43 per 100 students for black girls, 77.2 per 100 students for black boys. The rate, the black girls are 43 times more, excuse me, have 43 times more suspensions per 100 students. And so they are actually at a greater risk. They have greater suspensions as compared to their gender group.  So now I know what someone's going to say because I hear it in their head. Well, isn't that about economics? Isn't it that they're more poor blacks and poor blacks come from an environment that makes them higher at risk behavior wise? And so consequently, that would explain. Lucky for us, the Ohio actually collects economic disadvantage data, and we can compare that. And what we see is, yes, blacks who are economic disadvantage have a higher out of school suspension rate than anyone else. Anyone else. And so does multiracial children. But here's the surprise. Blacks who are not economically disadvantaged, hear what I'm saying? Blacks and multiracial kids who are not economically disadvantaged have a higher rate of suspension than everyone but the blacks who are economically disadvantaged. They have a higher rate of suspension than whites who are economic disadvantaged, and they have a higher rate of suspension, a much higher rate of suspension, doing whites who are not economically disadvantaged. In fact, blacks who are not economically disadvantaged have twice as many out of school suspensions than whites who are not economically disadvantaged. And they have a significantly difference than whites who are economically disadvantaged. So while economics makes a difference, race also makes a difference. And so the racial disparity continues to exist even in the face of economic disadvantage. Another issue that I think you should take a look at is what's happening to disabled kids. Because that's another area of law that we're not going to look at. There's all kinds of disability law that controls what can happen with disabled kids. And what we see is black disabled kids are at a greater risk. Black disabled kindergartners are 39.1 times more, excuse me, have 30 times point one times more suspensions. And it goes on. So one question you need to ask yourself if you're talking about wanting to look at the law is, is your school's system adequately protecting the rights of disabled black children? But we're not going to look at disability law now. So what we've essentially established that there's a discriminatory effect that happens in terms of how a date in public school is implementing its out of school suspension policy. And I suspect that you'll find that in almost every school, the data supports that. One of the things it's in, I have found it's important to get into the specific data and not use national data. Now, Ohio is one of the places that provides a lot of data on its website, Ohio Education Department of Education. Some districts don't provide that information. So this disparate disciplinary action, this discrimination, discriminatory effects could be unlawful if they are not, if they are not educational and necessary, a sufficient justification. What would be the sufficient justification that is educational necessary and no one would argue with that, that if in fact, and not just education for that individual child education for the school district to be able to provide an educational environment, then you would say, okay, this is what happens. It would be educationally necessary if in fact, black students were behaved, worse behaved. And so that the reason why there are more out of school suspensions for black students is not because they are applying the policy in a discriminatory way, but because black students are in fact behaving worse. Now, the data says that that's not the problem, that when you control for severity of illness, excuse me, thinking back to my other hat, which is healthcare, when you control for severity of behavior, what you find is that black kids are disciplined more harshly for the same behavior, that the difference in suspension rates is really housed in the philosophy of the principle and the administrators, because those are the two people that have a check on what the teacher does. And so that you can get some schools like in our, we have one school school in our area, Westwood, that in 2012 had 88 suspensions per 100 kids, and we had another school, Louise Troy, who had 11 suspensions per 100 kids. Those schools are on the same side of town, serve the same population group. And so the behavior can't be explained by that, but can be explained by what the principal is doing and what the school district is doing. And in fact, I think that holds true in Dayton, because when we talked with different people in the administration, we were told that principals were given a lot of leadway in how they implemented the code of conduct. But I think there's other data that in Dayton, at least that supports the idea that black kids are being disciplined more harshly for the same behavior. When we looked at discipline in 2012 by the types of behavior that was being disciplined, we found the most amazing information, disturbing information. This chart shows the grade level and the discipline category in which there were only black kids suspended. That is no Asian, no white, no Hispanic, no multiracial, only black kids suspended. You can see that fighting and violence, only black kids in the first, second, and third grade. The one that I found that most disturbing for me is harassment and intimidation, because it seems to be a label that's being put only on black kids. Every grade level except second and seventh grade. And second grade had no suspensions in that grade level. Seventh grade had some suspensions of white kids in that level.  Now, I'm thinking back to when I grew up, and I grew up in the 40s and the 50s. And I remember my foster mother saying to me in the 60s, I remember my foster mother, my foster mother who was college educated but worked clean houses. And that wasn't unusual because many blacks, most blacks who got a college education found that there were no jobs at that time, which is working hard, but not no jobs for the college educated. So she cleaned house. And she would come home and she would constantly say to us, white kids don't do this. White kids don't run in the house. White kids don't leave vegetables on their plate. White kids don't shout. Whatever behavior she didn't like in us, it was white kids don't. White kids don't do that. And you would begin to believe that white kids were perfect. And based on this data, you would begin to believe that black kids are horrible because they're the only ones doing the fighting and the violence, the harassment and the intimidation, the use of drugs, the use of tobacco. And I just don't believe that. I believe that this supports what other research has shown, that black kids are being engaged in the same behavior that other kids are engaged in, but they are being disciplined more harshly and more frequently for that behavior and other disciplined methods than out-of-school suspension is being used for the other students. So it is not educational necessary because black kids are behaving more in a way that requires it. I want to go back just a second. The other educational necessary is preschool to third grade suspension should be educationally unnecessary, even if black kids were behaving more, were worse behaved, because all of the developmental sciences say that that suspending preschool to third grade is developmentally inappropriate. So, and as we can see, blacks have significant more suspensions in those grade levels than whites. So what are some of the other reasons that are used to justify say that it's educationally necessary? One justification is getting the parents' attention and active involvement. Certainly that would be the ideal. If suspensions heighten the parental awareness of what's going on and got them more actively involved, that certainly would be a reason to say that they were educationally necessary. But the reality is that the behavior often can be a signal that there's something going on at home that is at the root of the problems, especially for the very young children. And so suspending them to home doesn't provide any assurances that parents are going to have any heightened awareness. And in fact, the problem becomes that parents, many parents of every educational economic background are so overextended that a suspended child only becomes a stressor. It doesn't become something that really, that they can engage in. They don't take off of work to be with that child. They put that child in daycare. Or worse, they have a older sibling stay home from school. Or they, in fact, the child stays home alone. So it may not be effective. And if getting attention is one of the things we want to do, there's certainly less extreme approaches than out of school suspension to get parents' attention. Certainly not an educational necessity for the child, because if in fact the home is a stressor, then suspension becomes just another stressor. So out of school suspension is an ineffective way of getting parents' attention and active involvement. The other reason that is often provided is to provide a deterrence for other students and to deter future behavior. So if that's in fact what happens, if we want to deter future behavior, what you would expect to see is that the behavior, the child would come back from detention with improved behavior. And what you see is that there's no evidence that those children actually change their behavior. There's no evidence that it does anything to improve safety, which is another issue. The people give to ensure safety of the children. And so children come back to school and they actually get more suspensions. And it may be that one of the reasons that occurs is because if some children, especially children who are left home alone and children who are left home with an older sibling may find that preferable to be in the school and dealing with the school environment. And there's no research evidence that suspending one child defers another child from the behavior. In fact, one of the, one issue that people constantly raise up is safety of children and staff. And that might be a good reason, and that might, it would be a good reason if in fact children came back with such a changed behavior.  If you have a child that throws temper tantrums and throws things. If you suspend them and when they come back, they no longer do those things. That would definitely be a point of ensuring safety of children and staff. But those children come back with those same behaviors. And so the out of school suspensions is ineffective for ensuring safety of children and staff because the only thing that's going to ensure safety in children and staff is to make changes in that child behavior. And in the school is the place where that can occur. Finally, along with that goes ensuring that is conductive to teaching. And it's true that some students need to be taken out of the classroom because of the disruptiveness of their behavior. But that doesn't mean that need to be suspended from school. There are alternatives that would allow the classroom to continue and move forward while the child to receive help, other additional help. Plus there's research that shows that putting a different, the same student in different classrooms tend to decrease the disruptions. Because to some extent the skill of the teacher is an issue as to how disruptive a child's behavior is. As engagement goes up, as teaching engagement goes up, classroom disruptive behavior goes down. So to the extent that a teacher or a class or a school is having a significant problem with disruptive behavior, the question might be, are those, are they really engaging the students in a way that needs to be engaged? So you can see from my discussion that I don't believe that out of school suspensions can be justified as an educational necessity. And without that justification, anywhere there's a discriminatory effect, they would be unlawful. But even if justified, a school district may still legally need to change if there's a less discriminatory alternative. And so the question is, are there less discriminatory alternatives? And the answer is yes. Start with the fact that out of school suspensions are ineffective for changing behavior and that they are educationally harmful. When you start there, then you have to look, okay, what alternatives that are more effective in changing behavior and less educationally harmful? And we have system-wide positive behavior interventions and support. We have restorative justice, peer mediation, an early childhood intervention and referral team, and support and training for teachers, including classroom management, cultural incompetent teaching, and bias-free discipline. One or all of those in combination can, are better alternatives to suspension, to out of school suspension. I want to talk a minute, I'm not going to go into detail because there's plenty of information on the internet and I wanted to keep this kind of short. It's already at 40 minutes, but I wanted to talk about the difference between culture incompetent teaching and bias-free discipline because there is a difference. But implicit bias, you can have implicit bias in the way you judge people and still do culturally competent teaching. Culturally competent teaching is about integrating differences about culture and recognizing differences in cultural needs and integrating it into your teaching. Even a culturally competent teacher can have implicit biases that have them look negatively or positively. For instance, 80 percent of whites have a pro-white bias so that when they look at whites, they judge whites' behavior in a much positive way than when they look at non-whites. By the same token, just hiring blacks of people of color won't get you a bias-free discipline because 30 to 40 percent of blacks have a pro-white bias. Bias, to get rid of bias-free discipline, they will have to implement alternatives and training that actually deals with bias and not just with cultural competency. And just getting rid of suspensions won't get rid of bias-free discipline. Whatever is implemented, I think Cincinnati is evidence of that. Cincinnati has one of the lowest suspension rates in the state, 2.9 or something per 100. And yet when you look at their other disciplinary methods, they continue to have a discriminatory effect in their other disciplines. And that's because they continue to have bias discipline. You have to actually work on getting rid of bias-free discipline and not just to get rid of the discriminatory effect in other discipline-marry methods. And the question you might ask is, why then focus on out-of-school suspensions at all? And that's because out-of-school suspensions are harmful in a way that other disciplinary methods are not. Out-of-school suspensions more than peer media is the leading indication of academic difficulty, which of course that makes perfect sense. If you're suspending a child, even for one day, they're missing that lesson for that day. And if they have repeated the suspension, then it's all accumulative. And at some point it accumulates enough where they drop out of school and eventually the future incarceration. So this is how it all connects to the school-to-prison pipeline. So under Title VI, Civil Rights Act of Nineteenth, SKU's 64 Disparate Impact Theory, does the practice of out-of-school suspensions have a discriminatory effect? The answer for Dayton is yes. You would have to look at the data in your school district to be able to answer that question. If you answer no to that question, then the rest of the questions are irrelevant. Stop. You can't go anywhere with it. Once you answer yes, the question is the practice educational necessity. I believe the answer to that question is no. But even if the answer is yes, there's still the question, is there equally effective, less discriminatory alternatives? Now, let me go back to the second question. If the practice is not educational necessary, then it doesn't matter whether there are equally effective, less discriminatory alternatives. If the practice is not educational necessary, then the practice should stop, period. Doesn't matter what alternatives there are. The only time when the issue of alternatives come into play is if you say that the practice is educationally necessary. In that point, you ask the question, well, are there equally effective, less discriminatory alternatives? Since the answer to that question is yes, there are equally effective, less discriminatory alternatives available. So any school district who has this array of answers to these questions should be looking at making changes. Part of the problem is that oftentimes school districts are not proactive in wanting to do this. And it often takes an actual legal suit or complaint to the Department of Education. Because remember what I told you at the very beginning, the way the law is set up now, you cannot file a lawsuit under this theory. All you can do is file a complaint with the Department of Education. So you should consider whether or not it's in your strategy to file a complaint. Do you think things are so bad? Is the school board and our school district so nonresponsive to this issue that you think that only a complaint with the Department of Education? I would encourage you to not sit too long on that in terms of whether you think that is an issue. Because we have a friendly Department of Justice now. In two years, we may have another administration. Well, we definitely will have another administration. It won't be the Obama administration. And that means whether it's Democrat or Republican, that they may have different priorities. Right now, this is a priority for the Obama administration. So it may be something that you will want to actively consider. Activists working on eliminating school pushouts should use the Despair Impact Standard of Law Review as grounds for surimities for the unjust and unnecessary removal of Black children from school. Please take a look at Daniel Lawson's article. I think you'll find it very detailed and very informative. Thank you.


Thank you that Transience before small story about why I called you at Transience. So like Jean said, I'm talking about the building area. We made WP rockets, you might know. It's your premium and a worthless cash play-in. And recently we modified, which is a play-in and service to optimize your media and images. So both of these projects are about optimization and also are Transience. Because Transience, I look for you on your website. Why? Who already know what is a Transience? Who already use Transience? Maybe the other government. Ah, yes. So I will give you some questions like what it is, why, and how. Just a question, what is a Transience? Transience is a temporary thing. What is Transience in Codex for us? Transience API offers a simple and standardized way to store your footage data in the database. So probably, like you need it, it's just a main engine and a frame. After which, if you expire, it's very important and easy to do. You can do this on this page of your codex, on worker.org. But it's not totally true. Because why? First, it's not the same as an option. You may know if you are already doing it, that Transience is stored in the database. In the options and table. But it's not acts like an option. Like I just said, it's not only in the database. Codex said it's stored in the database. Okay. So it's not only in the database. Because if you're using memcache or opcache, the Transience won't be stored in the database, but directly in the server's memory. So the codex doesn't talk about that. In the time-out, the time frame is not mandatory. The codex is not ten years. It's not mandatory. You could add a time-out to make your presence scarce. But it's not mandatory at all. Also, it can be deleted before the time-out. So the time-out is not a minimum lifetime. It's a maximum age, in fact, for your Transience. And the worst, it's because it's still in the database after expiration. It means if today I set the Transience for one day, I can back on my website seven days later, I go in my database. The Transience is still there. So the codex is not very accurate for this. But we'll see why and how to deal with them, etc. So why do we have to use the Transience? Is it a storage system? Because you get data. You store them in the Transience API in the database. But it's not a storage system. It's a cache system. Because you will gain performance by using the Transience API form with us. We will see quickly when we can use the Transience. For example, in your front-end, if you get the same contents on the many pages, like your last comments, your last posts in the sidebar, you don't have to always go to the database to do request again and again for the last comments between two pages, two editors. It will be the same comments, maybe for one hour, maybe for one day, we'll see also later when we can deal with them. So you can use it on the front-end for the same contents on the many pages. Also, when you do external requests, like your followers, your last tweets, your friends from Facebook or an API, an external API, you don't want that each visitor will gain a website. Each page will load your followers, your last tweets, etc. Each time will do an external request, and you may note an external request at the same time. So it will exactly be slower, of course, but using the Transience, you will cache the data. And some examples for the front-end if you do custom requests in your database using custom tables with big joints, you may need to cache the data as a result of the request because you don't want to again go in the database each time for each page for each visitor. An example for the back-end, you can display a message for a particular user written from a validation or a custom error. The two screenshots here are from the WordPress core. The first one is when you try to activate a plugin, that trigger of a fatal error. So WordPress will try to include the plugin, to activate the plugin in a kind of sandbox mode. We'll grab the error using output buffers, then it will need to refresh the page. But between the refresh, it will lose the information about an error or a strikeout. So it will store the error in a Transience with a user ID and then display later the reason of why this plugin can be activated. And it's the same when you delete plugins. WordPress will store the results of the deleted plugins if it's worked or not. A little example, it's the code from a WordPress core. I just deleted the comments. We will delete some plugins, the one we just checked in our back-end. This will be stored in a variable called deleteResult. Then we will use setTransient, we will see later how to use it, with the name plugins deleteResult, with the user ID, and then the result of this deletion. Then later, after the first refresh, WordPress will get the Transient, of course with the same name, for this particular user ID. It means if another user is refreshing another page, he won't have the notice for him. It's just for this user, because this user deleted some plugins before. Then we delete the Transient, because we don't need it anymore, and then we can display the message, the selected plugins have been deleted. So this case is not for performance, but you can use it to display some information later, and then you delete yourself your Transient. So you don't need a timeframe, an expiration. It's not mandatory, like I said. Where can we use the Transient? A few examples. If you're running a website with widgets like Meteo, Radeo, Lastwitz, et cetera, you may need to use a Transient. In fact, for all of these cases, you need Transient, of course. But do I have to manually delete my Transient? Do I have to add a timeframe for my Transient? Okay, a timeframe, but a long one, a short one. What is this? For example, for the Meteo, I think half an hour or an hour is enough to cache the data. I don't think the clouds will be there in one hour, or new clouds with rain will come. So one hour is kind of perfect. On Radeo, maybe three or five minutes, okay, it's very short, but each three or five minutes, you get a new song. For your Lastwitz, it depends on your tweets, if you are a Twitter fan, maybe you will tweet at ten times per hour, so you need to refresh more. If you tweet not so much, maybe one time per day is enough. You will reduce the external request calls. For your friends or followers, I think one day is enough. Same for your last member, if you're running like a forum, something like that. Same for your popular posts, you will get some new stats, which one is now the first, the third, et cetera. So these six examples are done with Transients, with Timeout. This one, this one's your menu, your bug role, your tag cloud. I can't say I need to refresh in one hour or one day. My menu will be the same, even in one month, two months. I won't set my Transients for two months because in three months it will be the same. So I have to do it manually. What's the difference? The Transients will stay in the database as we saw earlier. So I will have to myself go to delete my Transients. So when do I have to do this? For my menu, I will wait to have a new entry in my menu. Oh, this is correct, okay. When I delete something in my menu, same for my tag cloud. If I don't add or delete or update a new tag, I don't need to refresh my Transients about my tags. So you can use the WordPress hooks on the menu, on tag, on your post. Each time you will update a post, create a new post or delete a post, you will force the Transients to be deleted. Your Transients to be deleted so the next time you want to show your last post, the new Transients will store the new data. For your custom request, I can't tell. It depends on your request, on your needs. It could be automatic, it could be manual. You have to understand when and why to use it. Then you could answer yourself to this question if you need a large or short expiration time frame. Don't use Transients on live data because this example is from the WordPress.org download counter, of course. If I use the Transient to store my number of downloads, I will store them for like one second, two seconds. Is it really useful? Not sure. You may find, HK is of course, you may need but avoid to use Transients on live data because it's cache so it's not very live. And the big question, how? How to use Transients? First, is it from the database or object cache? Here comes a little drawing I did talking about Transient Caching without object cache.  Each time a page is requested, the database will be called and then your WordPress page will be displayed. New page, new call and the page will be displayed again. But if you are using object cache like memcache, your Transients are stored in the server memory and directly it can be set on your pages.  We'll see this why you don't have to do this because the server will manage itself the expiration and depending on his memory needs. We get three basic functions to play with Transients. So, we can set get and delete them and we also get the same with site, set site Transients. But be careful because the site Transients functions are not the functions that manage the multi-site compatibility. In fact, when you use the site Transient functions and you're using a not multi-site WordPress, it will fall back on this one, set Transient. So, we could say I will always use this one. If I'm not in a multi-site, the fallback will be okay if I'm using a multi-site, this one will be okay. Yes and no because if I get two websites or three websites or ten websites in my multi-site that will do an external request to get my followers on each website, I will get the same results because it's the same user, it's the same number of followers but I will have ten requests. So, it depends on the request. If the request is only for this website and another website shouldn't read the Transient, you should continue to use this one. If it's for only one website in your multi-site, you will use set site Transient. Let's see how set Transient works with three parameters. The first is the name of your Transient. Be careful because in your database, WordPress will add two prefixes because you will have two entries in your database if you're using a timeout. So, underscore transient underscore then underscore transient underscore timeout underscore. It means if you are naming your Transient like superplugin and MD5 unique ID, this is the name of your Transient timeout. 64 characters, it's the maximum. It means if I add superplugins, it will be 65. In the database, it will be truncated. So, this one won't be stored. And for the next call, when I will get the Transient, I will get with the last letter, so you won't never find it. So, the getTransient will always return false. So, be careful about your name. I suggest you to cut the MD5, not using the 32 characters for the MD5, you can just like 8, 10, it's enough. And this is a bad ID, I did that. If you use the date of today, okay. This is not a real date. 16 August 14, then tomorrow it will stay in your database for error because we will see why just after. The deletion of the plugin is not automatic. You have to request a known Transient to be deleted by WordPress. But tomorrow, it won't be the same date. So, you can't get a Transient with the date of yesterday. The value. So, you can use strings, integers, arrays, objects, serialized data, and you get 4 gigabytes of data. Pretty enough. But don't try to add a simple XML object directly. If you do this, it will explode. Not you, your development. And the famous exploration. So, the length is in seconds. It's not a date. You can't tell expiration 31 December. You have to add a number of seconds. And this number of seconds is a maximum age. It's not an expiration guarantee. It means if I set a Transient for like one year, I can assure you it won't never stay one year in your database.  Yeah. If you're using subscripts or plugins that will purge your Transients, it will be deleted before. So, it's not a lifetime. It's just a maximum age. You can't relay on that like a cron. It's not a cron. It's not a web cron. If you want to be sure that your data will stay in your database, don't use Transient. Use an option. Like I said in the first slide, a Transient, it's a temporary thing. It's pretty important. If you're using object cache, it also be possible to be deleted earlier because when the server doesn't have enough memory, it will start to delete the Transients by age. It doesn't look for the timeout just in the added orders. And if you don't use exploration, so zero second, and you don't use object cache, it will always be in your database. This is why you have to delete them. And take care of the autoload. You may know or not. In the options table, when you add an option, you can set autoload yes or no. It means when WordPress is loading, all the autoload yes options will be loaded in a PHP object. It means if I don't add an exploration, and I get a big Transient, it will be autoloaded. 4 gigabytes in the PHP memory. Maximum. If you use an exploration, the autoload will be set to false. So each time WordPress will need to get this Transient, it will do two requests in the database. Ten Transients equal 20 requests. It's not a big deal because it's two very small requests. You can't... how to tell? You can't say it will be slower. I'm not sure. Because it's very... two requests, very, very small in fact. So now you set Transient, you will now get Transient with only one parameter, the name. But you have to check with equal, equal, equal to check the type of the result. Because if you set a Transient from your followers, and you get zero followers, sorry for you, and you don't check with three equal symbols, the Get Transient will return false because zero is equal to false. So it will do again the external request to get your follower, then zero again, then get equal false, and it's a loop. Your Transient is not working using the three equal symbols. You will check if it's really false, really false. I don't know these Transients. Again, I talked about the deletion. The Transient is now only deleted now because you try to get the Transient. If the timeout expired, okay, now WordPress will delete it. If you don't try to get this Transient, it will stay in the database for a while. This is why you can't use a date in the name of a Transient. Talking about hooks, it won't trigger this hook. When you get the Transient and it's expired, delet Transient with the name of your Transient won't be triggered, but this one will be. It's absolutely not in the codex, only on my slide. Quick example. I've got a function and my external API request, and I return the data. I can do something with my data, of course. So each time I will call my function, each time I will do my API request. So this is bad. Use Transient. The code is not so difficult. You will try to get your Transient with your custom name. If the data is absolutely equal to false, so I don't know how my Transients may be expired, so I will do my external request. I will set my Transient with the same name of the GetTransient, of course, my data and my expiration. Then, like earlier, I do something with and I return. Next call. The GetTransient won't return false, so the if is false. Directly, I do something and I return. My external request API has been done. It's quite the same when you use persistent cache with WordPress. The code is slightly the same, but the cache is not... This kind of cache is not in the database, only in the WordPress memory. So the cache Transients will stay between pages, not this one. And this is a bad idea, because if you try to read the timeout yourself using GetOption, because maybe you will have the bad idea like me, because I did that, to tell I will try to get the Transients. If the Transient has expired, I will try to get my new data, but what if the external request will fail because website is down or what? I just lost my data. So you could think about doing your own GetOption to read the timeout, then check yourself the timeout and get the option yourself. But first, you will miss the Transient hooks, so it's not very cool. And remember that if Transients are used with memcache, you won't be able to read them using Option, because Option will only read the database, not the server memory. So it's a bad idea. Sometimes you have to delete your Transient yourself with only one parameter, and this is the same false good idea because the delete option won't work if you're using object cache or memcache, because options are not Transients. You may know Rust, I think is here today. He did this little script to delete your expert Transient in your database. So the magic line is here, if WordPress is using external object cache return, there's nothing, it won't work. But if you're not using object cache, so he will himself request all your Transients with an expert time. So you can use this script to delete your Transient and then clean your database from pure Transient, old Transient, etc. It's a good one. And this will trigger the previous hooks I talked about. A little help for you. I propose you four plugins to clean your Transients from your backend. You can delete them with the second one. The artists and this one are kind of the same. The Transient Manager is not the same. You will find all your Transients set in your database. You will see the next exploration, etc. And if you're using debug bar, you will find for each page how many Transients have been loaded, etc. Thank you. Have you got some questions about Transients? Thank you, Julia. Let's give it up for Julia first. Big round of applause. If you have any questions, just raise your hand. We'll have a mic runner come around and bring you the microphone. Hello. If your server has object caching, do you have to specify if you want your Transient to be stored in object cache? No, you don't have to. WordPress will do it itself. I've never used it before, so the one place I would have it would be with menus. Would it be something that you'd trigger on the saving of a menu, like a hook? Yeah, you can do it on the save menu. Each time you add an item on your switch items, the save menu hook is a good one, yes. Because sometimes you get big menus and the request can be huge. It's a kind of a get post. And each time you load your website, you get one, maybe two, sometimes three menus, so it can be loud, heavy. I thought about it a bit more, but you mentioned that there was, I think it was a plug-in or a bit of code to delete all the expired Transients. I was thinking during web development, you might want to delete all your Transients, whether they're expired or not, because you're testing and you just want to see the new data. Even if you've got Transients set for an hour, do you know if there's something in the API for that? No, you can do your own request. Personally, I go in my PHP, my admin. I select all like Transients, delete all.  It's a very bad idea. When you delete all your Transients, they might have to remain the same. Maybe the next call will be slower, but it doesn't have to break anything, any display, any widget, et cetera. Transients are really temporary. So let's imagine you update your WordPress core.  Imagine your website has been configured. It's not logical. Your Transients are really temporary. You could delete them at any moments, but not your options. Don't delete your options. Thanks. Hi. If doing a core upgrade with WordPress deletes all your Transients, what's the best way to handle that if you're reliant on those Transients for some sort of functionality in the website? Don't use Transients. For example, if we use it in one particular case where we're storing a cookie with an ID in it, and the ID is a way of relating those two things, it is a temporary thing. It's temporary, but not really temporary. You can create your own Transients using the options. You set your own timeout, your own option. You grab your own timeout, check, et cetera. And then you are sure that your Transient will be related with the RAR scripts or the WordPress updates or manually. You have to do it just... What would be your strategy for warming up the cache after a core update? Let's say you have Transient because you have some very heavy API calls, and then after every core update there would be many slow page loads. How would you handle that? Do you want that this Transient will be deleted? Yeah, they will be deleted at the core update, but how would you warm up the cache again after the core update, so trigger to recreating the Transients? Just reload. Just reload your WordPress. You can do that using your own bot, maybe. Like for the WP Rocket, when you pair the cache, our bot is asked to come on the website and store the new page in the cache of the user. So, kind of that. Each time your WordPress site has been updated or this particular Transient has been deleted, you can ask being a cron or something to get on your website to load the heavy... and avoid that it will be done by your visitors. So, you would say which pages would create the Transient and then just load them after the core update? Because otherwise the first user browsing the page would trigger the Transient update. Yes, so if you don't want that the user is the one through the Transient, ask a bot to visit your website, any page, logically any page, it depends on your development. Maybe it's only for the backend, maybe only for a particular page. Kind of leading off the back of that, I was going to ask if you knew of any other solutions to not deleting Transients when they need recreating. Because last year Mark Jaquith was talking about a plugin he wrote that basically does when a deletion is appropriate, it doesn't delete the Transient, it loves it and then requests the new data in the background. I don't know if you knew of any other solution to that or if that's still the only thing around. I tested this one and it's working, but I'm not sure that it would be implemented in WordPress. But it's a way to do it, to avoid losing data before grabbing some new ones. That also affects the previous comment about the performance of new people coming, it stops that performance here. Good question. You won a shirt, not for me. Can you cite any real world examples that you've come across of a dramatic performance improvement after implementing Transients? The best performance gain is always from external requests. But for example, I'd be interested to know if we're saving half a second on a page load or if you've seen more dramatic improvements. Yes, this is... I mean, I think I gained like three seconds on a page using Transient because I was using a short code and each short code was using an external request and in my page I could use any short codes... How to tell? Any number of short codes I want. So if I put 10 short codes or 20 short codes, each time I've got 20 external requests. So of course you can't do that. 20 on different URLs. Each time you will have to recover the DNS, call the API, authentication, retrieve the data, display. So you can gain like one second, two seconds, maybe ten seconds. External request is the best gain performance visible.


I saw. Whoa, whoa, whoa, whoa, whoa, whoa. Clap the room, I'm coming through, they want to see what I'm about. Yeah, I got skills, do it for the thrill, I'm on a pay for proud. If you can stay ahead of this curve and start training now and start getting your mindset right now, and by the way, plus your egos, if anybody in this room has an ego, I just did the math on how much money you can make in this business. Why acting like you made it? You set your standards to what was what you did, is that those who can carry the highest threshold of pain, those that can carry the highest threshold of pain are those that can go the farthest and make the most money and are the most grateful, okay?  But if you have had an easy life, there's not a good life ahead for you.  You're doing better than you were doing in the past, and guess what? Now you think you made it. One good year doesn't mean nothing. Being consistent is what this business is about.  Slaughter in your competition every freaking day for 20 freaking years. You told me you were doing the work sales in the history of time, and now you're this guy. I don't understand. You know what I mean? Where did that come in? Where did you get the time to train? How did it all happen? I said, what's just a priority? Because I understand what burnout looks like. I understand what no purpose looks like. I understand what going home at the end of the day and having an empty heart feels like. Feels like. That looks like it. Feels like. You know what I mean? You know, I understand what it's like to get close to losing your whole family. I understand all those things. So the idea of it is until you can get in that spot, you don't understand. A lot of people today have a job, and you know, it's just a job. What we have is we have a whole life. You know what I mean? We have a life here. And when you go into other people's spaces, sometimes you don't realize how lucky we are here. Which is why every day when I say, hey, I have a meeting. Hey, you're fired up. Every time you guys talk to somebody, you have to understand that the way that I am telling you that we all need to be, they have never seen. Our role as a stay sponge is until we die. Yeah.  Is that right, Sam? Yeah. Always look around at everybody and make sure it goes with the will of the take. Hey, buddy.  I believe it. I mean, I'm going to tell you this, but it was yesterday. Which day of the week did he do it? Does anybody judge him? No. No, you know what it is? It's about who you are today. And I'm going to tell you this, every single person in this world, right? Every person in this world has shame. They're unworthy. They have these problems, but together as a team, right? We're dangerous together because we're a group of underdogs. The world needs us to go out today and play the same.