POV-Ray : Newsgroups : povray.off-topic : SQL help Server Time
11 Oct 2024 05:19:05 EDT (-0400)
  SQL help (Message 5 to 14 of 44)  
<<< Previous 4 Messages Goto Latest 10 Messages Next 10 Messages >>>
From: Mike Raiford
Subject: Re: SQL help
Date: 7 Mar 2008 12:20:04
Message: <47d17944$1@news.povray.org>
Nicolas Alvarez wrote:

>> any pointers?
> 
> NULL.

If you give a person a NULL pointer, does that kill them?


Post a reply to this message

From: Mike Raiford
Subject: Re: SQL help
Date: 7 Mar 2008 12:22:21
Message: <47d179cd$1@news.povray.org>
Jim Henderson wrote:
> On Fri, 07 Mar 2008 16:58:58 +0000, Orchid XP v7 wrote:
> 
>> First person who says 0x3A28213A gets a slap!
> 
> LOL, you've got to know it's 0x3A28213B! ;)

Neither, The alignment's all wrong on a 32-bit machine... it should be 
0x3A28213C


Post a reply to this message

From: Nicolas Alvarez
Subject: Re: SQL help
Date: 7 Mar 2008 12:27:23
Message: <47d17afb@news.povray.org>

> Jim Henderson wrote:
>> On Fri, 07 Mar 2008 16:58:58 +0000, Orchid XP v7 wrote:
>>
>>> First person who says 0x3A28213A gets a slap!
>>
>> LOL, you've got to know it's 0x3A28213B! ;)
> 
> Neither, The alignment's all wrong on a 32-bit machine... it should be 
> 0x3A28213C

Andrew, I think your warning not to give "that kind of pointers" has 
backfired badly.


Post a reply to this message

From: Jim Henderson
Subject: Re: SQL help
Date: 7 Mar 2008 12:49:25
Message: <47d18025$1@news.povray.org>
On Fri, 07 Mar 2008 11:17:03 -0600, Mike Raiford wrote:

> Jim Henderson wrote:
>> On Fri, 07 Mar 2008 16:58:58 +0000, Orchid XP v7 wrote:
>> 
>>> First person who says 0x3A28213A gets a slap!
>> 
>> LOL, you've got to know it's 0x3A28213B! ;)
> 
> Neither, The alignment's all wrong on a 32-bit machine... it should be
> 0x3A28213C

Oh, right, I forgot to carry the 1. ;-)

Jim


Post a reply to this message

From: Orchid XP v7
Subject: Re: SQL help
Date: 7 Mar 2008 13:04:24
Message: <47d183a8$1@news.povray.org>
Nicolas Alvarez wrote:

> Andrew, I think your warning not to give "that kind of pointers" has 
> backfired badly.

...apparently. *rolls eyes*

-- 
http://blog.orphi.me.uk/
http://www.zazzle.com/MathematicalOrchid*


Post a reply to this message

From: Tom Austin
Subject: Re: SQL help
Date: 7 Mar 2008 13:17:59
Message: <47d186d7$1@news.povray.org>
Nicolas Alvarez wrote:

>> PS. Apparently "I see plenty of people who claim to know SQL who do 
>> worse than you did. You're really underselling yourself, Andrew. I 
>> wasn't even expecting you to ATTEMPT those last few..."
> 
> Remember that "unskilled and unaware of it" paper? The more you know, 
> the more you know you don't know too (does that make any sense?). People 
> may call themselves experts and not know what a JOIN is, and you say 
> you're somewhat rusty because you know about lots of features that exist 
> but you don't know very well, when you're actually much better than the 
> idiot calling himself an expert.
> 
> Does that make any sense either? Seems it's impossible to explain this 
> without long tricky sentences :)


Knowing what thou knowest not...
In in a sense...
Omniscience


Post a reply to this message

From: Darren New
Subject: Re: SQL help
Date: 7 Mar 2008 14:42:59
Message: <47d19ac3$1@news.povray.org>
Orchid XP v7 wrote:
> just don't remember the command syntax off the top of my head. 

Maybe that's because different engines use different syntax. :-)

> Another 
> wanted me to use "cursors" - something I've never ever done before. I 
> don't even know what one *is*.

It's kind of like imperative Haskell - try to avoid it. ;-)

> I sat for ages puzzling over this one. I can't figure out how the heck 
> to do it... any pointers?

I would first find the duration of each page view, then look for page 
views more than 10 minutes apart.

The duration is the difference between the view time of this row and the 
min of the view time of all rows with a later view time (select by user 
name or whatever your criteria are).  Unobvious. I had to ask that one 
myself.

After that, find the distinct user/duration>=10 pairs.

-- 
   Darren New / San Diego, CA, USA (PST)
     "That's pretty. Where's that?"
          "It's the Age of Channelwood."
     "We should go there on vacation some time."


Post a reply to this message

From: Orchid XP v7
Subject: Re: SQL help
Date: 7 Mar 2008 14:46:59
Message: <47d19bb3$1@news.povray.org>
Nicolas Alvarez wrote:

> Remember that "unskilled and unaware of it" paper? The more you know, 
> the more you know you don't know too (does that make any sense?). People 
> may call themselves experts and not know what a JOIN is, and you say 
> you're somewhat rusty because you know about lots of features that exist 
> but you don't know very well, when you're actually much better than the 
> idiot calling himself an expert.
> 
> Does that make any sense either? Seems it's impossible to explain this 
> without long tricky sentences :)

Hmm... it has a flavour...

-- 
http://blog.orphi.me.uk/
http://www.zazzle.com/MathematicalOrchid*


Post a reply to this message

From: Darren New
Subject: Re: SQL help
Date: 7 Mar 2008 14:48:06
Message: <47d19bf6$1@news.povray.org>
Darren New wrote:
> I would first find the duration of each page view, then look for page 
> views more than 10 minutes apart.

Or, to clarify. Count the number of sessions that *ended*.  Much easier 
than counting the number of sessions that started.  Finding the end of a 
session is finding the row where there's no row with a greater timestamp 
but within 10 minutes of this timestamp.

-- 
   Darren New / San Diego, CA, USA (PST)
     "That's pretty. Where's that?"
          "It's the Age of Channelwood."
     "We should go there on vacation some time."


Post a reply to this message

From: Orchid XP v7
Subject: Re: SQL help
Date: 7 Mar 2008 14:50:10
Message: <47d19c72$1@news.povray.org>
Darren New wrote:
> Darren New wrote:
>> I would first find the duration of each page view, then look for page 
>> views more than 10 minutes apart.
> 
> Or, to clarify. Count the number of sessions that *ended*.  Much easier 
> than counting the number of sessions that started.  Finding the end of a 
> session is finding the row where there's no row with a greater timestamp 
> but within 10 minutes of this timestamp.

Care to write an SQL statement? ;-)

-- 
http://blog.orphi.me.uk/
http://www.zazzle.com/MathematicalOrchid*


Post a reply to this message

<<< Previous 4 Messages Goto Latest 10 Messages Next 10 Messages >>>

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.