Michael Gordon, 38, was arrested last month after the mother of a 9-year-old girl could not find the child backstage during a concert by The Dead at Jones Beach.

Gordon and the girl were found together in an enclosed boathouse that is part of the backstage area, police said. He was also charged with trespassing.

The judge threw out the charges Friday after prosecutors said they could not prove their case beyond a reasonable doubt, said Rick Hinshaw, a spokesman for Nassau County District Attorney Denis Dillon.

Hinshaw said the girl’s parents also wanted the charges to be dropped.

After Gordon’s arrest, the band issued a joint statement from Gordon and the girl’s family calling the incident “an unfortunate misunderstanding.”