You are viewing a plain text version of this content. The canonical link for it is here.
Posted to derby-dev@db.apache.org by Laura Stewart <sc...@gmail.com> on 2006/09/08 06:20:00 UTC

SQL State 08001 "User id length ({0}) is outside the range of 1 to {1}."

I need to know the variables for the SQL State 08001 "User id length
({0}) is outside the range of 1 to {1}."

I assume that the second variable is a number (the maximum number
allowed) for a user ID. But is the first variable the length (as in a
number) of the user ID?

-- 
Laura Stewart

Re: SQL State 08001 "User id length ({0}) is outside the range of 1 to {1}."

Posted by Andrew McIntyre <mc...@gmail.com>.
On 9/7/06, Laura Stewart <sc...@gmail.com> wrote:
> I need to know the variables for the SQL State 08001 "User id length
> ({0}) is outside the range of 1 to {1}."
>
> I assume that the second variable is a number (the maximum number
> allowed) for a user ID. But is the first variable the length (as in a
> number) of the user ID?

The first number is the length of the user id with which a connection
attempt has been made. e.g. for connect
'jdbc:derby://localhost/mydb;user=somereallylongusernamethatwillnotbegoingoverthelimitbutyougettheidea;password=short'
the first number would be 68.

The error wouldn't be thrown in that case though, because the second
number is the maximum length for a user id (for the network client),
currently 255 characters. Since user id is internally a String, I
believe that means a max of 255 16-bit Unicode characters, and not 255
bytes or chars, but I haven't actually tracked down how the userid is
parsed out of the connection URL and converted to a String to confirm
that is the absolute truth. It should be true for connections made
through a DataSource since the user id would have started out as a
String.

andrew