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 200368 - CC doesn't work when specifying an alternate DB
Summary: CC doesn't work when specifying an alternate DB
Status: RESOLVED FIXED
Alias: None
Product: db
Classification: Unclassified
Component: SQL Editor (show other bugs)
Version: 7.0.1
Hardware: All All
: P3 normal (vote)
Assignee: Jiri Rechtacek
URL:
Keywords: NETFIX, PATCH_AVAILABLE
Depends on:
Blocks:
 
Reported: 2011-07-25 16:55 UTC by athompson
Modified: 2013-07-03 02:29 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
proposed patch v1 (2.87 KB, patch)
2013-07-01 18:57 UTC, matthias42
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description athompson 2011-07-25 16:55:41 UTC
In SQL Server, you can explicitly reference tables in other DBs so long as the DB is in the same DBMS instance.  For example, if I wanted to reference the table "tblLoginLogs" in the "dbLogin" database, I could use the notation:

    dbLogin.dbo.tblLoginLogs

or if "dbo" is the default schema:

    dbLogin..tblLoginLogs

However, CC doesn't work anywhere after the "dbLogin." 


Product Version: NetBeans IDE Dev (Build 201107220600)
Java: 1.6.0_26; Java HotSpot(TM) 64-Bit Server VM 20.1-b02-383
System: Mac OS X version 10.7 running on x86_64; MacRoman; en_US (nb)
Userdir: /Users/alvin/.netbeans/dev
Comment 1 athompson 2012-05-16 18:05:06 UTC
yup
Comment 2 athompson 2012-05-16 18:05:48 UTC
(In reply to comment #1)
> yup

sorry, wrong bug.
Comment 3 matthias42 2013-07-01 18:57:59 UTC
Created attachment 136554 [details]
proposed patch v1

I checked with sqlserver 2005 driver and found, that I could get it to work if the attached change is applied to SQLCompletionQuery.java. I also added a testcase to verify the change (the other 120 test cases of course still work).

This will enable the first syntax, the second would need further work in the parser and would be db dependend.
Comment 4 Jaroslav Havlin 2013-07-02 09:03:05 UTC
Applied as http://hg.netbeans.org/core-main/rev/91ff947f40d9

Thank you, Matthias!
Comment 5 Quality Engineering 2013-07-03 02:29:46 UTC
Integrated into 'main-silver', will be available in build *201307022300* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)

Changeset: http://hg.netbeans.org/main-silver/rev/91ff947f40d9
User: Jaroslav Havlin <jhavlin@netbeans.org>
Log: #200368: CC doesn't work when specifying an alternate DB

Patch by Matthias42.