Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.os.linux.advocacy > #383634

Re: Where are you, sdb? I have something fun for your little morons to try

From deplorable owl <owl@rooftop.invalid>
Newsgroups comp.os.linux.advocacy
Subject Re: Where are you, sdb? I have something fun for your little morons to try
Date 2016-12-11 04:07 +0000
Organization O.W.L.
Message-ID <ahgjeob003.ag@rooftop.invalid> (permalink)
References (9 earlier) <o2ho5i$n47$3@dont-email.me> <ahjgob040.ae@rooftop.invalid> <o2i132$ll7$1@dont-email.me> <o2i851$afo$1@dont-email.me> <o2i8pt$e0d$1@dont-email.me>

Show all headers | View raw


DFS <nospam@dfs.com> wrote:
> On 12/10/2016 07:56 PM, DFS wrote:
> 
> whoops... needs a commit right here:
> 
> 
> conn.commit()
>> db.execute("SELECT COUNT(dts) FROM RANDOMDATES;")
>> print str(db.fetchone()[0]) + ' rows in table'
> 
> 
> 
> I ran it 4 or 5 times, and twice it inserted just under 100K rows
> 
> [dfs@manjaro Downloads]$ python pop100K.py 100000
> 99997 rows in table
> Built list of 100000 random dates: 2.1 seconds
> 
> First 10 random dates:
> 1768-04-25 00:27:44 17680425002744
> 1852-11-01 07:03:59 18521101070359
> 1749-11-07 05:29:12 17491107052912
> 1832-08-20 13:07:43 18320820130743
> 1822-07-19 22:37:22 18220719223722
> 2005-08-18 00:55:13 20050818005513
> 1969-06-24 23:00:28 19690624230028
> 1806-01-19 19:45:51 18060119194551
> 1908-03-11 12:20:26 19080311122026
> 1970-10-04 23:15:46 19701004231546
> 
> Last 10 random dates:
> 1853-09-28 01:34:39 18530928013439
> 1753-02-09 01:53:47 17530209015347
> 1843-06-19 00:39:08 18430619003908
> 1904-11-07 19:47:45 19041107194745
> 1795-05-07 10:12:14 17950507101214
> 1950-11-19 17:45:29 19501119174529
> 1957-07-03 14:39:04 19570703143904
> 1882-02-15 06:17:48 18820215061748
> 1901-06-21 00:09:17 19010621000917
> 2012-12-18 18:25:59 20121218182559
> 

Are those unique with respect to the YYYY-MM-DD part?

This illustrates what I'm talking about with the seconds:

