The primary objective is to develop a scoring system using pancreatic volume measured by CT scan and intraoperative measurements of the pancreas parenchyma to predict the onset of diabetes mellitus after a pancreatectomy. The investigators will also monitor patients with pre-existing diabetes to see if their diabetes worsens or improves. Patients will be followed up to one year to track their diabetes status, postoperative outcomes and quality of life.