In iThink They Kissed, Carly took Sam to see him after Sam lost one of her teeth during an iCarly sketch, and then revealed that she had not seen a dentist in 12 years.
Sam was extremely nervous, to the point of physically threatening Dr. Wheeler and his assisting hygienist. She calmed down, however, after they administered nitrous oxide (laughing gas) to her. Dr. Wheeler then replaced Sam's missing tooth and filled three other cavities.
Dr. Wheeler and the hygienist went to examine Sam's X-rays, leaving Carly and Sam alone. (It was then that Sam, under the influence of the nitrous oxide, accidentally told Carly that she had once kissed Freddie.)