MyEclipse Forums
Post new topic   Reply to topic
View previous topic Printable version Log in to check your private messages View next topic
Author Message
bkearns
Post subject: Oracle Edit Table Data 3.8.3GA  PostPosted: Dec 15, 2004 - 04:10 PM
Registered Member
Registered Member


Joined: Dec 14, 2004
Posts: 12

Great work on the tool you guys have developed, I have begun to get dependant on it :), however I now appear to have a problem.

After installing MyEclipse 3.8.3 GA, I'm having a problem editing data in an Oracle 9.2.0.5 database that I wasn't having before on 3.8.2. The following is the error message:

!ENTRY com.genuitec.eclipse.sqlexplorer 4 4 Dec 15, 2004 10:45:04.491
!MESSAGE Error opening edit dialog
!STACK 0
java.sql.SQLException: Invalid scale size. Cannot be less than zero
at javax.sql.rowset.RowSetMetaDataImpl.setScale(Unknown Source)
at com.sun.rowset.JdbcRowSetImpl.initMetaData(Unknown Source)
at com.sun.rowset.JdbcRowSetImpl.<init>(Unknown Source)
at com.genuitec.eclipse.sqlexplorer.actions.directedit.EditorDialog.getRowSet(Unknown Source)
at com.genuitec.eclipse.sqlexplorer.actions.directedit.EditorDialog$1.run(Unknown Source)

The table definition is as follows:

create table USERREG(
USERS_ID NUMBER(22) PRIMARY KEY not null,
STATUS NUMBER(22),
PLCYACCT_ID NUMBER(22),
LOGONID VARCHAR2(254) not null,
LOGONPASSWORD RAW,
PASSWORDEXPIRED NUMBER(22),
CHALLENGEQUESTION VARCHAR2(254),
CHALLENGEANSWER VARCHAR2(254),
TIMEOUT NUMBER(22) default -1 not null,
PASSWORDRETRIES NUMBER(22) default 0 ,
SALT VARCHAR2(254),
PASSWORDCREATION DATE,
PASSWORDINVALID DATE)

I am connecting with the Oracle thin driver to a remote database. I can see all the tables and the explorer view shows the columns correctly. It appears that I can edit other tables in this same database. For example I can edit:

create table ACACGPDESC(
ACACTGRP_ID NUMBER(22) not null,
DISPLAYNAME VARCHAR2(254) not null,
DESCRIPTION VARCHAR2(254),
LANGUAGE_ID NUMBER(22) not null)

So I suspect this may have something to do with the RAW column. Is there any way to get to work again?
 
 View user's profile Send private message  
Reply with quote Back to top
support-rkalla
Post subject:   PostPosted: Dec 15, 2004 - 04:47 PM
Registered Member
Registered Member


Joined: Jan 06, 2004
Posts: 23824

Quote:
Great work on the tool you guys have developed, I have begun to get dependant on it :)

Glad you like them, we are really pushing hard for good tool support.

Quote:
So I suspect this may have something to do with the RAW column. Is there any way to get to work again?

I will check with the dev that worked on that module, hang on.

_________________
Riyad
MyEclipse Support
 
 View user's profile Send private message Visit poster's website  
Reply with quote Back to top
support-jeff
Post subject:   PostPosted: Dec 16, 2004 - 02:23 AM
Moderator
Moderator


Joined: Jul 18, 2004
Posts: 357

Problem is that the part of the code involved in creating the RowSet from a ResultSet (and obtaining the ResultSet in the first place) did not change. The only change that occurred was that a call to ResultSet.setMaxRows() was made conditional. Perhaps this is the problem. Tell me, do you have the "Disable Row Limit on SQL Execution" option selected in the Database Explorer preferences? Retry the direct edit after disabling this pref and setting a value for the limit. Does it now work properly? Let me know.

_________________
jeff
MyEclipse Support
 
 View user's profile Send private message  
Reply with quote Back to top
bkearns
Post subject:   PostPosted: Dec 16, 2004 - 06:55 PM
Registered Member
Registered Member


Joined: Dec 14, 2004
Posts: 12

That didn't seem to work. I'm still getting that error unfortunately. Any other tricks?
 
 View user's profile Send private message  
