Case was back in Chiba City for operations to heal Molly:
He looked down at [the shuriken]. They'd passed the shop where she'd
bought it for him, when they'd gone to Chiba together for the last of
her operations. He'd gone to the Chatsubo, that night, while she was
in the clinic, and seen Ratz. Something had kept him away from the
place, on their five previous trips, but now he'd felt like going
No time frame is given by the book, but given her injuries, it's reasonable to assume this is not long after he gets paid off by Wintermute - as little as one month, I would say no more than six.
It's pretty clear from the book, though, that time is not the primary reason Ratz doesn't recognize him:
Ratz had served him without the slightest glimmer of recognition.
"Hey," he'd said, "it's me. Case."
The old eyes regarding him out of their dark webs of wrinkled flesh.
"Ah," Ratz had said, at last, "the artiste." The bartender shrugged.
"I came back."
The man shook his massive, stubbled head. "Night city is not a place
one returns to, artiste..."
At the beginning of the book Case is a desperate junkie, living from deal to deal, spinning out a suicide trajectory of enough complexity that Ratz calls him the artiste. At the end of the book Case has money, is no longer pursued by any of his previous enemies, and is literally slumming when he stops by the bar. Ratz initially doesn't recognize him because he's changed, but more importantly recognizes that the new Case doesn't belong there any more.