Shared publicly  - 
What's the longest SQL query you've ever seen?
Sean Harding's profile photoRob Cockerham's profile photoHaji Hill's profile photoBill Ferrel's profile photo
Well, I don't want to brag, but.....
really? i could post something.
sounds like you've come a long way since our talk on the train that day? (y/n)
The idea of a TV ad database intrigues me greatly.
The largest obstacle is that there are an impossible number of them. However, they are short, and therefore pretty easy to collect and file. Other people are doing the same thing, but all of them are industry tools which require a paid membership, so my free., ad-based project has a chance to catch an audience.
If it gets momentum, crowdsourcing can save you. Maybe you could open it up as a semi-private beta, with a group of trusted people who will commit to pumping in a good amount of data. If it already has enough information to be useful when you do the public launch, it has a decent chance of taking off.
Very cool! I'm going to have to play with it some more. Looks fun!
It would be good to hang out sometime and talk about what we're working on, trade some ideas, maybe pair up on something.
I'm getting into ios apps for instance. Lots of room for collaboration and learning there.
Glad the SQL and Php thing went somewhere, at least, though. That's awesome. One of these days you'll have to tell me if I gave you enough to get going, or simply confused you enough so you had to go figure it out.
Oh, and in response to your original question: I was getting grief from the non techies at work (luddites) about what I do or do not do, because they have no concept. So, for several months I kept chemistry style legal notes, SQL included, for all procedures and tasks I was doing. What the outcomes were, further inquiry, etc... I had to print it on 11x17 landscape, and one page was a single SQL statement that carefully ordered, assigned unique ids to based on data, and prepped for the selective summing, 'rolling up' they call it, lines of data where it was called for, and a whole separate page was a single statement to do the summing and out the data as appropriate for the needs... Blahblahblah.... No one read it. There were several other queries that took half a page. The whole first document was ~50 pages, the second about 40. They asked meto stop preparing and printing those documents, as no one read them, and there were too many copies being made. I told them they had asked me for this info about what I do. They said, 'yes, we understand. that's fine. but we're good. please don't bring those in anymore.'
Oh yeah, and I printed in 8 point and 10 point fonts single spaced...... (varied for font of commands, vs text descriptions of procedures.)
Ha hah! You knew that was going to happen, right?
Either that or you explain it so well and fully that they start asking you to teach them all your tricks.
Yeah, lets get a beer and I'll make you critique my table structure!
I have one question for now: Is it generally better to taylor my queries to be precise, or to pull everything and then just sort through what I actually want on the page programmatically?
totally, that was most of the point.
i.e. stop. fucking. with. me.
That and if i get hit by a bus or get sick of their shit, i don't have to feel bad for just bailing as im now generally keeping notes that are pretty close. it actually proved useful to me in the end, keeping track of where i am one day to the next, and repeating things later.
honestly, depends. for scaling when you get traffic, you'll want careful stored procedures, views triggers, and timing of certain transactions. until you get too hammered, not drunk, the server... you can get away with whatever. depending on what you're deving your php with swapping queries can be easy. but overall, precise queries will give you less headaches over time. like anything else, more work now, or more work later?
also, was gonna comment earlier, to try and keep in mind crowdsourcing curation and moderation. it may not be a feature you want now, but in time, you may be very happy you had it in mind, at least, at the beginning.
btw the way, love the 'professional amateur scientist'. i tend to think of my self as a highly competent and skilled unfixer. Kinda similar.
Just ran across this post.  I actually wrote a SQL statement that when printed out took 7 - 8.5x11 sheets of paper.  It wasn't terribly complex once you understood what was going on.  It had many Union Statements, and took 1-2 minutes to run.
Add a comment...