Error:Class java.util.date not found

i have installed 9iAS on my computer.And i want to develop program on JSP.i tried the url below
http://eyuksel/servlet/IsItWorking
and i got "it is working" message.when i try to execute my first jsp file i get the error:
Errors compiling:d:\ias\apache\apache\htdocs\_pages\\_first.java
d:\ias\apache\apache\htdocs\_pages\_first.java:55: Class java.util.date not found.
out.print( new java.util.date() );
^
1 error
what must i do or how can i install the java classes.
kind regards...
null

Thank you very much.It worked:)
Java is case-sensitive.
try
java.util.Date
instead of
java.util.date
null

Similar Messages

  • Error: Class java.util.ArrayList not found in import

    Bear with me, I'm learning. That's part of the problem.
    I'm trying to teach myself JSP using a book based on Tomcat, but running it on an Oracle 9iAS server that I don't control. (The DBAs do that.) I'm running into constant problems compiling and using classes and such, I think because of the different directory structures on the two servers. (See subject error.)
    So, what I'd like to know is: how do I set up a default/main/whatever-you-want-to-call-it directory under which I can store my practice applications, such that 9iAS will function correctly? We're not using OC4J as far as I can see (no such directory, though there is a J2EE_containers folder), just JServ. Or, conversely, can someone explain in simple terms the basic 9iAS directory structures for deploying apps on 9iAS? I've been 'round and 'round the Oracle documentation until my head spins, and can't find this basic information.
    Help, please!!

    You will have to make Kawa to use the correct jdk
    Look into
    Options-> Directory
    Make a new Profile if it point to your old jdk version
    Thanks
    Joey

  • When compiling I get msg: Class java.io.* not found in import.

    import java.io.InputStreamReader;
    import java.io.BufferedReader;
    import java.io.IOException;
    public class CheckNumber {
    //program that checks the input buffer has valid integer value
         public static void main(String[] args) {
              String inLine = null;
              int checkInteger = 0;
              try {
              BufferedReader inStream = new BufferedReader (new InputStreamReader(System.in) );
              System.out.print("Enter a valid Integer and hit <ENTER>: ");
              inLine = inStream.readLine();
              checkInteger = Integer.parseInt(inLine);
              } catch (NumberFormatException nfe) {
              System.out.println("You did not enter a valid Integer: " + nfe);
              return;
              } catch (IOException e) {
              System.out.println("IOException: " + e);
              return;
              System.out.println("You entered a valid Integer: " + checkInteger);
    Compiling produced the following output:
    C:\jdk\work1>javac CheckNumber.java
    CheckNumber.java:1: Class java.io.InputStreamReader not found in import.
    import java.io.InputStreamReader;
    ^
    CheckNumber.java:2: Class java.io.BufferedReader not found in import.
    import java.io.BufferedReader;
    ^
    CheckNumber.java:12: Class java.io.BufferedReader not found in type declaration.
    BufferedReader inStream = new BufferedReader (new InputStreamReader(System.in) );
    ^
    CheckNumber.java:12: Class java.io.InputStreamReader not found in new.
    BufferedReader inStream = new BufferedReader (new InputStreamReader(System.in) );
    ^
    CheckNumber.java:15: Class java.io.BufferedReader not found in void main(java.lang.String[]).
    inLine = inStream.readLine();
    ^
    CheckNumber.java:21: Exception java.io.IOException is never thrown in the body of the corresponding try statement.
    } catch (IOException e) {
    ^
    6 errors

    I recently did a standard installation of jdk 1.5.
    This is the first time I am trying import.
    I set the path:
    set path=c:\jdk\bin
    Hmm...
    C:\jdk\bin>java -version
    java version "1.5.0_15"
    Java(TM) 2 Runtime Environment, Standard Edition (build 1.5.0_15-b04)
    Java HotSpot(TM) Client VM (build 1.5.0_15-b04, mixed mode, sharing)
    C:\jdk\bin>javac -J-version
    'javac' is not recognized as an internal or external command,
    operable program or batch file.
    There's no javac.exe file.
    I have javaw.exe and java.exe.

  • Source file for java.util.Vector not found ?

    Hi !
    In the Source Editor, hold down the Ctrl key and move the mouse over a class identifier belonging to the NetBeans APIs. A hyperlink appears. Click on the hyperlink and the cursor jumps to the related NetBeans API class.
    (Alt--O)
    Can anybody tell me, why this doesn't work in an Mobile Application ?
    thanks.
    (Show JavaDoc (Alt-F1) doesn't work in Mobile and EE ??)

    do you link javaee and javame sources with Netbeans?
    (you should ask it on a NetBeans forum??)

  • Java.util.Date badly serialized to java.sql.Timestamp Coherence 3.5.2

    Hi all,
    I'm running into this odd behaviour.
    I serialize java.util.Date objects to cache and when I read them back from cache, they appear to be java.sql.Timestamp types.
    I've isolated a junit test for that.
    Do you know why Coherence changes the type in the middle?
    Regards
    Harry.
    import java.util.Date;
    import org.junit.Assert;
    import org.junit.Test;
    import com.tangosol.io.Serializer;
    import com.tangosol.io.pof.ConfigurablePofContext;
    import com.tangosol.util.ExternalizableHelper;
    public class DatePofSerialTest {
         @Test
         public void testCobdate() throws Exception {
              Date date=new Date();
              Serializer serial = new ConfigurablePofContext();//"coherence-pof-config.xml");
              Date date2=(Date)ExternalizableHelper.fromBinary(ExternalizableHelper.toBinary(date, serial), serial);
              System.out.println(serial +" -- Date to serailize ["+ date.getClass() + "]");
              System.out.println(serial +" -- Date from deserialize ["+ date2.getClass() + "]");
              Assert.assertEquals(date, date2);/* Of course this passes, as both refer to the same time (long)*/
    {code}
    This gives as output
    {code:title=output |borderStyle=solid}
    log4j:WARN No appenders could be found for logger (Coherence).
    log4j:WARN Please initialize the log4j system properly.
    com.tangosol.io.pof.ConfigurablePofContext {location=coherence-pof-config.xml} -- Date to serailize [class java.util.Date]
    com.tangosol.io.pof.ConfigurablePofContext {location=coherence-pof-config.xml} -- Date from deserialize [class java.sql.Timestamp]
    {code}                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       

    Hi Harry,
    It looks like the same issue as ...
    PofExtractor with java.util.Date results in ClassCastException
    It was fixed in version 3.5.4.
    Thanks

  • OMWB under Linux redhat AS 3 : Java 1.4 not found

    Hi,
    I have already used the oracle migration workbench under Windows with a total sucess.
    But passing to Linux Redhat AS 3; Trying to launch the migration workbench by the ./omwb.sh ... the stressing error follows :
    Java 1.4 not found. Java 1.4 requiered
    I installed the j2re and j2sdk rpms without any changes
    please help ! thinks

    Hello All,
    I solved the problem by executing the following commands :
    $ java -version
    ... placeholder message ...
    $ su -
    # alternatives --remove java /usr/share/java/libgcj-java-placeholder.sh
    # alternatives --remove javac /usr/share/java/libgcj-javac-placeholder.sh
    # alternatives --remove jar /usr/bin/fastjar
    # alternatives --remove jar.1.gz /usr/share/man/man1/fastjar.1.gz
    # cd /usr/bin
    # ln -s /usr/java/jre1.5.0/bin/java java
    ... also set the links for javac etc ...
    # exit
    $ java -version
    java version "1.5.0"
    Java(TM) 2 Runtime Environment, Standard Edition (build 1.5.0-b64)
    Java HotSpot(TM) Client VM (build 1.5.0-b64, mixed mode, sharing)
    $
    Procedure of JDK is similar to J2RE...
    It seems that it wasn't a difficult problem
    sorry and thinks
    Tchao

  • Error(23,19): method getName(java.lang.String) not found in class javax.swi

    Hi , when i try to run my program, i keep getting the error msg:
    Error(23,19): method getName(java.lang.String) not found in class javax.swing.JTextField
    I have checked the java API and it inherits from the awt.Component class and should be accessible via the jtextfield.
    I have tried the following:
    trying to initailise the JTextField at the start.
    Using getName works if i use it within the loop after setting the name.
    Does anybody know what i am doing wrong please?
    public class clsMember extends JPanel implements ActionListener {
        private JButton jbtnLog;
        private String surname;
        private JTextField txtItem;
        public clsMember() {
            super(new SpringLayout());
            makeInterface();
            surname = txtItem.getName("Surname").toString();
    private void makeInterface() {
         //code omitted
               for (int i = 0; i < numpairs; i++) {
                JLabel l = new JLabel(strLabels, JLabel.LEADING);
    this.add(l);
    //if the array item is salutation create a combobox
    if (strLabels[i] == "Salutation") {
    jcomSalutation = new JComboBox(strSalutation);
    jcomSalutation.setSelectedIndex(0);
    this.add(jcomSalutation);
    } else {
    txtItem = new JTextField(10);
    l.setLabelFor(txtItem);
    txtItem.setName(strLabels[i].replaceAll(" ", "")); //this is where the label is set and if i do a system.out it shows fine. getName works here too.
    this.add(txtItem);
    //code omitted

    If i have a loop that creates the jtextfields such as
                    txtItem = new JTextField(10);
                    l.setLabelFor(txtItem);
                    txtItem.setName(strLabels.replaceAll(" ", ""));
    this.add(txtItem);How is it then possible to assign to a string the value of a *specific jtextfield*. Lets say that one of these JTextfields has the name surname.
    How is it possible for me to writeString surname = surnamejtextfield.getText();                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               

  • Error while deploying a web service whose return type is java.util.Date

    Hi
    I have written a simple web service which takes in a date input (java.util.Date) and returns the same date back to the client.
    public interface Ping extends Remote
    * A simple method that pings the server to test the webservice.
    * It sends a datetime to the server which returns the datetime.
    * @param pingDateRequest A datetime sent to the server
    * @returns The original datetime
    public Date ping(Date pingDateRequest) throws RemoteException;
    The generation of the Web service related files goes smoothly in JDeveloper 10g. The problem arises when I try to deploy this web service on the Oracle 10g (10.0.3) OC4J standalone. it gives me the following error on the OC4J console :
    E:\Oracle\oc4j1003\j2ee\home\application-deployments\Sachin-TradingEngineWS-WS\
    WebServices\com\sachin\tradeengine\ws\Ping_Tie.java:57: ping(java.util.Date) in com.sachin.tradeengine.ws.Ping cannot be applied to (java.util.Calendar) _result  = ((com.sachin.tradeengine.ws.Ping) getTarget()).ping
    (myPing_Type.getDate_1());
    ^
    1 error
    04/03/23 17:17:35 Notification ==&gt; Application Deployer for Sachin-TradingEngineWS-WS FAILED: java.lang.InstantiationException: Error compiling :E:\Oracle\oc4j1003\j2ee\home\applications\Sachin-TradingEngineWS-WS\WebServices: Syntax error in source [ 2004-03-23T17:17:35.937GMT+05:30 ]
    I read somewhere that the conversion between java to xml datatype and vice versa fails for java.util.Date, so it is better to use java.util.Calendar. When I change the code to return a java.util.Calendar then the JDeveloper prompts me the following failure:
    Method Ping: the following parameter types do not have an XML Schema mapping and/or serializer specified : java.util.Calendar.
    This forces me to return a String data.
    I would appreciate if someone can help me out.
    Thanks
    Sachin Mathias
    Datamatics Ltd.

    Hi
    I got the web service working with some work around. But I am not sure it this approach would be right and good.
    I started altogether afresh. I did the following step :
    1. Created an Interface (Ping.java) for use in web Service as follows :
    public interface Ping extends Remote{
    public java.util.Date ping(java.util.Date pingDateRequest)
    throws RemoteException;
    2. Implemented the above interface in PingImpl.java as follows :
    public class PingImpl implements Ping
    public java.util.Date ping(java.util.Date pingDateRequest) throws RemoteException {
    System.out.println("PingImpl: ping() return datetime = " + pingDateRequest.toString());
    return pingDateRequest;
    3. Compiled the above 2 java files.
    4. Generated a Stateless Java Web Service with the help of JDeveloper. This time the generation was sucessful.(If I had "java.util.Calendar" in place of "java.util.Date" in the java code of the above mentioned files the web service generation would prompt me for error)
    5. After the generation of Web Service, I made modification to the Ping interface and its implementing class. In both the files I replaced "java.util.Date" with "java.util.Calendar". The modified java will look as follows :
    Ping.Java
    =========
    public interface Ping extends Remote{
    public java.util.Calendar ping(java.util.Calendar pingDateRequest)
    throws RemoteException;
    PingImpl.Java
    ================
    public class PingImpl implements Ping
    public java.util.Calendar ping(java.util.Calendar pingDateRequest) throws RemoteException {
    System.out.println("PingImpl: ping() return datetime = " + pingDateRequest.toString());
    return pingDateRequest;
    6. Now I recompile both the java files.
    7. Withour regenerating the Web Service I deploy the Web Service on OC4j 10.0.3 from JDeveloper. This time the deployment was sucessful.(The Deployment fails if I don't follow the step 5.)
    8. Now I generated a Stub from JDeveloper and accessed the stub from a client. It works fine. Here if you see the Stub code it takes java.util.Date as a parameter and returns a java.util.Date. (Mind you I am accepting a java.util.Calendar and returning the same in my Web Service interface. Step 5)
    The confusing thing is the Serialization and Deserialization of Data from Client java data to Soap message and Soap message to Server java data.
    From Client to SOAP :
    java.util.Date to datetime
    From SOAP to Server :
    datetime to java.util.Calendar
    From Server to SOAP :
    java.util.Calendar to datetime
    From SOAP to Client :
    datetime to java.util.Date (I am not able to understand this part of the conversion)
    Any help or inputs would be appreciated.
    Thanks
    Sachin Mathias

  • Getting error by ValueBinding with java.util.Date

    Hi.
    1. my english is not so good.
    I develop a JSF-application to learn more about JSF-technologie.
    I use Eclipse 3.2
    Plugins: Web Tools Platform (WTP), Web Standard Tools, Java Server Faces // Version 1.5.0
    JRE: 1.5
    java-impl.jar and java-api.jar (sun)
    Look at this JSP-File Code
    <h:inputText id="dbirth" value="#{dataBean.dbrith}"> </h:inputText>
    this produce an error: EL expression does not evaluate to expected types for this attribute
    dataBean is a ManagedBeain. So if I use any athor variable from this Bean like:
    <h:inputText id="sname" value="#{dataBean.sname}"> </h:inputText>
    is going well. But if I use any java.util.Date variable it produce the error.
    I tried with other Bean and the error is still there.
    I can compile and use this JSP, but this error is there.
    Have any one an idea what is happen there??
    I looked at Eclipse forums, but I didnt found description for an error like this..
    thanks for any help...
    naba
    Message was edited by:
    NamboTango

    The problem is because you have bound the inputText to a java.util.Date object, instead of a String. You must use Strings with inputText. However, JSF has provided a way for you to convert objects into a String. It just needs to know how to do that. Luckily for you, there is a converter already available to convert a Date object into a String. Converters will also take input Strings and convert them into an object.
    So, in your case, use the convertDateTime tag. Like this:
    <h:inputText id="dbirth" value=#{dataBean.dbrith}">
         <f:convertDateTime type="date" pattern="MMM dd, yyyy" />
    </h:outputText>Try it. You may change the pattern to whichever valid one you like.
    CowKing

  • Why not Deprecate java.util.Date and java.util.Calendar

    With the introduction of java.time, why did you not flag java.util.Date and java.util.Calendar. These classes have been a bane to every Java developer and should never be used again with the introduction of Java 1.8.

    Adding the @Deprecated annotation would only just provide a warning about an old API and recommendation to the developer(s) to no longer use it. Doing so would not break any existing library out there; in fact quite a number of constructors and methods on the Date class have already been flagged deprecated.
    The new java.time package is far superior to Date/Calendar.

  • How To Add Days into a Date from java.util.Date class

    I have a problem when i wants to add 2 or days into a
    date object geting by java.util.Date class. so please help me resolve this issue?
    for e.g i have a date object having 30/06/2001,
    by adding 2 days i want 02/07/2001 date object ?
    Code
    public class test2
    public static void main(String args[])
    java.util.Date postDate = new java.util.Date();
    myNewDate = postDate /* ?*/;
    Here i want to add 2 date into postDate

    Use Calendar...
    Calendar cal = Calendar.getInstance();
    cal.setTime(new Date());
    cal.add(Calendar.DAY, 2); // I'm not sure about that "DAY"

  • Java.sql.Date and java.util.Date - class loaded first in the classpath

    I had two jar files which has java.util.Date and java.sql.Date class file. i want to know whether which class is loaded first in the classpath...
    I like to change the order of loading the class at runtime...
    Is there is any way to change the order of loading of class...
    I may have different version of jar files for example xerces,xercesImpl. some of the code uses xerces ,some of the code uses xercesImpl..i had common classes.
    I like to load the class with the same name according to the order i need..
    Can we do all these in Run time ?????

    I had two jar files which has java.util.Date and
    java.sql.Date class file. i want to know whether
    which class is loaded first in the classpath...
    I like to change the order of loading the class at
    runtime...
    Is there is any way to change the order of loading of
    class...
    I may have different version of jar files for example
    xerces,xercesImpl. some of the code uses xerces ,some
    of the code uses xercesImpl..i had common classes.
    I like to load the class with the same name according
    to the order i need..
    Can we do all these in Run time ?????That is meaningless.
    The classes you are referring to are part of the Java API. Third party jars have no impact on that. And you can't change to the order because java.sql.Data is derived from java.util.Date. So the second must load before the first.
    And if you have two jar files with those classes in them (and not classes that use them) then you either should already know how to use them or you should stop trying to do whatever you are doing because it isn't going to work.

  • Internal error: data not found message

    Every time I try to upload pics I get this message:
    internal error: data not found
    How can I fix this problem? Thank you so much, Stacey

    Please explain in detail about the process you are trying to perform...Do tell if any settings or any change in preferences you have made. How many files you rae trying to upload. Your account is not expired and you are admin etc.
    -Garry

  • Error - Data not found

    I experience error - data not found when i click on the custom 'Next' button on the page of my application, whereas, there are records in the table of the database. How can this be resolved?
    Thank you.

    User,
    What is your name?
    Can you put an example on apex.oracle.com and provide the workspace/username/password?
    Regards,
    Dan
    http://danielmcghan.us
    http://sourceforge.net/projects/tapigen
    http://sourceforge.net/projects/plrecur
    You can reward this reply by marking it as either Helpful or Correct ;-)

  • MyApplet.java:2: Class netscape.javascript.JSObject not found in import.

    Hi,
    Im getting: MyApplet.java:2: Class netscape.javascript.JSObject not found in import.
    import netscape.javascript.JSObject;
    Where can i get this package. Someone said jaws.jar, but its not to be found. Im new on this project and I dont know how the old people compiled this applet.
    JDK version is:
    Solaris VM (build Solaris_JDK_1.2.2_10, native threads, sunwjit)
    Thanks

    Thanks man!
    I installed the jdk1.4 on my workstation. I then compiled the program via JDeveloper and pumped the class over to my server.
    Thanks again.

Maybe you are looking for

  • LOTS of issues with Fascinate...worst phone ever

    I got this phone as the BOGO when my sister bought her Incredible 33 days ago, I previously had a Motorola Droid...big mistake on this "upgrade". I've had problems with it from day one. On day one I was unable to make or receive phone calls until aft

  • HP Laser printer 3020

    My printer HP 3020 (Print,Scan, Copy), which is 8 year old developed a problem recently.When the printer is switched ON, as part of self test / initialising, the motor starts running for few seconds as usual. But afterwards, nothing. the display is n

  • Problem (bug?) in report - sort

    I receive this error: failed to parse SQL query: ORA-06502: PL/SQL: numeric or value error: NULL index table key value I know where this comes from, but I don't know how to solve it (the first time). Below how you can reproduce my error. Test-case: 1

  • Synch Current Messages and Calls

    I Synched  my iPhone 5s to a 4s backup but my current messages and phone are not updated. Please help

  • Illustrator CS4 and Snow Leopard

    Does Illustrator CS 4 work well with Snow Leopard? Richard