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 183478

Summary: Syntax checker treats single and double quotation marks different ways
Product: db Reporter: Michael Nazarov <michaelnazarov>
Component: SQL EditorAssignee: Jaroslav Havlin <jhavlin>
Status: RESOLVED FIXED    
Severity: normal Keywords: NETFIX
Priority: P3    
Version: 6.x   
Hardware: PC   
OS: Windows XP   
Issue Type: DEFECT Exception Reporter:
Attachments: screenshot
proposed patch v1

Description Michael Nazarov 2010-04-05 11:10:52 UTC
Created attachment 96675 [details]
screenshot

If one started string with ' sign then sql statement editor treats followed characters as error. If " sign in use -- there is no error.
Check screenshot to see difference.
Comment 1 matthias42 2012-07-12 19:49:10 UTC
Created attachment 121984 [details]
proposed patch v1

The attached patch does three changes (I think they are small enough to be reviewed together):

- Add support for SQL-99 Quoting including unit-tests
- If a partly quoted identifier is encountered at the 
  end of the SQL string it is highlighted as an error
  (like in the string case)
- Fix problem in method "isEndIdentifierQuoteChar" - 
  the start character has to be checked whether it is
  a valid begin quote character, if not the end can't
  be a valid end quote
Comment 2 Jaroslav Havlin 2012-08-16 12:16:20 UTC
Patch applied as http://hg.netbeans.org/core-main/rev/bef911152a8b

Thank you very much!
Comment 3 Quality Engineering 2012-08-18 01:35:18 UTC
Integrated into 'main-golden', will be available in build *201208180001* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)
Changeset: http://hg.netbeans.org/main-golden/rev/bef911152a8b
User: Jaroslav Havlin <jhavlin@netbeans.org>
Log: #183478: Syntax checker treats single and double quotation marks different ways