What breed of dog is he?About how much does he weigh?Are you sure it was only 3mg?
There's nothing to worry about then.
As you can see from this link: http://www.petplace.com/drug-library/melatonin-melatonex/page1.aspx , a 3mg dose of Melatonin is a normal dose for a dog with a behavioral problem, so the fact your boy ingested that much shouldn't cause any problems with him at all!!
I hope this helps.