Thank you, Alexander. That's what I was looking for. Ramakrishna Raju ( "Raju" ) [EMAIL PROTECTED]
-----Original Message----- From: Alexander Foken [mailto:[EMAIL PROTECTED] Sent: Tuesday, March 18, 2008 5:23 AM To: Ramakrishna Raju Cc: Martin Evans; dbi-users@perl.org Subject: Re: perl DBI on windows 64 Not quite an example, but test code, included in the DBD::ODBC distribution. See <http://search.cpan.org/src/MJEVANS/DBD-ODBC-1.15/t/20SqlServer.t> for the current version. The relevant code for the SQL print statement starts near line 436. Alexander On 18.03.2008 11:13, Ramakrishna Raju wrote: > Martin, > > I thought I saw the examples the other day, but I can't seem to > find them now. Could you give me the link to the examples? > > Thanks, > Ramakrishna Raju ( "Raju" ) > [EMAIL PROTECTED] > > -----Original Message----- > From: Martin Evans [mailto:[EMAIL PROTECTED] > Sent: Friday, March 14, 2008 4:07 AM > To: dbi-users@perl.org > Subject: Re: perl DBI on windows 64 > > Ramakrishna Raju wrote: > >> Alexander, >> >> t-SQL has a print command and lot of stored procs have print >> statements in the code to indicate progress of execution or whatever. >> I need to capture it and print that to my log. >> >> In the error handling department, if there is duplicate key >> error on a insert or a table is missing, then that error gets printed >> > to > >> the console thru the perl script, but it's getting printed thru some >> low-level driver and not by the user statement. I need to grab that >> error situation and send out an email or something. How do I do that? >> >> I will do some reading and try to put something together and >> then we can compare notes. >> > > Start your reading with the PrintError, RaiseError and HandleError > attributes in DBI. Of course, once you've looked at the 20SqlServer > example in DBD::ODBC you will see it uses HandleError. > > Martin > -- Alexander Foken mailto:[EMAIL PROTECTED] http://www.foken.de/alexander/ DISCLAIMER: NOTICE REGARDING PRIVACY AND CONFIDENTIALITY This e-mail, and any attachments thereto, is intended only for use by the addressee(s) named herein and may contain legally privileged and/or confidential information. If you are not the intended recipient of this e-mail, you are hereby notified that any dissemination, distribution or copying of this e-mail, and any attachments thereto, is strictly prohibited. If you have received this e-mail in error, please immediately notify me and permanently delete the original and any copy of any e-mail and any printout thereof. E-mail transmission cannot be guaranteed to be secure or error-free. The sender therefore does not accept liability for any errors or omissions in the contents of this message which arise as a result of e-mail transmission. TJM Proprietary Trading, LLC ("TJMPT") may, at its discretion, monitor and review the content of all e-mail communications. TJMPT is a registered joint back office broker dealer with the Chicago Board of Options Exchange "CBOE". TJMPT's office is located at 318 W. Adams Floor 9, Chicago, IL 60606. For more information about TJMPT, please call us at (312)-432- 5100 or fax (312)-432-4498.