Nair Anoop

Ranch Hand
+ Follow
since May 09, 2001
Merit badge: grant badges
For More
Cows and Likes
Cows
Total received
In last 30 days
0
Forums and Threads

Recent posts by Nair Anoop

Hi,
So I would need to get the child node of the ELEMENT node and then do a getNodeValue() .. right ?
Is there a simpler way to read the information from the schema ... without crawling 2 levels deep in the nodes ?
Thanks,
Anoop
[This message has been edited by Nair Anoop (edited December 04, 2001).]
Hi,
I have a XML schema of the form:
<info>
<student id="1">
<fname>xyz</fname>
<lname>abc</lname>
</student>
</info>
I can read the "id" attribute correctly using the NamedNodeMap class but I am unable to read the fname and lname elements.
Any ideas why I keep getting blanks for the same ?

Thanks,
Anoop
Hi,
I am currrently using :
boolean status = rsInfo.getBoolean("status");
to access a boolean (Yes / No) field in an Access DB.
If I need to port this to Oracle, will I need to make the field as Number(1) and use
int status = rsInfo.getInt("status");
and thus change all my Java code
Thanks,
Anoop
Hi,
I am using JDBC to connect to an Access table. I have a simple table called:
Student (StudID, FName, LName, Marks)
I would like to find out the student with the highest marks:
SELECT StudID, max(Marks) AS maxMarks FROM Student GROUP by StudId
I get multiple rows returned whereas I need only the highest one.
I am facing a similar problem in other tables too. How can I get all the fields of only the highest row ?
Thanks in advance.
Anoop
Hi,
Is it necessary to use the to_date function in the SQL query, or can I just use a ? in the preparedStatement and then allow the Oracle JDBC driver to take care of the rest.
Thanks,
Anoop
Hi,
I am using JAXP 1.0.1 and 2 jar files: jaxp.jar and parser.jar. But when I try to use the TransformerFactory and other similar classes, they give a compiler error.
I am unable to find the latest versions of the above ajr files. Could someone help me find the new version for the same ?
Thanks in advance,
Anoop
Hi Vanitha,
Actually what I was looking for is the create table statement since I do not know the different DateTime fields available in Oracle.
Thanks once again,
Anoop
Hi,
I am using OracleDB for the first time. Could someone help me with the appropriate DateTIme fields available in Oracle.
I would like to create a table Student(ID, Name, DateofBirth)
What will be the corresponding CREATE TABLE statement for the above. I would preferabley like the DateofBirth field to hold both the date as well as time.
Thanks in advance,
Anoop
Thanks David for the code snippet. And no, it wasn't for school HW .. but for a project I'm working on.
~Anoop
Jamie,
Thank you very much for your help.
-Anoop
Hi,
Could someone please give me some code snippet / tips to create a XML DOM document for the following using the JAXP DocumentBuilder class:
<info>
<student id="1">
<fname>john</fname>
<lname>smith</lname>
<student>
</info>
Also, just as a tip, which of the following is a better design decision:
1. Putting studentID as an attribute
2. Putting studentID as an element
Thanks in advance,
Anoop
Thanks very much for the prompt response, David. Its exactly what I was looking for.
~Anoop
Hi,
I create a new XML DOM document using DocumentBuilderFactory How can I store this file on disk ?
Thanks in advance,
Anoop
Hi,
I am using JDBC to interact with an Oracle DB. I have fields of DateTime type in the DB. I need to write a few queries which require the hour or a particular month for a given date.
I know that MySQL has specific functions such as MONTH(Date) which gives the month from a quey and can be used directly in a sql statement.
Could some of you guys who have used Oracle tell me the corresponding functions in Oracle.
eg. I need a list of the number of customers who came in each hour. I have a DateTime field in the DB. Any help with this query ?
Thanks in advance,
Anoop
Thanks very much for the respose. I have go it to work now.
-Anoop
23 years ago