The most general chemical equation for oxygen based photosynthesis is as follows:
CO2 + H2O + photons --> CH2O + O2
This can be read as carbon dioxide plus water plus photons (energy from sunlight) gives a carbohydrate (CH2O) and oxygen. You are probably looking for standard plant photosynthesis to make glucose. That equation is here:
6CO2 + 6H2O + photons --> C6H12O6 + 6O2
This can be read as carbon dioxide plus water plus energy from sunlight gives glucose (C6H12O6) and oxygen. Basically the carbon dioxide is taken in through the leaves of the plant. The water is taken in from the root system. Organelles in the plant called chloroplasts contain a pigment called chlorophyll which is able to absorb energy from the sunlight. The glucose produced is the energy the plant uses for its own cellular processes. And the oxygen is a byproduct of the process that is dissipated through the leaves and into the air for humans and animals to breathe.