Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commitafa178e

Browse files
committed
On Mon, 3 Sep 2001 22:01:17 -0500, you wrote:
>public boolean isWritable(int column) throws SQLException>{> if (isReadOnly(column))> return true;> else> return false;>}The author probably intended: public boolean isWritable(int column) throws SQLException { return !isReadOnly(column); }And if he would have coded it this way he wouldn't have madethis mistake :-)>hence, isWritable() will always return false. this is something>of a problem :)Why exactly? In a way, true is just as incorrect as false, andperhaps it should throw "not implemented". But I guess thatwould be too non-backwardly-compatible.>let me know if i can provide further information.Will you submit a patch?Regards,Ren? Pijlman <rene@lab.applinet.nl>
1 parente4cfff6 commitafa178e

File tree

2 files changed

+2
-8
lines changed

2 files changed

+2
-8
lines changed

‎src/interfaces/jdbc/org/postgresql/jdbc1/ResultSetMetaData.java

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -419,10 +419,7 @@ public boolean isReadOnly(int column) throws SQLException
419419
*/
420420
publicbooleanisWritable(intcolumn)throwsSQLException
421421
{
422-
if (isReadOnly(column))
423-
returntrue;
424-
else
425-
returnfalse;
422+
return !isReadOnly(column);
426423
}
427424

428425
/**

‎src/interfaces/jdbc/org/postgresql/jdbc2/ResultSetMetaData.java

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -414,10 +414,7 @@ public boolean isReadOnly(int column) throws SQLException
414414
*/
415415
publicbooleanisWritable(intcolumn)throwsSQLException
416416
{
417-
if (isReadOnly(column))
418-
returntrue;
419-
else
420-
returnfalse;
417+
return !isReadOnly(column);
421418
}
422419

423420
/**

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp