Home » SQL & PL/SQL » SQL & PL/SQL » SQL Query - help needed (Oracle 9i)
SQL Query - help needed [message #335958] Thu, 24 July 2008 04:52 Go to next message
close2jay
Messages: 1
Registered: July 2008
Junior Member
Hi,

In my table I am having data like below:

Job ename
CLERK A
SALES C
CLERK B
CLERK D
SALES E
SALES F

In the output, i want to print JOB column only once.
I am new to SQL so please help me on this.

Expected Output:
=================

Job ename
CLERK A
B
D
SALES C
E
F


Thanks,


Re: SQL Query - help needed [message #335973 is a reply to message #335958] Thu, 24 July 2008 05:12 Go to previous message
Michel Cadot
Messages: 64152
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
If you use SQL*Plus, use BREAK command otherwise search on the forum there are solutions.

Also please read OraFAQ Forum Guide, especially "How to format your post?" section.
Make sure that lines of code do not exceed 80 characters when you format.
Indent the code (See SQL Formatter) and align the columns in result.
Use the "Preview Message" button to verify.
Also always post your Oracle version (4 decimals).

Regards
Michel
Previous Topic: Flag field based on max(date)
Next Topic: Invalid Objects
Goto Forum:
  


Current Time: Sat Dec 10 10:43:46 CST 2016

Total time taken to generate the page: 0.07715 seconds