Categories

JAVA DATEBASE
Technology Network Community
Oracle Database
Fusion Middleware
Development Tools
Java
Desktop
Server & Storage Systems
Enterprise Management
Berkeley DB Family
Cloud Computing
Big Data
Business Intelligence
Architecture
Migration and Modernization
E-Business Suite
Siebel
PeopleSoft Enterprise
JD Edwards World
Industries
JD Edwards EnterpriseOne
User Productivity Kit Pro (UPK) and Tutor
Governance, Risk & Compliance (GRC)
Master Data Management (MDM)
Oracle CRM On Demand
On Demand: SaaS and Managed Applications
AutoVue Enterprise Visualization
Primavera
ATG
Agile PLM
Endeca Experience Management
Fusion Applications
Archived Forums

 



Tags

New To Java


java compilation error "package org.apache.lucene.store" does not exist


package djvusearching;  import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader;  import org.apache.lucene.analysis.cjk.CJKAnalyzer; //import org.apache.lucene.analysis.standard.StandardAnalyzer; import org.apache.lucene.queryParser.ParseException; import org.apache.lucene.queryParser.QueryParser; import org.apache.lucene.search.Hits; import org.apache.lucene.search.IndexSearcher; import org.apache.lucene.search.Query; import org.apache.lucene.search.Sort; import org.apache.lucene.search.SortField; import org.apache.lucene.store.Directory; import org.apache.lucene.store.FSDirectory;  i used to get the compilation error "package org.apache.lucene.store" does not exist since my java file can only have one package which i have included i.e. "djvusearching".   can anyone help me out please??//.

Did u set the CLASSPATH.  if not set the class path.... (Set the classpath to the parent folder where your source file is available)

package djvusearching;  import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader;  import org.apache.lucene.analysis.cjk.CJKAnalyzer; import org.apache.lucene.search.Hits; import org.apache.lucene.store.Directory; import org.apache.lucene.store.FSDirectory;  i used to get the compilation error "package org.apache.lucene.store" does not exist since my java file can only have one package which i have included i.e. "djvusearching".  That's not quite correct. The given error has nothing to do with your file "having only one package". And you do not import package djvusearching; you're declaring a class to reside in said package so you do not need to import it, nor do you.  The reason you get the error for "org.apache.lucene.store" is that you haven't told the compiler where to find the classes inside it. Does it find the other apache-lucene classes, or do you get the same error for all of them?  can anyone help me out please??// Sure, if you give us a hand. Tell us - how exactly you are calling javac (command line? IDE?) What if anything are you already passing as classpath? - what exactly and for which packages you get the error


Related Links

ear file, war file , and jar file.
how to change jvm memory heap using command line
How to load images and set a download directory for an online applet?
Build an XML file from a text file
What does this code mean?
My java program runs fine even if i don't specify access specifier of class
Could not find the main class.
A JTable Question?
Receiving infinity when running code.
java equivalent of ado components
Strange new issue
SET into string array using toArray()
What is going on?
jdbc connection problem
Access/Change Folder Permissions
Safari BETA on Windows