This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 178262

Summary: Entity Classes from Database wizard, Step 2: Available Tables not displayed
Product: db Reporter: Troy Giunipero <tgiunipero>
Component: DB schemaAssignee: Jiri Rechtacek <jrechtacek>
Status: RESOLVED WORKSFORME    
Severity: normal    
Priority: P3    
Version: 6.x   
Hardware: All   
OS: All   
Issue Type: DEFECT Exception Reporter:

Description Troy Giunipero 2009-12-07 11:39:48 UTC
NetBeans IDE 6.8 (Build 200912041610)

Entity Classes from Database wizard does not recognize tables from JavaDB script.

To reproduce:

1. Create a new 'consult' database using the JavaDB server.
2. Run the derby_create_consult_v2.sql script found in:

   http://kenai.com/projects/consultingagencysol/downloads/download/base/derby-consult.zip

3. Open the Entity Classes from Database wizard.

4. Create a new datasource and name it 'jdbc/consult'.

5. Select the 'jdbc:derby://localhost:1527/consult' connection.

The wizard attempts to read in the tables, but fails.
Comment 1 Sergey Petrov 2009-12-07 12:08:33 UTC
Is there any exceptions?
Can you create database schema from this connection? (Persistence|Database Schema wizard)
Comment 2 Troy Giunipero 2009-12-07 13:03:00 UTC
| Is there any exceptions?

No.

| Can you create database schema from this connection? (Persistence|Database
Schema wizard)

No.
Comment 3 Sergey Petrov 2009-12-08 00:38:59 UTC
thanks, need to be evaluated on schema generation side first as entity from db use schema generation.
Comment 4 Jiri Rechtacek 2010-02-12 09:26:39 UTC
I can confirm the steps leads to unavailability to create Entity Classes from Consult Database, cause: user who creates the Consult database has other name than consult, it means has another default schema than consult. A easy workaround (should be documented in the tutorial) is: change point 1)
Create a new 'consult' database using the JavaDB server => Create a new 'consult' database using 'consult' username and whatever password. Then it works for me.
I'm lowering the priority and I'll file new issue about heart of problem, allow to read tables from other schema then is the user's default.
For NB6.8, NB6.9M1 I recommend use the note workaround. If I'm wrong, let me know. Thanks
Comment 5 Jiri Rechtacek 2010-04-13 13:31:06 UTC
Conclusion: The script in the tutorial removes creating an another schema then user name in database consult.