In the current investigation, a new dimeric [Cd(DNBA)2(py)2]2 and a polymeric [Cd(DNBA)2(pyz)2]n cadmium complexes have been prepared by the reaction of 3,5-dinitrobenzoic acid (main ligand), nitrogen donor auxiliary ligands (pyridine and pyrazine), and Cd(II) sulphate in aqueous media. The crystal structures of the synthesized compounds were determined by single-crystal X-ray diffraction analysis. The crystal structures were investigated in terms of the coordination geometry, dihedral angles between various rings, and intermolecular interactions. The solid-state assembly was stabilized by various interatomic contacts, explored by Hirshfeld surface analysis. Void analysis was performed to predict the response of crystals to the applied stress. The optimized molecular geometries of the compounds were achieved utilizing the DFT approach along with the B3LYP functional/6–311G(d,p)/LANL2DZ basic set. MEP maps, molecular orbital theory, and quantum chemical parameters for the synthesized compounds were generated using the same level of theory.