Having never read the latter I'm not really sure what to do with this, but it seems like it might be interesting to the more well-read than I. A list of Hamlet references in Ulysses, cited back to Act and Scene inside Hamlet. Lots of them.
UPDATE : It bothers me that the link no longer works, since this seems to be one of my most popularly followed links. I wish I had better info for you. The best I can do is offer to google it for you.