The time setting of this verse is prior to the Seven Creative Days—long before. “Heaven” (singular) refers to the earth’s solar system. “Heavens” (plural) would be the entire physical universe including the earth. Psalm 115:16 distinguishes between “heavens” and “heaven,” that is, between the entire universe and our own solar system. “The heaven, even the heavens, are the LORD’S: but the earth hath he given to the children of men.”
Verse 1 zeroes in on the earth, our solar system, which was created with the rest of the universe. No time period is given for this creating, but it took considerable time. Much later the First Creative Day began; it began 48,000+ years ago. Verse 1 can be paraphrased as follows: Before the ordering of the earth’s surface, this condition existed for ‘x’ amount of years.”