Grinstein (1980, p. 392) places this dream "some time during the course of his self-analysis" -- i.e., after 1896. Anzieu (1975, pp. 419-430) gives a plausible argument for dating the dream in May, 1899, just before a May 28, 1899 letter to Fliess, in which Freud writes jubilantly of overcoming the last inner obstacles to finishing the dream book. In The Interpretation of Dreams, Freud's followup passage to his main discussion of the dream affirms that

The dissection meant the self-analysis that I was carrying out, as it were, in the publication of this present book about dreams -- a process which had been so distressing to me in reality that I had postponed the printing of the finished manuscript for more than a year. (Freud, 1900 [SE 5], p. 477)

Anzieu, D. (1986). Freud's self-analysis (P. Graham, Trans.). New York: International Universities Press. (Original work published 1975)

Grinstein, A. (1980). Sigmund Freud's dreams. New York: International Universities Press.