anon@lowtide:~/code/dfsdates$ ./getdaysec -7158654004
25-Feb-1743
anon@lowtide:~/code/dfsdates$ ./getdaysec -7158654003
25-Feb-1743
anon@lowtide:~/code/dfsdates$ ./getdaysec -7158654002
25-Feb-1743
anon@lowtide:~/code/dfsdates$ ./getdaysec -7158654001
25-Feb-1743
anon@lowtide:~/code/dfsdates$ ./getdaysec -7158654000 -t
25-Feb-1743 00:03:58
anon@lowtide:~/code/dfsdates$ ./getdaysec -7158653999 -t
25-Feb-1743 00:03:59
anon@lowtide:~/code/dfsdates$ ./getdaysec -7158653998 -t
25-Feb-1743 00:04:00
anon@lowtide:~/code/dfsdates$
...
anon@lowtide:~/code/dfsdates$ ./getdaysec -68402 -t
30-Dec-1969 23:59:58
anon@lowtide:~/code/dfsdates$ ./getdaysec -68401 -t
30-Dec-1969 23:59:59
anon@lowtide:~/code/dfsdates$ ./getdaysec -68400 -t
31-Dec-1969 00:00:00
anon@lowtide:~/code/dfsdates$ ./getdaysec -68399 -t
31-Dec-1969 00:00:01
anon@lowtide:~/code/dfsdates$ ./getdaysec -68398 -t
31-Dec-1969 00:00:02
anon@lowtide:~/code/dfsdates$ ./getdaysec -68397 -t
31-Dec-1969 00:00:03
anon@lowtide:~/code/dfsdates$
...
anon@lowtide:~/code/dfsdates$ ./getdaysec -2 -t
31-Dec-1969 18:59:58
anon@lowtide:~/code/dfsdates$ ./getdaysec -1 -t
31-Dec-1969 18:59:59
anon@lowtide:~/code/dfsdates$ ./getdaysec 0 -t
31-Dec-1969 19:00:00
anon@lowtide:~/code/dfsdates$ ./getdaysec 1 -t
31-Dec-1969 19:00:01
anon@lowtide:~/code/dfsdates$ ./getdaysec 2 -t
31-Dec-1969 19:00:02
anon@lowtide:~/code/dfsdates$ ./getdaysec 3 -t
31-Dec-1969 19:00:03
anon@lowtide:~/code/dfsdates$ 
...
anon@lowtide:~/code/dfsdates$ ./getdaysec 17997 -t
31-Dec-1969 23:59:57
anon@lowtide:~/code/dfsdates$ ./getdaysec 17998 -t
31-Dec-1969 23:59:58
anon@lowtide:~/code/dfsdates$ ./getdaysec 17999 -t
31-Dec-1969 23:59:59
anon@lowtide:~/code/dfsdates$ ./getdaysec 18000 -t
01-Jan-1970 00:00:00
anon@lowtide:~/code/dfsdates$ ./getdaysec 18001 -t
01-Jan-1970 00:00:01
anon@lowtide:~/code/dfsdates$ ./getdaysec 18002 -t
01-Jan-1970 00:00:02
anon@lowtide:~/code/dfsdates$ ./getdaysec 18003 -t
01-Jan-1970 00:00:03
anon@lowtide:~/code/dfsdates$
...
anon@lowtide:~/code/dfsdates$ ./getdaysec  1481345998 -t
09-Dec-2016 23:59:58
anon@lowtide:~/code/dfsdates$ ./getdaysec  1481345999 -t
09-Dec-2016 23:59:59
anon@lowtide:~/code/dfsdates$ ./getdaysec  1481346000 -t
10-Dec-2016 00:00:00
anon@lowtide:~/code/dfsdates$ ./getdaysec  1481346001 -t
10-Dec-2016 00:00:01
anon@lowtide:~/code/dfsdates$ ./getdaysec  1481346002 -t
10-Dec-2016 00:00:02
anon@lowtide:~/code/dfsdates$ ./getdaysec  1481346003
10-Dec-2016
anon@lowtide:~/code/dfsdates$ ./getdaysec  1481346004
10-Dec-2016
anon@lowtide:~/code/dfsdates$ ./getdaysec  1481346005
10-Dec-2016
anon@lowtide:~/code/dfsdates$ ./getdaysec  1481346006
10-Dec-2016
anon@lowtide:~/code/dfsdates$ 


anon@lowtide:~/code/dfsdates$ cat getdaysec.c
#include <stdio.h>
#include <stdlib.h>
#include <time.h>
#include <string.h>
void usage(void);
int main(int argc, char *argv[])
{
  time_t num=0;
  char *fmtstr=NULL;
  char buf[100]={0};
  char *str=NULL;
  char *end;
  switch(argc)
  {
   case 2:
      fmtstr="%d-%b-%Y"; 
      break;  
   case 3:
      if(!strcmp(argv[2],"-t"))
      {
        fmtstr="%d-%b-%Y %H:%M:%S"; 
        break;  
      } 
   default:
      usage();
      exit(1); 
  }
  str=argv[1];
  num=(time_t)strtol(str,&end,10); 
  strftime(buf,sizeof buf,fmtstr,localtime(&num));
  printf("%s\n",buf);
  return 0;
}
void usage(void)
{
  fprintf(stderr,"one or two arguments. first is a number, "
                 "optional second is '-t'\n"); 
}
anon@lowtide:~/code/dfsdates$ 


Back to comp.os.linux.advocacy | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

