A term of endearment for a smart, bright little fellow; a Jemmy Jessamy.
Smart she is, and handy, O ! Sweet as sugar-candy, O ! ... `And I'm her Jack-a-dandy, O !
“Dimidium cyathi vero apud Methropolitanos Herbernicos dicitur Dandy.” —Blackwood's Magazine, May, 1838 (Father Tom and the Pope).
Source: Dictionary of Phrase and Fable, E. Cobham Brewer, 1894