Beefy Boxes and Bandwidth Generously Provided by pair Networks
Don't ask to ask, just ask
 
PerlMonks  

Re: DBI: select distinct returns same values

by FreeBeerReekingMonk (Deacon)
on Sep 21, 2019 at 11:08 UTC ( #11106474=note: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    select distinct cast(DATE as date) from myschema.mytable GROUP BY DATE
    
  2. or download this
    
    create table foo (IDENTITY INT, LoginTime DATETIME);
    ...
    --Select unique
    SELECT distinct cast(LoginTime as date) FROM foo GROUP BY LoginTime;
    
  3. or download this
    #!/usr/bin/perl
    use strict;
    ...
    }
    
    $dbh->disconnect;
    
  4. or download this
    [29-09-2019]
    [30-09-2019]
    
  5. or download this
    $VAR1 = [
              [
    ...
              ],
              $VAR1->[0]
            ];
    
  6. or download this
    $sth->execute();
    
    ...
    foreach my $row_ref (@all_rows) {
        print "$row_ref->[0]\n";
    }
    

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://11106474]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others imbibing at the Monastery: (6)
As of 2020-10-29 20:46 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    My favourite web site is:












    Results (274 votes). Check out past polls.

    Notices?