in reply to Re: SQL query: are all results in one hashref key the same?
in thread SQL query: are all results in one hashref key the same?
To set the record straight, I am doing it in Perl, and for more detail of what I'm doing with DBI -- what the tables look like is more or less irrelevant, but essentially my select is:
select actor_name, episode_title, character_name FROM <my tables> WHERE <certain table columns match> AND actor_id = $id
And this results in rows representing a list of episodes an actor has appeared in. Most of the time he or she played the same character, so the character_name is the same in every row.
I wanted to be able to do a preliminary type of select which returned either one or more-than-one rows depending on whether that actor played one or more roles in total.
It does seem that GROUP BY will do what I want. Thanks.
($_='kkvvttuubbooppuuiiffssqqffssmmiibbddllffss') =~y~b-v~a-z~s; print
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Re: Re: SQL query: are all results in one hashref key the same?
by etcshadow (Priest) on Oct 12, 2003 at 01:15 UTC | |
by Cody Pendant (Prior) on Oct 12, 2003 at 04:40 UTC | |
by etcshadow (Priest) on Oct 13, 2003 at 01:42 UTC |