Click here to Skip to main content
15,888,908 members
Home / Discussions / Database
   

Database

 
GeneralRe: T-SQL Question Pin
turbochimp25-Mar-05 18:12
turbochimp25-Mar-05 18:12 
GeneralRe: T-SQL Question Pin
Suman Singh29-Mar-05 11:38
professionalSuman Singh29-Mar-05 11:38 
GeneralHandle SQL errors with severity 10 Pin
_J_23-Mar-05 9:05
_J_23-Mar-05 9:05 
GeneralRe: Handle SQL errors with severity 10 Pin
Chris Meech23-Mar-05 9:14
Chris Meech23-Mar-05 9:14 
GeneralRe: Handle SQL errors with severity 10 Pin
_J_23-Mar-05 9:29
_J_23-Mar-05 9:29 
GeneralRe: Handle SQL errors with severity 10 Pin
Chris Meech23-Mar-05 9:54
Chris Meech23-Mar-05 9:54 
GeneralRe: Handle SQL errors with severity 10 Pin
_J_23-Mar-05 10:07
_J_23-Mar-05 10:07 
GeneralRe: Handle SQL errors with severity 10 Pin
Colin Angus Mackay23-Mar-05 13:03
Colin Angus Mackay23-Mar-05 13:03 
I think that would be
catch(SqlException se)
{
}


If there is only one error then the exception object will contain the details. If there is more than one error the exception object will contatin the details of only the first error. You then have to look in the errors collection for the other errors.
catch(SqlException se)
{
    foreach(SqlError error in se.Errors)
    {
        // Do something with each error
    }
}


Does this help?


My: Blog | Photos
WDevs.com - Open Source Code Hosting, Blogs, FTP, Mail and More


GeneralRe: Handle SQL errors with severity 10 Pin
_J_23-Mar-05 21:31
_J_23-Mar-05 21:31 
GeneralRow ID after INSERT to database Pin
Abyss22-Mar-05 21:00
Abyss22-Mar-05 21:00 
GeneralRe: Row ID after INSERT to database Pin
_J_23-Mar-05 1:45
_J_23-Mar-05 1:45 
GeneralRe: Row ID after INSERT to database Pin
Abyss23-Mar-05 2:19
Abyss23-Mar-05 2:19 
GeneralRe: Row ID after INSERT to database Pin
Jeff Martin23-Mar-05 3:37
Jeff Martin23-Mar-05 3:37 
GeneralRe: Row ID after INSERT to database Pin
_J_23-Mar-05 3:53
_J_23-Mar-05 3:53 
GeneralRe: Row ID after INSERT to database Pin
Abyss23-Mar-05 21:25
Abyss23-Mar-05 21:25 
GeneralRe: Row ID after INSERT to database Pin
Huseyin Altindag24-Mar-05 0:33
Huseyin Altindag24-Mar-05 0:33 
GeneralRe: Row ID after INSERT to database Pin
Abyss24-Mar-05 1:33
Abyss24-Mar-05 1:33 
GeneralRe: Row ID after INSERT to database Pin
Huseyin Altindag24-Mar-05 1:42
Huseyin Altindag24-Mar-05 1:42 
GeneralRe: Row ID after INSERT to database Pin
Abyss24-Mar-05 1:52
Abyss24-Mar-05 1:52 
GeneralRe: Row ID after INSERT to database Pin
Mike Dimmick24-Mar-05 2:22
Mike Dimmick24-Mar-05 2:22 
GeneralRe: Row ID after INSERT to database Pin
Jeff Martin24-Mar-05 3:19
Jeff Martin24-Mar-05 3:19 
GeneralRe: Row ID after INSERT to database Pin
Abyss24-Mar-05 3:38
Abyss24-Mar-05 3:38 
GeneralRe: Row ID after INSERT to database Pin
Jeff Martin24-Mar-05 4:06
Jeff Martin24-Mar-05 4:06 
GeneralRe: Row ID after INSERT to database Pin
Jeff Martin24-Mar-05 3:15
Jeff Martin24-Mar-05 3:15 
GeneralRe: Row ID after INSERT to database Pin
Abyss24-Mar-05 3:45
Abyss24-Mar-05 3:45 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.