Self-assembly of a flexible building unit 4-pyridylacetic acid (Hpya) with inorganic metal salts Cu(ClO4)2 center dot 6H(2)O, Co(OAc)(2)center dot 4H(2)O, Ni(ClO4)(2)center dot 4H(2)O, AgNO3, and HgCl2 affords five new metal-organic coordination frameworks [M(pya)(2)(H2O)(2)](n) (pya = 4-pyridylacetate; M = Cu for 1; Co for 2; and Ni for 3), [Ag(pya)](n) (4), and [Hg(pya)Cl](n) (5) under similar reaction conditions. Single-crystal X-ray diffraction analyses of these polymeric complexes suggest that 1-3 are isostructural and exhibit a two-dimensional (2D) wavelike layered architecture constructed by alternate left- and right-hand helical chains, in which pya takes the bidentate (N-py, O-COO(-)) bridging mode. However, polymer 4 possesses a three-dimensional (3D) brickwall network generated from the expansion of 2D layers with dinuclear [Ag-2(RCOO)(2)] nodes via further interlayer Ag-O-COO(-) interactions, which is also stabilized by argentophilic interactions (Ag center dot center dot center dot Ag = 2.983(3) angstrom). The structure of 5 seems more complicated, in which the [Hg-2(pya)(2)] boxlike dimeric subunits are extended to a unique 3D framework via multiple Hg-O-COO(-) coordination forces. In the structures of 4 and. 5, the carboxylate groups display unusual mu-O, O'(syn)-mu-O, O and mu-O, O-eta-O, O'-mu-O', O' binding modes, respectively. The significant differences of these metal-organic frameworks indicate that the flexible pya ligand may adjust its coordination fashion to meet the requirement of the coordination preference of the metal center. The fluorescent and thermal properties of these new materials have also been studied.