Forum Home
|
Marketplace
|
Articles
|
Blogs
|
Interviews
|
Tools
REGISTER
|
SEARCH
|
MEMBERS
|
F.A.Q.
Register Here
Forum Rules
Webmaster-Talk.com
>
Web Administration Talk
>
The Database Forum
>
Group By Without Using Any Aggregate Function
Link Back
Thread Tools
Group By Without Using Any Aggregate Function
12-07-2007, 12:58 AM
#
1
(
permalink
)
Group By Without Using Any Aggregate Function
kapsne_143
Junior Talker
Posts: 1
Name: kapil
Talkupation:
Hi,
I want the select statement but i am using group by but i don't want to use any aggregate function on it . kindly suggest me the answer.
select empno, ename from emp group by deptid,empno;
Thank You,
When You
Register
, These Ads Go Away!
12-07-2007, 09:29 PM
#
2
(
permalink
)
Re: Group By Without Using Any Aggregate Function
ForrestCroce
Half Man, Half Amazing
Latest Blog Post:
4th of July Fireworks on Lake Union
Posts: 3,024
Name: Forrest Croce
Location: Seattle, WA
Talkupation:
If every field in your select list is also in the group by, you don't need aggregate functions to tell the database how to collapse multiple rows. In that case, you're probably better off using select distinct.
__________________
The Pacific Northwest
|
Escheresque
|
Avery Point, Connecticut
12-18-2007, 01:45 AM
#
3
(
permalink
)
Re: Group By Without Using Any Aggregate Function
ADAM Web Design
Canadastaninianite
Latest Blog Post:
If You Hate Form Spam, This is the Site for You
Posts: 5,945
Name: Adam for web page design, not program
Location: Toronto, Ontario, Canada
Talkupation:
Are you trying to sort your rows? If so, you want ORDER BY, not GROUP BY.
__________________
Search Engine Friendly Layouts
|
Walk on My Path
(my blog)
eBay Caters to Content Thieves
(with proof)
12-26-2007, 03:05 AM
#
4
(
permalink
)
Re: Group By Without Using Any Aggregate Function
brookittykat12
Novice Talker
Posts: 10
Name: Cookie
Talkupation:
people talk about stuff i hav no clue about WAY too often.
oh, poo. I feel like a watermelon who dreamed she was a pickle.
12-26-2007, 03:06 AM
#
5
(
permalink
)
Re: Group By Without Using Any Aggregate Function
brookittykat12
Novice Talker
Posts: 10
Name: Cookie
Talkupation:
anyways...
ignorance is bliss, right? ain't that good?
« Reply to
Group By Without Using Any Aggregate Function
Previous Thread
|
Next Thread
Webmaster-Talk.com
>
Web Administration Talk
>
The Database Forum
>
Group By Without Using Any Aggregate Function
Thread Tools
Show Printable Version
Email this Page
Posting Rules
You
may not
post new threads
You
may not
post replies
You
may not
post attachments
You
may not
edit your posts
vB code
is
On
Smilies
are
On
[IMG]
code is
On
HTML code is
Off
Trackbacks
are
Off
Pingbacks
are
Off
Refbacks
are
Off
Webmaster Resources Marketplace:
Software Development Company
|
Webhosting.UK.com
Web Templates
|
Text Link Brokers
|
Stock Photos
Feeds:
RSS
JS
XML
Feeds for this forum:
RSS
JS
XML
Mark Forums Read
-
View Forum Leaders
-
Contact Us
-
Webmaster Forum
-
Advertise
-
Archive
-
Privacy Statement
-
Top
Page generated in
0.12086
seconds with
12
queries