Could a sun emit a large piece of matter that escapes it's gravity, and might eventually reach another solar system? And what would be the effect if a planet sized object reached our solar system and enters orbit around our sun?
The sun couldn't. The sun gives off light and a solar wind. It doesn't emit lumps of solid matter. It is possible for a small body, such as a comet to get a slingshot around a planet and be ejected. In the early solar system, when the planets orbits were unstable it is possible that larger bodies were ejected from the solar system. It is thought that rogue planets exist, far from any stars. Some larger than Jupiter.
If a rogue planet were to enter our solar system it would fall towards the sun, pass the sun and leave again. It is possible that it could interact with one of the other planets and enter into a long elliptical orbit. This would be very bad. A planet-sized object in an unstable orbit is not the sort of thing you want in your solar system. We would just have to hope that it never got close enough to Earth to affect it.
A rogue planet could significantly distort Earth's orbit, and if it collided with the Earth, enough energy would be released to melt the entire surface. Fortunately, rogue planets are rare enough that we would not expect one to enter the solar system for a very very long time.