db-derby-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "TomohitoNakayama" <tomon...@basil.ocn.ne.jp>
Subject Re: Question about error messages (Re: Discussions on Wiki ...)
Date Tue, 11 Oct 2005 22:22:13 GMT
Hello.

> If I understand you correctly, you are asking how the user
> 
> (a) can tell if they're using the network driver or embedded driver and
> 
> The DatabaseMetadata of a connection gives you the driver name, product 
> name, version, etc.  Would this give the information you're looking for?
> 
> (b) can tell if the exception came from the client or the server
> 
> I don't think it's reasonable to want the SQLState to be different; I 
> think that many users very much want them to be the *same* across the 
> drivers, for the same error.  Kathey and Dan have made it pretty clear 
> they should be the same.

No no.
I ask you what "you" want to distinguish in this issue.

There seems to be concept of "error of embedded" and "error of network" in your article.
However, it is ambigous what is the difference between them.

At least , I couldn't read what they exactly are.

Best regards.

/*

         Tomohito Nakayama
         tomonaka@basil.ocn.ne.jp
         tomohito@rose.zero.ad.jp
         tmnk@apache.org

         Naka
         http://www5.ocn.ne.jp/~tomohito/TopPage.html

*/
----- Original Message ----- 
From: "David W. Van Couvering" <David.Vancouvering@Sun.COM>
To: "Derby Development" <derby-dev@db.apache.org>
Sent: Wednesday, October 12, 2005 2:52 AM
Subject: Re: Question about error messages (Re: Discussions on Wiki ...)


