This lamp require 12V AC and i am trying to supply power to it safely. When testing with 12V DC adapter it seems to work but i also have unused 12V transformer that i hope to utilize for this project. Besides the transformer, is there anything else i need in order to provide the adequate power to the lamp safely or is it completely fine to just use the 12V transformer directly?
It is completely fine to use the 12 V transformer directly. Your device wants 12 VAC, and it puts out 12 VAC. As long as it can source the current that the device needs, it should be fine.
Depending on what kind of power supply, if any, is in the lamp, it might need 17 VDC, 12 VDC, or won't work on DC at all.
If it's just a incandescent bulb, then it lights up as a function of the RMS voltage. In that case, if would run fine from DC and would need 12 V.
If the lamp is made from LEDs, then it most likely has a power supply in it. There is a chance that the power supply full wave rectifies the AC to make DC internally, then regulates that further. This is the case where DC would work, but should be the peak of the AC voltage. Since the peaks of a sine are sqrt(2) times its RMS, the DC to use would be 17 V.
High power lamps that have a more fancy power supply that includes power factor regulation might work on a range of DC voltages, or might not work at all, depending on the details of the power supply. However, it is unlikely that this is done in a low power lamp. If the lamp were high enough power to require power factor regulation, then it wouldn't likely run from 12 V.
Since you've already tried 12 VDC and it seems to work, you either have a dumb incandescent bulb, or a flexible enough switching power supply with a wide enough input voltage range to be able to tolerate 12 V in.
It depends on what kind of "lamp" it is. If it is truly a common incandescent bulb, then it will make no difference whether it is 12V DC or 12V (RMS) AC. However if it is some other kind of "lamp" (like an LED or something) then applying AC will ruin it. Double-check to confirm exactly what kind of "lamp" you are talking about.