A judge can't approve an I-485 if there is no immediately available immigrant visa - so they can't approve if the priority date isn't current when you are before the judge.
Even if it is, they may not approve anyway, as the I-485 case shouldn't have been filed when the priority date wasn't current. It may have been best to re-file when the priority date WAS current if this was possible; the case would then sit on hold, offering protection as to status and the ability to get employment authorization as long as it was pending.
Speak with a lawyer for guidance on your current situation.
Neither an Immigration Judge nor the USCIS can approve the I-485 unless the priority date is current.
If you have further questions, let me know.
Attorney at Law & CPA
Law Offices of Rehan Alimohammad, PC
Houston Office: 281-340-2074
Toll Free: 800-814-3920