Healthy volunteers
Not accepted
Inclusion Criteria: - Informed consent obtained before any trial-related activities. Trial-related activities are any procedures that are carried out as part of the trial, including activities to determine suitability for the trial - Diagnosed with type 2 diabetes mellitus - Treatment with up to 2 OADs (oral anti-diabetic) (metformin, glitazone, SGLT-2 inhibitor (sodium-glucose cotransporter-2 inhibitors) or sulphonylurea) - Stable treatment with basal insulin according to its label (no requirement of minimum or maximum dose) for at least 90 days prior to screening, as judged by the investigator - HbA1c (glycosylated haemoglobin) 6.0-10.0% (both inclusive) - BMI (body mass index) equal to or above 27 kg/m\^2 - Age at least 18 years at the time of signing informed consent Exclusion Criteria: - Diagnosis of type 1 diabetes - Known hypoglycaemic unawareness as indicated by the investigator according to Clarke's questionnaire question 8 (see Section 8.2.3) - Recurrent severe hypoglycaemic episodes within the last year as judged by the investigator - Unable or unwilling to perform self-monitoring of plasma glucose according to the protocol and to keep a diabetes diary - Treatment with any hypoglycaemic medications other than OADs and basal insulin within the past 90 days prior to screening - Treatment with a DPP-IV (dipeptidyl peptidase-4) inhibitor within the past 90 days prior to screening - Recent history of cardiovascular disease (myocardial infarction or stroke within the past 6 months), severe congestive heart failure (NYHA class III, IV), or second degree or greater heart block - Personal or family history of Medullary Thyroid Carcinoma (MTC) or Multiple Endocrine Neoplasia type 2 (MEN2) - Female who is pregnant, breast-feeding or intends to become pregnant or is of child-bearing potential and not using an adequate contraceptive method (adequate contraceptive measure as required by local regulation or practice) - For Germany: Only highly effective methods of birth control are accepted (i.e. one that results in less than 1% per year failure rate when used consistently and correctly such as implants, injectables, combined oral contraceptives, some intrauterine device), or sexual abstinence or vasectomised partner - Use in past 90 days of medications known to induce significant weight loss (e.g., prescription weight loss medications) or weight gain (e.g., chronic use of oral steroids, second generation antipsychotics) - History of pancreatitis (acute or chronic) - History of major depressive disorder within the past 2 years - Any lifetime history of a suicide attempt - Inadequately treated blood pressure defined as Grade 3 hypertension or higher (Systolic above or equal to 180 mmHg or diastolic above or equal to110 mmHg). - History of malignancy (except for non-melanoma skin cancer) within the past 5 years