Problems with 8.1: indicating error

Howdy all!

I trying out IDEA, I downloaded the trial version and loaded up a bunch of Maven projects (through some initial difficulties ).
The code compiles ok and builds but in the editor window I get a bunch of errors that seems to be centered about this:

public static final void insertProductChoice() {

... <some code>
cstmt = conmgr.getConnection().prepareCall("{call insertProductChoice ?,?,?,?}");

I get a red marker on insertProductChoice in the prepareCall statement which is a call to a stored procedure.
The error text says 'unexpected 'insertProductChoice', '}' expected'.
Every prepareCall() are marked like this (with the name of the stored procedure marked as the problem).
The syntax coloring also marks it as a method call rather than a string.
This is clearly a configuration issue or a bug. Is there any way around it?
I've turned off the errors I could turn off on the error page of the preferences to no avail.
I would term this as a show stopper for us when it comes to using IDEA  :-)

cheers
Erik Svensson

2 comments
Comment actions Permalink

Hello Erik,

The syntax you describe is unfamiliar to me.

Here are the correct variants as described by JDBC docs

{call procedure_name[(?, ?, ...)]}
{? = call procedure_name[(?, ?, ...)]}
{call procedure_name}

http://java.sun.com/j2se/1.3/docs/guide/jdbc/getstart/callablestatement.html

Anyway SQL language injection into string literals can be switched off
in Settings/Language Injection.

Gregory Shrago


Erik Svensson wrote:

Howdy all!

I trying out IDEA, I downloaded the trial version and loaded up a
bunch of Maven projects (through some initial difficulties ). The
code compiles ok and builds but in the editor window I get a bunch of
errors that seems to be centered about this:

public static final void insertProductChoice() {

.. <some code> cstmt = conmgr.getConnection().prepareCall("{call
insertProductChoice ?,?,?,?}");

I get a red marker on insertProductChoice in the prepareCall
statement which is a call to a stored procedure. The error text says
'unexpected 'insertProductChoice', '}' expected'. Every prepareCall()
are marked like this (with the name of the stored procedure marked as
the problem). The syntax coloring also marks it as a method call
rather than a string. This is clearly a configuration issue or a bug.
Is there any way around it? I've turned off the errors I could turn
off on the error page of the preferences to no avail. I would term
this as a show stopper for us when it comes to using IDEA :)

cheers Erik Svensson

--- Original message URL:
http://www.jetbrains.net/devnet/message/5233657#5233657

0
Comment actions Permalink

Strange, never noticed that and it seems to work :-)
Anyway, turning off language injection worked. Thanx!

cheers
/Erik

Guest wrote:

Hello Erik,


The syntax you describe is unfamiliar to me.


Here are the correct variants as described by JDBC docs


{call procedure_name[(?, ?, ...)]}
{? = call procedure_name[(?, ?, ...)]}
{call procedure_name}


http://java.sun.com/j2se/1.3/docs/guide/jdbc/getstart/callablestatement.html


Anyway SQL language injection into string literals can be switched off
in Settings/Language Injection.


Gregory Shrago


Erik Svensson wrote:

Howdy all!


I trying out IDEA, I downloaded the trial version and loaded up a
bunch of Maven projects (through some initial difficulties ). The
code compiles ok and builds but in the editor window I get a bunch of
errors that seems to be centered about this:


public static final void insertProductChoice() {


.. <some code> cstmt = conmgr.getConnection().prepareCall("{call
insertProductChoice ?,?,?,?}");


I get a red marker on insertProductChoice in the prepareCall
statement which is a call to a stored procedure. The error text says
'unexpected 'insertProductChoice', '}' expected'. Every prepareCall()
are marked like this (with the name of the stored procedure marked as
the problem). The syntax coloring also marks it as a method call
rather than a string. This is clearly a configuration issue or a bug.
Is there any way around it? I've turned off the errors I could turn
off on the error page of the preferences to no avail. I would term
this as a show stopper for us when it comes to using IDEA  :)


cheers Erik Svensson


--- Original message URL:
http://www.jetbrains.net/devnet/message/5233657#5233657

0

Please sign in to leave a comment.