Where are you, sdb? I have something fun for your little morons to try DFS <nospam@dfs.com> - 2016-12-07 12:27 -0500
  Re: Where are you, sdb? I have something fun for your little morons to try deplorable owl <owl@rooftop.invalid> - 2016-12-07 19:52 +0000
    Re: Where are you, sdb? I have something fun for your little morons to try DFS <nospam@dfs.com> - 2016-12-07 21:28 -0500
      Re: Where are you, sdb? I have something fun for your little morons to try deplorable owl <owl@rooftop.invalid> - 2016-12-08 05:52 +0000
        Re: Where are you, sdb? I have something fun for your little morons to try chrisv <chrisv@nospam.invalid> - 2016-12-08 07:02 -0600
          Re: Where are you, sdb? I have something fun for your little morons to try DFS <nospam@dfs.com> - 2016-12-08 09:02 -0500
  Re: Where are you, sdb? I have something fun for your little morons to try Adlbifhr Mjduhgfks <am@random.us> - 2016-12-08 00:32 +0000
    Re: Where are you, sdb? I have something fun for your little morons to try DFS <nospam@dfs.com> - 2016-12-07 21:48 -0500
      Re: Where are you, sdb? I have something fun for your little morons to try Adlbifhr Mjduhgfks <am@random.us> - 2016-12-08 14:17 +0000
        Re: Where are you, sdb? I have something fun for your little morons to try DFS <nospam@dfs.com> - 2016-12-08 11:00 -0500
          Re: Where are you, sdb? I have something fun for your little morons to try Steve Carroll <fretwizzer@gmail.com> - 2016-12-08 09:13 -0800
            Re: Where are you, sdb? I have something fun for your little morons to try DFS <nospam@dfs.com> - 2016-12-08 18:41 -0500
              Re: Where are you, sdb? I have something fun for your little morons to try Steve Carroll <fretwizzer@gmail.com> - 2016-12-08 17:32 -0800
                Re: Where are you, sdb? I have something fun for your little morons to try DFS <nospam@dfs.com> - 2016-12-08 21:12 -0500
                Cartoons are easier to read than the Wall Street Journal. Jeff-Relf.Me <@.> - 2016-12-08 20:16 -0800
                Re: Where are you, sdb? I have something fun for your little morons to try Steve Carroll <fretwizzer@gmail.com> - 2016-12-09 09:03 -0800
      Re: Where are you, sdb? I have something fun for your little morons to try Adlbifhr Mjduhgfks <am@random.us> - 2016-12-08 15:49 +0000
        Re: Where are you, sdb? I have something fun for your little morons to try DFS <nospam@dfs.com> - 2016-12-08 11:00 -0500
          Re: Where are you, sdb? I have something fun for your little morons to try Adlbifhr Mjduhgfks <am@random.us> - 2016-12-08 16:24 +0000
            Re: Where are you, sdb? I have something fun for your little morons to try DFS <nospam@dfs.com> - 2016-12-08 18:43 -0500
              Only _results_ matter; i.e.:  What does it do ? Jeff-Relf.Me <@.> - 2016-12-08 19:45 -0800
                Re: Only _results_ matter; i.e.:  What does it do ? flatfish+++ <flatfish@linuxmail.org> - 2016-12-08 22:50 -0500
                I don't need the source code. Jeff-Relf.Me <@.> - 2016-12-08 20:39 -0800
                Re: I don't need the source code. flatfish+++ <flatfish@linuxmail.org> - 2016-12-08 23:48 -0500
                I'm hard to copy, thank God. Jeff-Relf.Me <@.> - 2016-12-08 22:30 -0800
                Re: I'm hard to copy, thank God. flatfish+++ <flatfish@linuxmail.org> - 2016-12-09 01:54 -0500
                Re: I'm hard to copy, thank God. Steve Carroll <fretwizzer@gmail.com> - 2016-12-09 12:30 -0800
                Re: I don't need the source code. Poutnik <poutnik4nntp@gmail.com> - 2016-12-09 07:12 +0100
                Re: I don't need the source code. flatfish+++ <flatfish@linuxmail.org> - 2016-12-09 01:15 -0500
                Re: I don't need the source code. Poutnik <poutnik4nntp@gmail.com> - 2016-12-09 07:27 +0100
                Re: I don't need the source code. flatfish+++ <flatfish@linuxmail.org> - 2016-12-09 01:44 -0500
                Usenet is not CraigsList nor WikiPedia, Reddit. Jeff-Relf.Me <@.> - 2016-12-08 23:00 -0800
                Re: Usenet is not CraigsList nor WikiPedia, Reddit. flatfish+++ <flatfish@linuxmail.org> - 2016-12-09 02:12 -0500
                If/When Cola is being honest, they don't think MicroSoft is "Evil". Jeff-Relf.Me <@.> - 2016-12-08 23:56 -0800
                Re: Usenet is not CraigsList nor WikiPedia, Reddit. Poutnik <poutnik4nntp@gmail.com> - 2016-12-09 08:16 +0100
                Usually, the __DEFAULT__ "Subject:" line isn't best. Jeff-Relf.Me <@.> - 2016-12-08 22:53 -0800
                Re: Usually, the __DEFAULT__ "Subject:" line isn't best. Poutnik <poutnik4nntp@gmail.com> - 2016-12-09 08:19 +0100
                Please lookup the word "Default". Jeff-Relf.Me <@.> - 2016-12-08 23:31 -0800
                Re: Please lookup the word "Default". Poutnik <poutnik4nntp@gmail.com> - 2016-12-09 08:42 +0100
                The parent post. -- Re: Please lookup the word "Default". Jeff-Relf.Me <@.> - 2016-12-09 00:12 -0800
                Re: The parent post. -- Re: Please lookup the word "Default". Poutnik <poutnik4nntp@gmail.com> - 2016-12-09 11:28 +0100
                Threads branch like a tree, SubTopics sprout. Jeff-Relf.Me <@.> - 2016-12-09 03:35 -0800
                Re: Threads branch like a tree, SubTopics sprout. Poutnik <poutnik4nntp@gmail.com> - 2016-12-09 16:18 +0100
                Re: The parent post. -- Re: Please lookup the word "Default". moroney@world.std.spaamtrap.com (Michael Moroney) - 2016-12-09 15:05 +0000
                I want details, Michael Moroney. Jeff-Relf.Me <@.> - 2016-12-09 07:18 -0800
                Re: I want details, Michael Moroney. Steve Carroll <fretwizzer@gmail.com> - 2016-12-09 10:38 -0800
                Re: I want details, Michael Moroney. moroney@world.std.spaamtrap.com (Michael Moroney) - 2016-12-10 04:03 +0000
                I never had to deal with such problems. Jeff-Relf.Me <@.> - 2016-12-09 21:15 -0800
                Re: I never had to deal with such problems. moroney@world.std.spaamtrap.com (Michael Moroney) - 2016-12-11 01:50 +0000
                Re: The parent post. -- Re: Please lookup the word "Default". chrisv <chrisv@nospam.invalid> - 2016-12-09 09:37 -0600
                Re: The parent post. -- Re: Please lookup the word "Default". moroney@world.std.spaamtrap.com (Michael Moroney) - 2016-12-09 20:32 +0000
                Re: I don't need the source code. chrisv <chrisv@nospam.invalid> - 2016-12-09 06:39 -0600
                Re: I don't need the source code. Poutnik <poutnik4nntp@gmail.com> - 2016-12-09 16:19 +0100
                Re: I don't need the source code. Silver Slimer <.m@nsn.s> - 2016-12-09 11:51 -0500
                Re: I don't need the source code. flatfish+++ <flatfish@linuxmail.org> - 2016-12-09 12:07 -0500
                Re: I don't need the source code. Silver Slimer <.m@nsn.s> - 2016-12-09 12:22 -0500
                Re: I don't need the source code. flatfish+++ <flatfish@linuxmail.org> - 2016-12-09 12:28 -0500
                Re: I don't need the source code. moroney@world.std.spaamtrap.com (Michael Moroney) - 2016-12-09 17:52 +0000
                I only have time to read a few select authors, sorry. Jeff-Relf.Me <@.> - 2016-12-09 10:05 -0800
                Re: I don't need the source code. chrisv <chrisv@nospam.invalid> - 2016-12-09 12:26 -0600
                Re: I don't need the source code. Silver Slimer <.m@nsn.s> - 2016-12-09 14:06 -0500
                Re: I don't need the source code. Chris Ahlstrom <OFeem1987@teleworm.us> - 2016-12-09 19:56 -0500
                Re: I don't need the source code. Silver Slimer <.m@nsn.s> - 2016-12-10 09:23 -0500
                Re: Only _results_ matter; i.e.:  What does it do ? fr314159@gmail.com - 2016-12-09 07:17 -0800
                Re: Only _results_ matter; i.e.: What does it do ? DFS <nospam@dfs.com> - 2016-12-12 18:54 -0500
    Re: Where are you, sdb? I have something fun for your little morons to try DFS <nospam@dfs.com> - 2016-12-12 18:39 -0500
  Re: Where are you, sdb? I have something fun for your little morons to try Melzzzzz <mel@zzzzz.com> - 2016-12-09 03:38 +0100
    Re: Where are you, sdb? I have something fun for your little morons to try deplorable owl <owl@rooftop.invalid> - 2016-12-09 19:00 +0000
      Re: Where are you, sdb? I have something fun for your little morons to try Melzzzzz <mel@zzzzz.com> - 2016-12-10 00:33 +0100
        Re: Where are you, sdb? I have something fun for your little morons to try deplorable owl <owl@rooftop.invalid> - 2016-12-10 05:24 +0000
          Re: Where are you, sdb? I have something fun for your little morons to try Melzzzzz <Melzzzzz@zzzzz.com> - 2016-12-10 06:54 +0100
            Re: Where are you, sdb? I have something fun for your little morons to try deplorable owl <owl@rooftop.invalid> - 2016-12-10 06:25 +0000
              Re: Where are you, sdb? I have something fun for your little morons to try Melzzzzz <Melzzzzz@zzzzz.com> - 2016-12-10 07:28 +0100
                Re: Where are you, sdb? I have something fun for your little morons to try deplorable owl <owl@rooftop.invalid> - 2016-12-10 19:56 +0000
                Re: Where are you, sdb? I have something fun for your little morons to try DFS <nospam@dfs.com> - 2016-12-10 15:19 -0500
                Re: Where are you, sdb? I have something fun for your little morons to try DFS <nospam@dfs.com> - 2016-12-10 15:23 -0500
                Re: Where are you, sdb? I have something fun for your little morons to try deplorable owl <owl@rooftop.invalid> - 2016-12-10 20:44 +0000
                Re: Where are you, sdb? I have something fun for your little morons to try DFS <nospam@dfs.com> - 2016-12-10 17:55 -0500
                Re: Where are you, sdb? I have something fun for your little morons to try deplorable owl <owl@rooftop.invalid> - 2016-12-11 00:02 +0000
                Re: Where are you, sdb? I have something fun for your little morons to try DFS <nospam@dfs.com> - 2016-12-10 19:39 -0500
                C/CPP's "srand( int Seed )" generates an array of (PseudoRandom) int's. Jeff-Relf.Me <@.> - 2016-12-10 23:09 -0800
                Re: C/CPP's "srand( int Seed )" generates an array of (PseudoRandom) int's. deplorable owl <owl@rooftop.invalid> - 2016-12-11 07:23 +0000
                Re: Where are you, sdb? I have something fun for your little morons to try DFS <nospam@dfs.com> - 2016-12-10 19:56 -0500
                Re: Where are you, sdb? I have something fun for your little morons to try DFS <nospam@dfs.com> - 2016-12-10 20:07 -0500
                Re: Where are you, sdb? I have something fun for your little morons to try deplorable owl <owl@rooftop.invalid> - 2016-12-11 04:07 +0000
                Re: Where are you, sdb? I have something fun for your little morons to try DFS <nospam@dfs.com> - 2016-12-11 00:18 -0500
                Re: Where are you, sdb? I have something fun for your little morons to try Melzzzzz <mel@zzzzz.com> - 2016-12-11 03:40 +0100
                Re: Where are you, sdb? I have something fun for your little morons to try deplorable owl <owl@rooftop.invalid> - 2016-12-11 04:00 +0000
                Re: Where are you, sdb? I have something fun for your little morons to try Melzzzzz <Melzzzzz@zzzzz.com> - 2016-12-11 05:08 +0100
                Re: Where are you, sdb? I have something fun for your little morons to try deplorable owl <owl@rooftop.invalid> - 2016-12-11 04:27 +0000
                Re: Where are you, sdb? I have something fun for your little morons to try Melzzzzz <Melzzzzz@zzzzz.com> - 2016-12-11 05:58 +0100
                Re: Where are you, sdb? I have something fun for your little morons to try deplorable owl <owl@rooftop.invalid> - 2016-12-11 05:55 +0000
                Re: Where are you, sdb? I have something fun for your little morons to try Melzzzzz <Melzzzzz@zzzzz.com> - 2016-12-11 07:11 +0100
                Re: Where are you, sdb? I have something fun for your little morons to try deplorable owl <owl@rooftop.invalid> - 2016-12-11 06:49 +0000
                Re: Where are you, sdb? I have something fun for your little morons to try Melzzzzz <mel@zzzzz.com> - 2016-12-11 07:52 +0100
                Re: Where are you, sdb? I have something fun for your little morons to try deplorable owl <owl@rooftop.invalid> - 2016-12-11 07:09 +0000
                Re: Where are you, sdb? I have something fun for your little morons to try Melzzzzz <Melzzzzz@zzzzz.com> - 2016-12-11 08:23 +0100
                Re: Where are you, sdb? I have something fun for your little morons to try deplorable owl <owl@rooftop.invalid> - 2016-12-11 07:37 +0000
                Re: Where are you, sdb? I have something fun for your little morons to try Melzzzzz <Melzzzzz@zzzzz.com> - 2016-12-11 08:40 +0100
                Re: Where are you, sdb? I have something fun for your little morons to try deplorable owl <owl@rooftop.invalid> - 2016-12-11 09:05 +0000
        Re: Where are you, sdb? I have something fun for your little morons to try deplorable owl <owl@rooftop.invalid> - 2016-12-10 19:41 +0000
          Re: Where are you, sdb? I have something fun for your little morons to try Melzzzzz <mel@zzzzz.com> - 2016-12-10 20:48 +0100
            Re: Where are you, sdb? I have something fun for your little morons to try deplorable owl <owl@rooftop.invalid> - 2016-12-10 20:06 +0000
      Re: Where are you, sdb? I have something fun for your little morons to try DFS <nospam@dfs.com> - 2016-12-10 10:32 -0500
        Re: Where are you, sdb? I have something fun for your little morons to try Melzzzzz <mel@zzzzz.com> - 2016-12-10 16:40 +0100
          Re: Where are you, sdb? I have something fun for your little morons to try DFS <nospam@dfs.com> - 2016-12-10 11:03 -0500
            Re: Where are you, sdb? I have something fun for your little morons to try Steve Carroll <fretwizzer@gmail.com> - 2016-12-10 09:26 -0800
              Re: Where are you, sdb? I have something fun for your little morons to try DFS <nospam@dfs.com> - 2016-12-10 12:38 -0500
                Re: Where are you, sdb? I have something fun for your little morons to try Steve Carroll <fretwizzer@gmail.com> - 2016-12-10 09:52 -0800
                Re: Where are you, sdb? I have something fun for your little morons to try DFS <nospam@dfs.com> - 2016-12-10 13:01 -0500
                Re: Where are you, sdb? I have something fun for your little morons to try Steve Carroll <fretwizzer@gmail.com> - 2016-12-10 10:06 -0800
            Re: Where are you, sdb? I have something fun for your little morons to try deplorable owl <owl@rooftop.invalid> - 2016-12-10 19:38 +0000
              Re: Where are you, sdb? I have something fun for your little morons to try DFS <nospam@dfs.com> - 2016-12-10 19:55 -0500
        Re: Where are you, sdb? I have something fun for your little morons to try deplorable owl <owl@rooftop.invalid> - 2016-12-10 19:33 +0000
          Re: Where are you, sdb? I have something fun for your little morons to try deplorable owl <owl@rooftop.invalid> - 2016-12-10 20:00 +0000

csiph-web