Compare environment printout from running standalone with environment printout from running as CGI. Most likely some variables are missing, or some directory is missing from $ENV{PATH}.
Alexander
--
Today I will gladly share my knowledge and experience, for there are no sweeter words than "I told you so". ;-)
Comment on Re: CGI Script connection to SQL Server.