When Baley dies. Daneel's reaction is decidedly human.
Ditto when Giskard dies.
The dying Baley refuses to let Daneel stay until his death, much as he would like to, for fear of the effect witnessing his 'Partner Elijah's' death might have on Daneel's First Law impressed positronic brain.
He also won't let Gladia see him on his deathbed, fearing her thoughts of him as a frail, dying old man.
An early conversation between Gladia and Daneel has Gladia concerned that the memory capacity of his robotic brain might be reaching its limits after more than two centuries. Daneel doesn't think so but admits he can't be certain — but when Gladia suggests a process to delete some of the more unimportant memories to free more room, Daneel declines. Why? Because he's afraid that the process would, perhaps accidentally, remove some of his memories of Elijah Baley. And he doesn't want to lose a single one.