{
  "fields": [{"type":"int","id":"_id"},{"info":{"notes":"","type_override":"","label":"The data source that is reported from.  SMR04 covers psychiatric inpatient records."},"type":"text","id":"Dataset"},{"info":{"notes":"","type_override":"","label":"Denotes the financial years covered by this dataset.  Financial years start on 1 April and end on 31 March.  This file shows data for the six-year period from 1 April 2016 to 31 March 2022."},"type":"text","id":"FinancialYear"},{"info":{"notes":"","type_override":"","label":"The length of a patient's time as an inpatient."},"type":"text","id":"LengthOfStay"},{"info":{"notes":"[Country label](https://www.opendata.nhs.scot/dataset/geography-codes-and-labels/resource/9c6e6c56-2697-4184-92c6-60d69c2b6792)\r\n","type_override":"","label":"9-digit code for NHS Scotland as a whole."},"type":"text","id":"Country"},{"info":{"notes":"","type_override":"","label":"The total number of continuous inpatient stays.  A continuous inpatient stay is an unbroken period of time that a patient spends as an inpatient.  However, a patient may change consultant, significant facility, specialty, and/or hospital during a continuous inpatient stay.  As a result, information used to assign a stay to the Learning Disability specialty has to be taken from a single episode within the stay.  In this report, the specialty and the health board of treatment are taken from the last episode in the stay. Moreover, stays are assigned to financial years based on the date of discharge of the last episode in the stay."},"type":"numeric","id":"PatientsCount"}],
  "records": [
    [1,"SMR04","2016/17","Less than a day","S92000003",4],
    [2,"SMR04","2016/17","1 to 7 days","S92000003",8],
    [3,"SMR04","2016/17","8 to 29 days","S92000003",13],
    [4,"SMR04","2016/17","30 - 90 days","S92000003",16],
    [5,"SMR04","2016/17","91 - 365 days","S92000003",52],
    [6,"SMR04","2016/17","Over 365 days","S92000003",145],
    [7,"SMR04","2017/18","Less than a day","S92000003",2],
    [8,"SMR04","2017/18","1 to 7 days","S92000003",10],
    [9,"SMR04","2017/18","8 to 29 days","S92000003",10],
    [10,"SMR04","2017/18","30 - 90 days","S92000003",28],
    [11,"SMR04","2017/18","91 - 365 days","S92000003",43],
    [12,"SMR04","2017/18","Over 365 days","S92000003",116],
    [13,"SMR04","2018/19","Less than a day","S92000003",1],
    [14,"SMR04","2018/19","1 to 7 days","S92000003",9],
    [15,"SMR04","2018/19","8 to 29 days","S92000003",7],
    [16,"SMR04","2018/19","30 - 90 days","S92000003",12],
    [17,"SMR04","2018/19","91 - 365 days","S92000003",42],
    [18,"SMR04","2018/19","Over 365 days","S92000003",122],
    [19,"SMR04","2019/20","Less than a day","S92000003",0],
    [20,"SMR04","2019/20","1 to 7 days","S92000003",9],
    [21,"SMR04","2019/20","8 to 29 days","S92000003",10],
    [22,"SMR04","2019/20","30 - 90 days","S92000003",14],
    [23,"SMR04","2019/20","91 - 365 days","S92000003",26],
    [24,"SMR04","2019/20","Over 365 days","S92000003",107],
    [25,"SMR04","2020/21","Less than a day","S92000003",1],
    [26,"SMR04","2020/21","1 to 7 days","S92000003",4],
    [27,"SMR04","2020/21","8 to 29 days","S92000003",14],
    [28,"SMR04","2020/21","30 - 90 days","S92000003",20],
    [29,"SMR04","2020/21","91 - 365 days","S92000003",38],
    [30,"SMR04","2020/21","Over 365 days","S92000003",84],
    [31,"SMR04","2021/22","Less than a day","S92000003",2],
    [32,"SMR04","2021/22","1 to 7 days","S92000003",4],
    [33,"SMR04","2021/22","8 to 29 days","S92000003",6],
    [34,"SMR04","2021/22","30 - 90 days","S92000003",12],
    [35,"SMR04","2021/22","91 - 365 days","S92000003",38],
    [36,"SMR04","2021/22","Over 365 days","S92000003",100],
    [37,"SMR04","2022/23","Less than a day","S92000003",1],
    [38,"SMR04","2022/23","1 to 7 days","S92000003",7],
    [39,"SMR04","2022/23","8 to 29 days","S92000003",3],
    [40,"SMR04","2022/23","30 - 90 days","S92000003",4],
    [41,"SMR04","2022/23","91 - 365 days","S92000003",37],
    [42,"SMR04","2022/23","Over 365 days","S92000003",91]
]}
