Numerous scientific studies confirm that, apart from environmental and genetic factors, a significant role is played by gastrointestinal microbiota in the aetiology of type 2 diabetes and obesity. Currently, scientists mainly focus on the distal intestinal microbiota, while the equally important proximal parts of the intestine are overlooked. The aim of the study was a qualitative analysis of the structure of the duodenal mucosa microbiota in groups of patients with obesity and with type 2 diabetes and where obesity qualified for bariatric surgery: sleeve gastrectomy. The microbiological results obtained were compared with some clinical parameters. As a result, it was possible to determine the microbiological core that the treatment and control groups had in common, including phyla: Firmicutes, Proteobacteria, and Actinobacteria. The patients with obesity and with type 2 diabetes and obesity presented a significantly lower number of genus Bifidobacterium compared to healthy subjects. Furthermore, the numbers of Bifidobacterium were positively correlated with the high density lipoprotein (HDL) concentration in the groups under study. The obtained results indicate that bacteria of the genus Bifidobacterium should be considered in the future in the context of a potential biomarker in the progress of type 2 diabetes and obesity.