> If I understand you correctly, you are asking how the user
> 
> (a) can tell if they're using the network driver or embedded driver and
> 
> The DatabaseMetadata of a connection gives you the driver name, product 
> name, version, etc.  Would this give the information you're looking for?
> 
> (b) can tell if the exception came from the client or the server
> 
> I don't think it's reasonable to want the SQLState to be different; I 
> think that many users very much want them to be the *same* across the 
> drivers, for the same error.  Kathey and Dan have made it pretty clear 
> they should be the same.
> 
> And we have also agreed that using the error code or the implementing 
> class of SQLException is not valid because neither of these are public 
> (and therefore stable) interfaces.
> 
> In the network client, when you construct a SQLException, the full 
> diagnostics of the exception are written to the configured log:
> 
>           if (logWriter != null) {
>             logWriter.traceDiagnosable(this);
> 
> if the exception is from the server, then the trace diagnostics contain 
> information that makes it clear the exception is from the server:
> 
> if ( sqlca != null )
>             printWriter.println(header + " DERBY SQLCA from server");
>             printWriter.println(header + " SqlCode        = " + 
> sqlca.getSqlCode());
>             printWriter.println(header + " SqlErrd        = " + 
> Utils.getStringFromInts(sqlca.getSqlErrd()));
>             printWriter.println(header + " SqlErrmc       = " + 
> sqlca.getSqlErrmc());
>             printWriter.println(header + " SqlErrmcTokens = " + 
> Utils.getStringFromStrings(sqlca.getSqlErrmcTokens()));
>             printWriter.println(header + " SqlErrp        = " + 
> sqlca.getSqlErrp());
>             printWriter.println(header + " SqlState       = " + 
> sqlca.getSqlState());
>             printWriter.println(header + " SqlWarn        = " + new 
> String(sqlca.getSqlWarn()));
> 
> It seems to me this should give the user the information they need, right?
> 
> Thanks,
> 
> David
> 
> TomohitoNakayama wrote:
>> Hello.
>> 
>> This is question around next .
>> http://wiki.apache.org/db-derby/JDBC_error_messages_and_SQL_States
>> 
>> And it seems have something a lot to do with DERBY-254 .
>> http://issues.apache.org/jira/browse/DERBY-254
>> 
>> As in DERBY-254, there seems to be concept of "error of embedded" and 
>> "error of network" .
>> However, it is not clear what does distinguish one from another .
>> * Whether user uses network or embedded driver distinguishes ? * Whether 
>> exception happens in network or embedded implementation distinguishes ?
>> Best regards .
>> 
>> /*
>> 
>>         Tomohito Nakayama
>>         tomonaka@basil.ocn.ne.jp
>>         tomohito@rose.zero.ad.jp
>>         tmnk@apache.org
>> 
>>         Naka
>>         http://www5.ocn.ne.jp/~tomohito/TopPage.html
>> 
>> */
>> ----- Original Message ----- From: "David W. Van Couvering" 
>> <David.Vancouvering@Sun.COM>
>> To: "Derby Development" <derby-dev@db.apache.org>
>> Sent: Saturday, October 08, 2005 5:44 AM
>> Subject: Re: Discussions on Wiki - WAS Re: SQL functions, procedures and 
>> PSM - a possible approach
>> 
>> 
>>> Hi, Tomohito.  It would be great if you could summarize your concerns 
>>> in email and we can continue our discussion on the list.
>>>
>>> If it would help, I'm also more than open for you and I to have an IRC 
>>> conversation, log it, and send the log out to the list.  We do seem to 
>>> be a bit stuck :)
>>>
>>> David
>>>
>>> TomohitoNakayama wrote:
>>>
>>>> Hello.
>>>>
>>>> I understand. Sorry for disturbing .
>>>> I had come to feel difficulties in discussing at Wiki.
>>>>
>>>> Should I ask David my question in mailing list once more ?
>>>>
>>>> Best regards.
>>>>
>>>> /*
>>>>
>>>>         Tomohito Nakayama
>>>>         tomonaka@basil.ocn.ne.jp
>>>>         tomohito@rose.zero.ad.jp
>>>>         tmnk@apache.org
>>>>
>>>>         Naka
>>>>         http://www5.ocn.ne.jp/~tomohito/TopPage.html
>>>>
>>>> */
>>>> ----- Original Message ----- From: "David W. Van Couvering" 
>>>> <David.Vancouvering@Sun.COM>
>>>> To: "Derby Development" <derby-dev@db.apache.org>
>>>> Sent: Friday, October 07, 2005 12:40 PM
>>>> Subject: Re: Discussions on Wiki - WAS Re: SQL functions, procedures 
>>>> and PSM - a possible approach
>>>>
>>>>
>>>>> I'm getting a little concerned, it feels a little quiet over there 
>>>>> in the corner with Tomohito and I, and I was about to propose with 
>>>>> Tomohito that we move it back to the list.
>>>>>
>>>>> David
>>>>>
>>>>> Daniel John Debrunner wrote:
>>>>>
>>>>>> David W. Van Couvering wrote:
>>>>>>
>>>>>>
>>>>>>> This sounds great, Dan!  Is this a good candidate for putting
up 
>>>>>>> on the
>>>>>>> Wiki site as a proposal?
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>> Is anyone else concerned by the movement of discussion to the wiki
for
>>>>>> the common code stuff? The Apache way is for discussions to occur

>>>>>> on the
>>>>>> mailing lists. It seems to me that the wiki is a great way to 
>>>>>> summarize
>>>>>> such discussions, but not to hold them. A wiki page related to a
>>>>>> discussion can provide a very useful single overview, something that
>>>>>> does get lost in mailings as the discussion spreads out.
>>>>>>
>>>>>> Dan.
>>>>>>
>>>>>>
>>>>>
>>>>
>>>>
>>>> --------------------------------------------------------------------------------

>>>>
>>>>
>>>>
>>>> No virus found in this incoming message.
>>>> Checked by AVG Anti-Virus.
>>>> Version: 7.0.344 / Virus Database: 267.11.13/123 - Release Date: 
>>>> 2005/10/06
>>>>
>>>>
>>>>
>>>
>> 
>> 
>> --------------------------------------------------------------------------------

>> 
>> 
>> 
>> No virus found in this incoming message.
>> Checked by AVG Anti-Virus.
>> Version: 7.0.344 / Virus Database: 267.11.13/124 - Release Date: 2005/10/07
>> 
>> 
>> 
>

Mime
View raw message