Win a copy of The Java Performance Companion this week in the Performance forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Class Problem...

 
Scott Batchelor
Greenhorn
Posts: 11
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am trying to do this:
JDBCHelper.delimitSingleQuote(cas_priv_nm) +
" and " + getTableAlias() + ".stu_seq_nbr = " + stu_seq_nbr, conn);
But I keep getting this strange error saying:
The method delimitSingleQuote(String) from the type JDBCHelper is not static.
I am unsure of what to do to fix this.
I am using JDK 1.4.2_01
Thanks in advance.
 
Wayne L Johnson
Ranch Hand
Posts: 399
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Only a guess, but you are calling the method "delimitSingleQuote(...)" using the Class name (JDBCHelper). The error message seems to imply that in the class (JDBCHelper) the method "delimitSingleQuote(String)" is not declared as "static".
You either need to declare the "delimitSingleQuote" method as "static" so you can invoke it using only the class name, or you need to create an instance of "JDBCHelper" and call the method using the instance.
[ October 08, 2003: Message edited by: Wayne L Johnson ]
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic