Andrew Nomos

Greenhorn
+ Follow
since May 31, 2005
Merit badge: grant badges
For More
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
0
Received in last 30 days
0
Total given
0
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by Andrew Nomos

Hi all,

what is the better aproach:



or



Thanks for advice!
[ July 27, 2006: Message edited by: Andrew Nomos ]
17 years ago
Hello,

in the JDBC API it is said that a ResultSet is an object that maintains a cursor pointing to its current row of data.
What does that mean in terms of memory?

For example, when I execute a database query that returns 500.000 records, the ResultSet will not acctually keep the 500.000 records, won't it? But what actually gets send to my machine?

Any comments are highly appreciated.

Thanks,
Andrew
Ok, I see I was mistaken.
But why does it compile properly when you put the two classes into the same package???
18 years ago
Answer B is correct!

Variable x is declared as public by default and therefore visible in class Test2.
The main() method is a static method and therefore it is no problem to access the static variable x.
18 years ago
did you setup an odbc data source?

Originally posted by G Sirish Reddy:
Hello,
Rcently i was encounter a problme what it is,
How can i connect MS Access from JDBC Program,iam using jdbc-odbc Driver and i select Odbcdriver for MS Access,can you guess what the problem is ?
one more thing my program is compiling fine but not getting any out put ?
Thanking you,
Regards,
G Sirish Reddy.,

Code:
....
...
...
ResultSet rs=stmt.executeQuery("Select * from [$emp]");
while(rs.next()){
S.o.p(rs.getInt(1));

Hi all,

I have two questions regarding java web applications:

- how do i set up a java web application to support SSL or any another type of
encryption?
- a security constraint is that the connection must cut off when the user
hasn't done anything for 15 minutes. what is the best way to realize this?

Any suggestions would be highly appreciated.

Thanks,
Andrew
18 years ago
A constructor is called during object instantiation and cannot be invoked explicitly.
A method represents object behaviour and can be invoked at any time.
18 years ago
You could store a HashMap in HTTP session with the name of the JSP as key and the name of the column as value.

----------------------------

The box said: Install Windows 98 or better. So I installed linux.
It's difficult to give you an anwser without knowing the exact circumstances you are facing.

Anyhow, I guess you should re-think your desing:
- can you separate the responsibilities of your root class so that problem will not arraise?
- can you introduce an additional layer to avoid it?
- perhaps you can use object composition instead of inheritance?
A marker interface is indeed a interface that contains no methods.

Why is this useful --> polymorphism
18 years ago
A java bean is a java class that adheres to some conventions:
1. members can only be accessed through getters and setters
2. must have a non-argument constructor
[ June 02, 2005: Message edited by: Andrew Nomos ]
18 years ago
What exactly is your difficulty: Getting the lowest score out of the array or displaying it in JOptionPane?
18 years ago
The compiler wants you to catch the exception in your test class because your store method contains 'throws InvalidRecord'.

If you want to handle the exception entirely in the store method you do not need the 'throws InvalidRecord' with your store method.
You only need to specify the throws statement if you do not want to handle the exception in your method but hand it up to the calling method.

By the way, it is a convention that exceptions end with Exception --> InvalidRecordException.
18 years ago
Perhaps a 'ServletContextListener' might work for you.
[ June 01, 2005: Message edited by: Andrew Nomos ]
18 years ago
The key point is not that the method getFoo() returns null but that it returns an instance of class Foo and since fubar is a static member it can be accessed.
18 years ago