Tomatoes and peppers from cuttings?

Last year I cut a six inch sucker off of a Yellow Pear tomato in June. I just stuck it in a plain jar of water in a window in the house. It rooted great after a few weeks and grew into a 4 leader vine that was 8 feet tall on all four leaders by the time I pulled it out before frost came.