Prepare for your Next Interview
|
Welcome to the Geeks Talk forums. You are currently viewing our boards as a guest which gives you limited access to view most discussions and access our other features. By joining our free community you will have access to post topics, communicate privately with other members (PM), respond to polls, upload content and access many other special features. Registration is fast, simple and absolutely free so please, join our community today! If you have any problems with the registration process or your account login, please contact contact us. |
This is a discussion on Question within the Oracle forums, part of the Databases category; Write PLSQL to print the Mulpilication Table in maths....
|
|||||||
| Oracle Oracle 9i & Oracle 10g Knowledge Base Learn and Share Oracle Technology related articles, white papers, tutorials / study materials, example codes, FAQ's, Tips and Tricks. |
![]() |
| LinkBack | Thread Tools | Display Modes |
|
|||
|
Re: Question
sql query
select rownum||' * '|| &tnm ||' = ' ||rownum*&tnm from tab where rownum<=20 or pl/sql block declare i number; tbl number:=2; begin for i in 1..20 loop dbms_output.put_line(i||' * '||tbl||' = '|| i*tbl); end loop; end;
__________________
Sireesha |
|
|||
|
Re: Question
Hi check with below codes.
declare i number; j number; n number; begin n:=&n;---upto which number u want for i in 1..n loop DBMS_OUTPUT.put_line('Multiplication table for---->'|| i); for j in 1..10 loop DBMS_OUTPUT.put_line((i||' X '|| j ||' = '||i*j); --insert into tom values(i||' X '|| j ||' = '||i*j); end loop; end loop; end; |
|
|||
|
Re: Question
declare
--i number; --j number; n number; begin n:=&n;---upto which number u want for i in 1..n loop DBMS_OUTPUT.put_line('Multiplication table for---->'||(i)); for j in 1..10 loop DBMS_OUTPUT.put_line((i)||' X '|| (j) ||' = '||(i*j)); --insert into tom values(i||' X '|| j ||' = '||i*j); end loop; end loop; end;
__________________
Sireesha |
|
|||
|
Re: Question
Declare
i number := &n; begin for j in 1..i loop for k in 1..12 loop dbms_output.put_line(j||'*'||k||'='||j*k); end loop; dbms_output.put_line(' '); end loop; end; |
![]() |
|
| Thread Tools | |
| Display Modes | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| sql question | sanjay kumar rajwar | SQL Server | 7 | 04-02-2009 10:25 AM |
| Question!!! | bee896 | C and C++ | 1 | 10-25-2008 01:41 PM |
| C++ Question | bee896 | C and C++ | 3 | 10-23-2008 12:59 AM |
| Question about QTP | SangeethaG | QTP | 4 | 09-12-2008 01:27 AM |
| question | sumerram | Interviews | 6 | 09-01-2008 10:01 PM |