Reply with quote Back to top
support-jeff
Post subject:   PostPosted: Dec 17, 2004 - 12:06 AM
Moderator
Moderator


Joined: Jul 18, 2004
Posts: 357

Darn. Was hoping that was it. Have you tried going back to 3.8.2 (just reinstall a fresh version) and retry?

I tried to create a table in an Oracle 9i test database to test with myself, and I cannot use the RAW type in the way you describe in DDL. I tried:

create table USERREG(
USERS_ID NUMBER(22) PRIMARY KEY not null,
LOGONPASSWORD RAW
);

But I get complaints that RAW requires a precision number (or some argument in parentheses) be supplied. Am I missing something?

_________________
jeff
MyEclipse Support
 
 View user's profile Send private message  
Reply with quote Back to top
snpe
Post subject:   PostPosted: Dec 17, 2004 - 02:29 AM
Quality Board
Quality Board


Joined: Jul 05, 2003
Posts: 544

Have you last oracle jdbc driver - oracle have buggy drivers and last is fine
I think that bugy driver return error like your

regards
 
 View user's profile Send private message  
Reply with quote Back to top
bkearns
Post subject:   PostPosted: Dec 17, 2004 - 03:44 PM
Registered Member
Registered Member


Joined: Dec 14, 2004
Posts: 12

The table create script isn't actually a script I used to generate the table, but one that I got by hitting <create table script> in MyEclipse. Unfortunately this is a WebSphere Commerce Table and I don't have the original schema create script handy. Since you mention that the table create fails due to a missing precision, I wonder if that is the scaling error that is causing the error.

The driver version that I have is the one that came with this version of Oracle in the jdbc directory. We're using 9.2.0.5, with security patches, so it should be a reasonably current release of the driver. Since editing worked on this table (with this driver) in 3.8.2 I suspect the root cause is potentially something other than the driver.

Thanks for all the help.
 
 View user's profile Send private message  
Reply with quote Back to top
snpe
Post subject:   PostPosted: Dec 17, 2004 - 04:06 PM
Quality Board
Quality Board


Joined: Jul 05, 2003
Posts: 544

I try this from sqlplus (without me)
create table USERREG(
USERS_ID NUMBER(22) PRIMARY KEY not null,
LOGONPASSWORD RAW
);

and get
ORA-00906: missing left parenthesis

It is not problem with me - you have to add length for raw
 
 View user's profile Send private message  
Reply with quote Back to top
bkearns
Post subject:   PostPosted: Dec 17, 2004 - 04:43 PM
Registered Member
Registered Member


Joined: Dec 14, 2004
Posts: 12

So after modifying the RAW type to be RAW(2000) in the create table script, and a SELECT INTO this newly created table from the original and edit the table as before. However selecting <create table script> still shows this field as a RAW with no length.

Additionally I think I've found the correct create table script.

CREATE TABLE userregtt (
users_id NUMBER NOT NULL,
status INTEGER NULL,
plcyacct_id INTEGER NULL,
logonid VARCHAR2(254) NOT NULL,
logonpassword RAW(128) NULL,
passwordexpired INTEGER NULL,
challengequestion VARCHAR2(254) NULL,
challengeanswer VARCHAR2(254) NULL,
timeout NUMBER DEFAULT -1 NOT NULL,
passwordretries INTEGER DEFAULT 0 NULL,
salt VARCHAR2(254) NULL,
passwordcreation DATE NULL,
passwordinvalid DATE NULL
);

This one should work and appears to cause the problem to appear.
 
 View user's profile Send private message  
Reply with quote Back to top
snpe
Post subject:   PostPosted: Dec 17, 2004 - 05:15 PM
Quality Board
Quality Board


Joined: Jul 05, 2003
Posts: 544

Hello,
oracle have nestandard jdbc api for type (for instance date is date and time , Timestamp) etc
and it is problem with create script.Me database tool have to with different database and don't work with any oracle specific behavior.
Maybe , myeclipse team resolve this in next version, but it don't work in 3.8.2 too

regards
 
 View user's profile Send private message  
Reply with quote Back to top
Display posts from previous:     
Jump to:  
All times are GMT - 6 Hours
Post new topic   Reply to topic
View previous topic Printable version Log in to check your private messages View next topic
Powered by PNphpBB2 © 2003-2004 The PNphpBB Group
Credits