aspose file tools
The moose likes Beginning Java and the fly likes Class Problem... Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of RabbitMQ in Depth this week in the Open Source forum!
JavaRanch » Java Forums » Java » Beginning Java
Bookmark "Class Problem..." Watch "Class Problem..." New topic

Class Problem...

Scott Batchelor

Joined: Jul 07, 2003
Posts: 11
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

Joined: Sep 03, 2003
Posts: 399
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 ]
I agree. Here's the link:
subject: Class Problem...