Skip to Main Content

SQL & PL/SQL

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Multi-Rows from DUAL

Gerd VolbergApr 3 2007 — edited Nov 19 2010
I need an easy select from DUAL, which gives me more than one row.

e.g. 1000 rows or 4500 rows....


I know that one of the best solutions was something with an CONNECT BY PRIOR and a WHERE ROWNUM <= 1000 e.g.


But what was the complete statement?

thx 4 solutions
Gerd

Comments

unknown-7404
Answer

I have read and watched videos regarding creating an Object of a class and calling its method in a different class. I'm still confused about how to properly do this. Using the code below can anyone explain how to properly call the objects method from my main.

Huh? You have NOT posted any 'main' or any 'objects method'.

If you need help with code you have to post the code.

The Java tutorials has dozens of trails on 'Classes and Objects': what they are, how to create them and how to use them.

https://docs.oracle.com/javase/tutorial/java/javaOO/classes.html

1. Create an instance of a class

2. call one or more of the public methods of that class

If the class has public static methods then you do NOT need to create an instance first.

I suggest you work your way thru those tutorials. They include WORKING example code.

Marked as Answer by 2801625 · Sep 27 2020
aJohny

As rp0428 suggested, please go through the tutorials first, add extra debug messages in the samples if needed, get an understanding how things works.

You have not given the full code, so we can't help much.

By looking at the content, it looks like you have written this in the Constructor. Refer the below link to understand about Constructors

https://docs.oracle.com/javase/tutorial/java/javaOO/constructors.html

If the above piece of code is the constructor code, it will get executed when you create the instance of the class itself (with those number of parameters);

ex:= FileContentsObject fileContentsObject = new FileContentsObject( cachecName, lastModifiedTimeStamp,contents, fileName, lines);

I have used the same variable names as the ones defined in the class, which is not necessary. These variables has to be defined first.

Hope it helps.

Cheers

AJ

2801625

Thanks for the advice so far this info has proved to be extremely helpful.

1 - 3
Locked Post
New comments cannot be posted to this locked post.

Post Details

Locked on Dec 17 2010
Added on Apr 3 2007
49 comments
58,028 views