15 years later: on the physics of high-rise building collapses (2016) - <AUTHOR> https://www.europhysicsnews.org/articles/epn/abs/2016/04/epn2016474p21/epn2016474p21.html <comment><USER2> Snopes has some nice commentary on this. Key takeaway-- this is not a peer reviewed journal. [https://www.snopes.com/fact-check/journal- endorses-911-consp...](https://www.snopes.com/fact-check/journal- endorses-911-conspiracy-theory/)

</comment><comment><USER3> Dr. J. Leroy Hulsey of the University of Alaska Fairbanks has a study on the collapse of just World Trade Center Building 7, which fell even though it was not hit by a plane. So far he has concluded that:

"The findings thus far are that fire did not bring down this building. Building failure simulations show that, to match observation, the entire inner core of this building failed nearly simultaneously."[1]

[1]: [http://ine.uaf.edu/projects/wtc7/](http://ine.uaf.edu/projects/wtc7/)

</comment><comment><AUTHOR> TL;DR:

From the article's conclusion:

"Instead, the evidence points overwhelmingly to the conclusion that all three buildings were destroyed by controlled demolition."

</comment><comment><USER4> I was hoping for something more interesting. All they did here is raise the usual doubts, and provide no evidence to bolster their conclusion. At best what they've done is show that we still can't completely explain through modeling what happened with those buildings. That's a looooong ways from proving it was really a controlled demolition.

</comment><comment><USER5> I know it sounds nuts, but Dr Judy Wood makes a damned good case that the twin towers (not bldg 7) were turned to dust by directed energy weapons.

Watch with an open mind and just look at the evidence, don't prejudge based on "come on, our government would never do something like that...".

[https://youtu.be/ermHx3akejc](https://youtu.be/ermHx3akejc)

</comment><comment><USER6> question for people who know the subject (from someone who doesn't) : is this paper legit or written by conspiracy minded individuals? I didn't want to say 'nuts'.

<comment><USER7> the 2nd part is for sure true (they believe it's controlled demolitions, and when you believe something, confirmation bias ([https://youarenotsosmart.com/2010/06/23/confirmation- bias/](https://youarenotsosmart.com/2010/06/23/confirmation-bias/)) probably makes you find more and more evidence that prove your belief), and whether it's legit, well, considering who the writers associate with, I would scrutinize their claims more, if finding the truth about this topic really bothered me...

</comment></comment><comment><USER7> TL;DR: two (edit: four) 9/11 Truthers wrote a paper. Can't be bothered to see if what they claim about the NIST investigation being un-transparent and sloppy is valid.</comment>


How a 64k intro is made - <AUTHOR> http://www.lofibucket.com/articles/64k_intro.html <comment><USER3> There is a nice documentary on the history of the demoscene, with some introspection to the creative process behind a demo/intro. It was made by a Hungarian team, who has other interesting documentaries on underground culture.

It is also available in English, at: [https://www.youtube.com/watch?v=iRkZcTg1JWU](https://www.youtube.com/watch?v=iRkZcTg1JWU)

<comment><USER4> FYI, there's a lot of interviews in that video that are not in English.

<comment><USER3> I'm sorry to hear that. There should be CC available, but to be honest I have only watched the Hungarian version in full length, and only knew about the existence of the English version.

I hope you still find it interesting.

<comment><USER5> there are English subtitles available, you just need to turn CC on in Youtube and click the gear next to to make sure it's set to English.

</comment></comment></comment></comment><comment><USER6> In the other sciences, you strive to take the complexity of the world and to reduce it to underlying principles. In Computer Science, you start with very simple rules and strive to build as much complexity as possible. This is what I really like about demos: they represent what I think makes programming interesting.

<comment><USER7> It seems like we do go in the other direction, too, though. When computer scientists encounter some new problem domain—e.g. rendering photorealistic scenes at 60 frames per second—people analyze the domain into various 'primitives' or underlying principles. We don't have the same notion of 'truth' in selecting a set of underlying principles like you get in the sciences, though, which means multiple sets can survive and be used in different contexts (e.g. using raymarching and distance functions, versus using triangle meshes and Phong shading)—there doesn't only have to be one.

Then at some point, other engineers _use_ those 'underlying principles'/primitives in order you build up particular complex instances of whatever domain was analyzed in the previous stage—but it does start with the science-like analyzing and 'theory building' (not literally—it just has an analogous structure/role).

</comment></comment><comment><USER8> For wanting interested in this stuff, check out pouet.net ([http://www.pouet.net/prodlist.php](http://www.pouet.net/prodlist.php)). They have demos as small as 32b. Most of them have YouTube mirrors and usually they have the executables if you'd like to verify yourself.

<comment><USER9> At first I thought you wrote "32kb" and I was going to correct you.

Note to others: that's 32 BYTES! :)

<comment><USER10> here's an 8 byte demo :> [http://www.pouet.net/prod.php?which=63126](http://www.pouet.net/prod.php?which=63126)

asm file is included

</comment></comment></comment><comment><USER11> If you like this stuff then you may also be interested in an excellent streamer (ferrisstreamsstuff - mentioned in the extra stuff section) who often makes demos:

[https://www.youtube.com/watch?v=V8JXraZPkh8&list=PL- sXmdrqqY...](https://www.youtube.com/watch?v=V8JXraZPkh8&list=PL- sXmdrqqYYeyUpx7BvKXpcw8EbFQLR70)

<comment><AUTHOR> OMG, thank you for this. I love looking behind the scenes in video stream format.

</comment></comment><comment><USER12> These are always so wonderful. The size limitation is the icing, they are always so gorgeous on their own. The advantage is always in seeing what cool tricks they do to make awesome stuff that is defined by such little information.

</comment><comment><USER13> Great article, the demo scene was what got me into programming as a teenager back in the 90s and is still inspirational today!

<comment><USER14> Yup, same here!

</comment></comment><comment><USER15> God it's a beautiful intro. Really like that science fiction like feeling to it!

</comment><comment><USER16> After quickly skimming this article, I got sucked down the rabbit hole of "ray marching" \- in concept, and implementation (mainly as a shader). The idea and how it works was fascinating, if a little above my head mathematically. I got the general gist of the idea, though; it's kinda a combination of ray casting and ray tracing, where you send out the rays and step along them, but in ray marching you don't cast secondary or tertiary (or more rays) like you do in ray tracing (thus limiting the processing, but also the level of realism) and instead continue to "step" (ie - "march") along the ray past the intersection, to gather more information (and thus you can do volumetric stuff with transparency - smoke, water, clouds, marble, skin, etc).

Stepping is done using something called "sphere tracing" \- where for each step along the ray, you compute a sphere, and where it intersects the scene, and only step that far; as you get closer to surfaces, the spheres become smaller (and so do the steps and more computations) - this keeps you from sampling along the ray where there is no scene, and stepping along the ray in larger "jumps" to keep the computational reqs down (it has limitations, particularly along edges of objects, and complex scenes).

For 4k comps (and in general, I think) objects of the scene are described algorithmically (ie - you don't create a model of a sphere or torus or cube, but rather the mathematical representation of it) - so intersects with the ray become a bit trivial. At the same time, complex scenes can become tedious to lay out, so you typically see tessellations and repetitions of scene objects, or other mathematical constructs are used (fractals and the like) that can generate complexity from simple representations (thus, procedural rendering and representational concepts come into play of course).

There was a ton more involved (found interesting shadertoy demos from known authors, going over the concepts of how raymarching and related techniques are used - especially in the context of GPU shader rendering, where it is frequently used in 4k compos - the idea of "two triangle demos", doing everything in the shaders) - and I probably got a lot of this wrong or over- simplified (as I said, I felt a lot went over my head in the math arena).

But I think I got the gist. Regardless, it was a fascinating exploration, and taught me some new things I didn't know about until then; I haven't kept up much with the demoscene since I stopped playing around with my Amigas a long time ago (aside from the occasional amazing demo or whatnot here and there - especially those authors who like to push their Craft - hint-hint - <USER2> microcontrollers). So it was nice to see what "state of the art" was. Although - milkytracker is still being used as well - which is nice to see.

<comment><USER7> I think that's a pretty nice overview you have. One thing I would clarify is about how the objects in the scene are represented mathematically: it's done using 'signed distance functions' so every object you have in the scene is actually created through one of these functions which takes a point in 3D space and returns the distance to the nearest point on the object's surface to that point—which does, as you say, make the object/ray intersection testing trivial (the return value of this function is the radius of the sphere used to step along the ray).

The other basic components when creating scenes to be raymarched are distance functions which combine other distance functions together. The simplest cases are just union and intersection, but it's easy to get more interesting things like smoothly blending objects together. This page is a nice reference of these 'combining' functions as well as distance functions for geometric primitives: [http://mercury.sexy/hg_sdf/](http://mercury.sexy/hg_sdf/) I think that combining power is one of the main reasons to use raymarching/distance functions: building procedural content this way is faaar easier than trying to knit triangle meshes together.

Additionally, if anyone wants to go a little further on the subject of building up sophisticated content by raymarching distance functions, this is an excellent talk on the subject: [https://www.youtube.com/watch?v=s8nFqwOho-s](https://www.youtube.com/watch?v=s8nFqwOho-s)

<comment><USER17> Here is another page on distance functions...

[http://www.iquilezles.org/www/articles/distfunctions/distfun...](http://www.iquilezles.org/www/articles/distfunctions/distfunctions.htm)

...written by one of the authors of this amazing 4k ( _four kilobytes!_ ) demo:

[https://www.youtube.com/watch?v=jB0vBmiTr6o](https://www.youtube.com/watch?v=jB0vBmiTr6o)

</comment></comment></comment><comment><USER18> At first I was surprised they didn't use any assembly language. However, GLSL is their replacement...

<comment><USER19> I wonder how common GLSL is for demos, though; as far as I know you have to have the actual source text and send that to the driver at runtime for compilation. In contrast, shaders for DirectX are AOT-compiled, greatly minimising their size. An executable packer might mitigate that for the most part, although it probably depends.

In this particular case they noted that they weren't size-constrained anyway.

<comment><USER20> Both GLSL and HLSL are very popular, for both 64kB intros and 4kB intros. Even Elevated is storing the actual text in the binary ([http://www.pouet.net/prod.php?which=52938](http://www.pouet.net/prod.php?which=52938)). Compressed text can be quite small.

I wrote a minifier specifically for these use-cases and it has been used in many demoscene productions: [https://github.com/laurentlb/Shader_Minifier](https://github.com/laurentlb/Shader_Minifier) On a 64kB intro like Guberniya, it can save a few kilobytes (but size was not an issue for them) - after compression.

</comment></comment></comment><comment><USER21> Amazing. Brings me back to the 90 and my days with the FUEL coders when putting asm as first line of your demo was the thing to do.

</comment><comment><USER22> 64k + gigabytes of system libraries and GPU drivers.

<comment><USER23> They mostly provide hardware abstractions; I suspect that the intros, if coded in 100% bare metal (Amiga style), wouldn't be that much larger.

<comment><USER24> Indeed. PC 64k intros in the 90s were just as popular. Initially running on MS-DOS but later moving to Windows. Unless you have some memory-mapped interface to the underlying hardware (like the C64/Amiga) you'll always have device drivers, I don't see how that's "less impressive" at all.

It's not like a device driver has an undocumented "MakeAwesome()" call that modern 64k intros are abusing.

</comment></comment></comment><comment><USER25> I thought this was going to be about how to introduce people to investors who put in $64k :)

<comment><USER25> Why is this being downvoted so heavily? Given the forum it seems like a very reasonable expectation.

<comment><USER26> Simply put, it does not add to the discussion. It is mildly amusing a personal quip, that invites no further insight. It is also not relevant to the link, which is not always startup funding related. HN is picky about the commens it promotes, and most of us feel thats a good thing.</comment></comment></comment>


Ask HN: Viable InDesign Alternative? - <AUTHOR>

There's been a decent amount of buzz around Mac apps like Sketch, Pixelmator, Affinity Photo, and others for replacing Adobe apps like Photoshop and Illustrator.
Some have gone so far as to ditch Adobe CC entirely and turn to these new-ish apps exclusively.
My question is: does anyone know of a viable InDesign alternative? I haven't seen one to date and wanted to know if there's one in existence or in the works. <comment><USER2> I haven't found anything that really beats InDesign itself for heavy print work, but I have been using Sketch for web marketing material (brochures, getting started guides etc) and it's worked so far.

I'm using the pixel dimensions of Letter paper, which is not really ideal, but does work if you need to print. Also, when you export your Sketch artboards to PDF, they're huge so I open the PDF's in Acrobat after to create compressed versions.

My workflow is 95% Sketch at this stage. I still use PS for image-editing and I keep Illustrator & InDesign installed, but honestly haven't opened them in months, since transitioning to Sketch.

</comment><comment><USER3> Have you tried Scribus?? When I used to publish a magazine, we started with InDesign and moved over to Scribus. It took awhile to get used to, but once we got it set up, it was extremely powerful!

My email is in my profile - use it if you need help!

<comment><AUTHOR> I have tried it in the past but wasn't too impressed at the time. I may have to give it another go to see if they've upped their game. Thanks!

</comment></comment><comment><USER4> Is not this solvable by using google? ;)

[http://alternativeto.net/software/adobe- indesign/](http://alternativeto.net/software/adobe-indesign/)

<comment><AUTHOR> Yea, been there, a couple of times, but I've yet to find anything "viable" (nebulous term, I know).

Things in common between the three new-ish apps mentioned above is a sleek, simplified UI, all with the essentials when it comes to features.

I've tried a number of the ones on the page you've referenced, but most are too big a step back.

My hope is that there's a Sketch-esque InDesign type app out there that I've missed among the latest and greatest. I'm coming to believe, however, that's only wishful thinking. ;)

<comment><USER4> Scribus is powerful enough. Even magazines are beeing made with it. It is for sure lacking some features when compared Indesign but for every normal user who is willing to learn how Scribus works it offers at least for me everything I need from a DTP program.</comment></comment></comment>


Chernobyl's Literary Legacy - <AUTHOR> http://www.theatlantic.com/entertainment/archive/2016/04/chernobyls-literary-legacy/479769/?single_page=true <comment><USER2> Since it was written in 1971, well before the Chernobyl disaster, it's not surprising that the Strugatsky brothers' _Roadside Picnic_ doesn't appear in the article. The book's theme and narrative are so redolent of Chernobyl, however - telling about perilous journeys into the Zone, an area infested with inexplicable, often invisible, and frequently deadly remnants of some alien Visitation - that the comparison is almost irresistible. Some of the caretakers of Chernobyl call themselves "Stalkers"[1] after the book's name for those venturing into the Zone (and also the name of Tarkovsky's film adapting the novel) for example.

With this in mind, if you've read _Roadside Picnic_ it's hard not to see a reference to it in the article's closing words:

 _For 30 years, authors have heaved their imaginations into the Zone, trying to crack the riddle of the sarcophagus—how to make sense of Chernobyl? Their imperfect answers keep the question alive._

1: [https://en.wikipedia.org/wiki/Stalker_%281979_film%29](https://en.wikipedia.org/wiki/Stalker_%281979_film%29)

<comment><USER3> Ah, that's why the games based in the exclusion zone are named S.T.A.L.K.E.R.: [something]: [https://en.wikipedia.org/wiki/S.T.A.L.K.E.R.:_Shadow_of_Cher...](https://en.wikipedia.org/wiki/S.T.A.L.K.E.R.:_Shadow_of_Chernobyl)

Ah, it's explicit in a paragraph in the intro which I had not previously noted:

 _The background and some terminology of the game ( "The Zone", "Stalker") are borrowed from the popular science fiction novella Roadside Picnic by Boris and Arkady Strugatsky and the 1979 Andrei Tarkovsky film Stalker that was loosely based on it, as well as Stalker, the film's subsequent novelization by the original authors. The term "Stalkers" was later used for the scientists and engineers who explored the interior of Chernobyl's "sarcophagus" after its hasty construction in 1986. In addition, 'The Zone' is also a term used to refer to the 30 kilometer Chernobyl Exclusion Zone, established after the accident._

<comment><USER4> I cannot recommend Roadside Picnic highly enough. Possibly one of the greatest science fiction novellas ever written.

<comment><USER3> Do you have an English translation to recommend? Sounds like I should check it out.

<comment><USER4> This is the best one:

[http://soviethistory.msu.edu/wp- content/uploads/2015/10/picn...](http://soviethistory.msu.edu/wp- content/uploads/2015/10/picnic.pdf)

<comment><USER3> Thanks!

<comment><USER4> Hope you enjoyed it :)</comment></comment></comment></comment></comment></comment></comment>


Flexible Loudspeaker Made of Nanowires Will Stick to Your Skin and Play Music - <AUTHOR> https://spectrum.ieee.org/nanoclast/semiconductors/nanotechnology/nanomembrane-sticks-to-your-skin-and-plays-music <comment><USER2> The first thing I immediately thought was to make a flexible sheet with elements like pixels and wear it for full tactile sensory immersion for VR.</comment>


I'am a startup looking for a billing platform? - <AUTHOR>

Anyone heard of the SeedEdition? They are giving the first $1M in revenue for free. <comment><USER2> Never heard of SeedEdition, sorry.

Chargify has a really flexible structure for configuring how you bill, with an api that lets you hook into it pretty easily.

The main drawback is, at least the last time I looked at them, the cost structure. It very quickly gets expensive, although depending on how much you charge, it might not be an issue.

You can always roll that cost into your actual offering, as well

</comment><comment><USER3> Consider taking a look at Samurai by FeeFighters <https://samurai.feefighters.com/>

</comment><comment><AUTHOR> Blog post on someone using Seed Edition. They sound pretty happy...

[http://mcftechnology.wordpress.com/2011/11/14/seed- edition-f...](http://mcftechnology.wordpress.com/2011/11/14/seed-edition- finally-light-at-the-end-of-the-tunnel-for-subscription-billing/)

</comment><comment><USER4> Check out some of the apps here <http://whebsite.com/wiki/Startups#Finance_and_accounting>

</comment><comment><AUTHOR> Thanks everyone. Ya I have been hearing SeedEdition has the same features as Chargify. I will definitely look into everything.

</comment><comment><USER5> <https://stripe.com/>

<comment><USER2> Correct me if i'm wrong, but isn't stripe more of a payment gateway, where as what hes asking is more about structuring recurring billing based on a contract?

In other words, he could actually do the charge through stripe, but he couldn't generate the invoice by which he comes to the amount that he charges.

Maybe i'm wrong.

</comment></comment><comment><USER6> What's a link to the SeedEdition website?

<comment><AUTHOR> www.seededition.com</comment></comment>


Have we reached Peak Dog in our cities? - <AUTHOR> http://www.treehugger.com/pets/have-we-reached-peak-dog.html <comment><USER2> I live in Chicago, where there are a zillion dogs, and I feel honestly like the history of humanity will one day be rewritten to clearly and correctly explain that human beings were in fact domesticated by dogs so that we work to support and feed them. People spend more to support their pets than most people in developing countries make. It's ridiculous.

</comment><comment><AUTHOR> I smell an opportunity...</comment>


Epidermal Electronic System (EES) Tatoo - <AUTHOR> http://www.engadget.com/2011/08/12/ees-packs-circuits-into-temporary-tattoos-makes-medical-diagnos/ creepy! <comment><USER2> Better article:

[http://news.sciencemag.org/sciencenow/2011/08/electronic- ski...](http://news.sciencemag.org/sciencenow/2011/08/electronic-skin-grafts- gadgets-t.html?ref=hp)

Abstract of paper, + full text if you have access.

<http://www.sciencemag.org/content/333/6044/838.abstract></comment>


Ask HN: Possible to publish a paper without graduate degree? - <AUTHOR> Forgive the naive question, as I know many of you have at least one graduate degree.
One of my favorite courses during undergrad was one on how to read papers and journals, and the vigor that goes through them.
Not that I fancy myself as being on the same level as those in professional research, I have a niche where I've tossed the idea around of beginning the years long approach to increasing the boundary of knowledge in a very tiny way with a paper. Is there any chance of it even getting read though without a PhD? Let alone, published? <comment><USER2> Yes! Conferences in CS have increasingly begun to adopt a double-blind approach to reviewing papers, meaning that you won't know who the reviewers are, but neither will they know who you are or your credentials.

This way, as long as your paper is well written and clearly presents a worthwhile idea, there is no requirement to having a graduate degree.

<comment><AUTHOR> That's great because it would be in CS.

</comment></comment><comment><USER3> As others have said, it's perfectly possible to get published without a PhD. I had a paper published as an undergrad and I have helped a couple of people, who worked for me in industry, get published.

I haven't tried it but I would expect that getting published on your own, and without prior experience of publishing, will be quite hard. There are a fair number of, often implicit, conventions that you're expected to follow.

My recommendation is to ask someone, at a university, who has published in your field to help. Or suggest someone to help. My experience of doing this has been positive but I appreciate that that is very anecdotal. This can work because they'll be named on the paper too so it's potentially beneficial for both parties.

BTW if you don't know of anyone in that position, that would be symptomatic of an issue that you'll have getting published. You'll be expected to have a reasonable understanding of the state of art in the field and be able to cite it. If you're not already in that position I would strongly recommend that that be the first thing you do.

Good luck. Hope it works out for you.

<comment><USER4> I agree. I was just going to write this. [My version would have been less articulated.]

I want to add a small warning: There are many "predatory journals" that will charge you to publish whatever rubbish you want to publish. Avoid them because they have no real value.

</comment></comment><comment><USER5> I think it's certainly possible; depending on your subject niche, you may even be able to cultivate a rapport with academics in the field you are interested in. For the sake of discussion, let's say you enjoy _pastry filling optimization_.

Reach out to those academics who study _pastry filling optimization_ at a variety of institutions. Most won't get back to you, as a professor/academic's day job is busy and requires more than simply conducting research. This isn't out of malice so much as an accident. Heck, some professors I am taking classes with miss my emails!

Eventually you'll build up a relationship with a few who have returned your emails (or Twitter DMs). At this point, you could suggest collaborating on a paper together. Most will probably decline, but there is a nonzero amount of academics more than willing to collaborate with anybody, given they know you have your wits about you. That is, so long as you don't come across as a _pastry filling optimization_ crank. :)

<comment><AUTHOR> This is excellent advice and very encouraging!

</comment></comment><comment><USER6> In my opinion, if your paper has content, it should not be difficult to publish it. Degree or not, the end result what everyone wants is high-quality content.

<comment><AUTHOR> That's excellent, thank you.

</comment></comment><comment><USER7> I wrote and published two papers while working on my bachelor's degree, so it is definitely possible.

</comment><comment><USER8> Depends if you want it in a journal or not. Publish anything using [https://leanpub.com](https://leanpub.com)</comment>


Ask HN: Do we take the relief money? - <AUTHOR> Local politicians are urging all entrepreneurs to start applying for aid. But we're not a local beloved coffee shop. You know the old joke that entrepreneur as a job means unemployed? That's kind of us before and now. The tech is real and we are paying local people, there just was no Stanford incubator. I don't have impostor syndrome, I just don't know what to do. I haven't even incorporated yet. It feels real and we need the relief money desperately. But would we be stealing from older more well known businesses that equally need it? What happens when hucksters start applying for aid? I know half the readership does startup, so are you applying for aid? It feels like it should go to local retail, but entrepreneurs gonna entrepreneur. <comment><USER2> Decent people like you who ponder the question are especially the ones taxpayers want to take the money.

A few years ago, a friend of mine was laid off. It had been two months and I was talking to him about his situation. I asked: SO how much do you get from unemployment?

Friend: Well I have not applied for it.

Me: Why not? It is there for exactly your situation.

Friend: I am not desperate yet, and I think others need the money more than I do.

Me: Stop being an idiot! Get the damn money! You are not doing anyone else a favor by not getting it. In addition you dwindle your meager savings down.

Moral of the story: You will not prevent someone who deserves it more from getting the money. You will probably keep some politician from pocketing it as a campaign donation.

<comment><AUTHOR> Thank you for this perspective. And thanks for calling me decent. I actually was your friend with the unemployment. I lost a job and someone paid me under the table to build some stuff for them. It didn't feel right doing both at the same time so I didn't do unemployment. Kind of dumb of me.

<comment><USER3> Safety nets exist to catch you, not to shame you. Always take all of the help you can get. There is no extra credit for making life harder needlessly.

<comment><AUTHOR> Thanks Yoda. No, I mean seriously, you just dropped some gems.

<comment><USER3> Prevent the suffering of others, we must.

</comment></comment></comment></comment></comment><comment><USER4> My personal stance is that a lot of small businesses should close down. They're not doing well, they're not paying well, customers give them money not because the product is good but because they're supporting businesses. They have a poor future for themselves and their employees, they're not happy, and are dealing with sunk cost, pride, and family pressure.

If you're in that group, don't take the money. Close down and blame the lockdowns.

If you're not in that group, take the money. If your business is growing. If you're planning on paying staff well instead of skirting labor laws. If you make products that improve someone's life, and want to use that money to make more of such products.

But personally, I don't need the relief money so I procrastinate on it a bit, in case it's limited. It puts me at the bottom of the pile when it goes through, so if they have to pick one out of two, it deprioritizes me.

</comment><comment><USER5> You should contact you local Small Business Administration office. They will be better able to direct you to both disaster assistance and Covid 19 support funds, which are low-interest loans with suspended repayments for the first year. To be eligible for funds in Indiana the business needed to be incorporated by January 31, 2020, but I don't know about other states. Your SBA will be best able to direct you. Our newly founded farm is eligible and we are making the call today.

</comment><comment><USER6> isn't the aid mostly low or zero percent loans? That's what the discussions were anyway.

As long as that's the case, what are you hurting if you take it? It's just free money to help your business along, and businesses like yours are what drive the economy and pay people's salaries.

<comment><AUTHOR> I actually do employ people. They just don't have health care plans. Also, some dumb scarf store that loses money every year will file for this and get it. Why not us?

<comment><USER6> That was my point -- you're employing people, you're building the economy, take the money. That's the whole point.

</comment></comment></comment><comment><USER7> Take it.

<comment><AUTHOR> The problem is how do you prove a loss of business? Startups are always losing money, but this situation intensifies things. But then again the cruise ship industry that doesn't pay US tax is getting bailed out. Why is this so complicated?

<comment><USER8> > But then again the cruise ship industry that doesn't pay US tax is getting > bailed out

[citation needed]

What I've been reading is the opposite, like [0].

[0] [https://www.miamiherald.com/news/business/tourism- cruises/ar...](https://www.miamiherald.com/news/business/tourism- cruises/article241547471.html)</comment></comment></comment>


Even Monkeys Can Build Websites Now - <AUTHOR> https://medium.com/swlh/even-monkeys-can-build-websites-now-f0aabf25fb6a <comment><USER2> Yeap, that's true. Personally, I only use drag and drop, hosted website builders just because they don't require any technical skills, so I didn't have to code. You can find some good tips here [https://www.webbuildersguide.com](https://www.webbuildersguide.com)

</comment><comment><USER3> Shorter TFA: "Why would you want a self-contained website for your business when there's so many different companies that _probably_ won't squeeze you for money after you're totally dependent on them"

<comment><AUTHOR> Because reliance is the Mother of great leverage?</comment></comment>


Inclusivity Is a Joke - <AUTHOR> https://medium.com/@hasharray/inclusivity-is-a-joke-32d0e10c65cb <comment><USER2> Inclusivity is one of those things that you just have to do, and not talk about. I sincerely hope the irony of excluding this man in the name of inclusivity is not lost on the crowd. What a mess.

I think more people would do well to practice the tolerance and acceptance that they preach. As a gay man, I've run into my fair share of loud mouthed, biggoted people, who say incredibly mean things about me without realizing that they're affecting someone in the same room. A good deal of my friends are Christians, and a good deal of my family is as well. At least in our churches, being gay is considered quite a heavy sin. Somewhat intuitively then, when I came out to my family, I was simultaneously declaring that I would no longer be a part of their religion.

And you know? We didn't fight about it. They understand my limitations, and I still love them. I'm still friends with my Christian friends, and I'm still on great terms with my family. We disagree on certain things but that's OK, because they've learned to see the good in my unique outlook on life, and I've learned to understand the love tolerance that their Jesus teaches, because I watch them practice it every day. We've learned to accept one another, despite our differences.

Inclusivity is not hard, but it starts with avoiding conflict. You're going to have to tolerate that which occasionally offends you, and learn to let it go. Learn to love people despite their flaws, because goodness do people have flaws. We're not perfect. Nowhere near it. But all people still have some good in them, and it's worth making the effort to see past that which you dislike to appreciate the human being underneath it all.

<comment><USER3> I don't understand what straight men have against gay men. They should be happy, because that means less competition. ;)

<comment><USER2> I think the idea that another man might find them attractive is a source of discomfort. When I came out to my straight friends, almost all of them asked me if at any point I found them attractive, and were visibly relieved when I informed them that I did not.

<comment><USER3> I suppose even if you are attracted to one of them, you might not admit it, because that could make thinks awkward between you in the future.

So they ask you, not because they want to know the truth, but because they want your assurance that nothing will change in the relationship between you.

</comment></comment></comment></comment><comment><USER4> The part of this article that highlights what Douglas Crockford did to get him removed from Nodevember is fine. A bit boring, but fine.

The part of this article that generally hand-waves towards "inclusivity" as a movement and dismisses them as people with "unicorn-colored hair" is frustrating. There's little here that actually discusses the issue. It points out a couple of things that Douglas said, trivializes the issues that the inclusivity group cares about, and seems to make its primary point by arguing semantics (oh, look, the inclusivity group excludes people, har har).

I get that its an opinion piece, but there's nothing of substance here that I could possibly disagree with, because it's not defined. If you want to get a bunch of people agree with you and give you internet points, it's spot on. But there's not a lot here that's interesting if you're not already on board with this point of view.

<comment><USER5> It's worth noting that the details of the reasons Crockford was uninvited have not been confirmed by any of the parties. This article takes speculation from elsewhere as announced truth and proceeds to dismiss inclusivity as a goal on that basis.

<comment><USER6> Here is a good update I missed: Formal statement from Nodevember[0]

[0] [http://nodevember.org/statement.html](http://nodevember.org/statement.html)

<comment><USER7> "While we have a tremendous respect for Mr. Crockford's abilities as a speaker and his contributions to our craft, we became aware that based on private feedback - not simply the dialogue on Twitter - that his presence would make some speakers uncomfortable to the point where they refused to attend or speak."

Any speakers who are made "uncomfortable" by Crockford's presence are pretty much guaranteed to be the sort of speakers who don't bring anything to your conference anyway.

"We are in over our heads."

Well, that's certainly the truth.

I also notice that while they apologized so unreservedly, they didn't go so far as to reinvite Crockford.

</comment></comment></comment></comment><comment><USER6> Sometimes I wonder if these groups are false flags. I know they aren't, but perhaps it is better to say they are their own parody. There are serious issues out there, discrimination is alive and has been demonstrated in studies, statistics, etc. Garbage like this makes a mockery of the whole thing, the real hurt and issues gets mixed in with this trash and gives some people, I'm sure, solace that all of it is just a tempest in a teapot, and there are no real issues out there.

Groups and fake controversies like this distract from _real_ issues of discrimination. They do more harm to inclusive movements than good.

<comment><USER8> As much as I'd like to think this is true, I don't think it's plausible. It would require a conspiracy of epic proportions.

It's a flaw in human psychology that is related to [https://en.wikipedia.org/wiki/Narcissism_of_small_difference...](https://en.wikipedia.org/wiki/Narcissism_of_small_differences)

Another aspect is that as that any idealistic movement is prone to being taken over by it's most intractable members. There's a game theoretic spin on it by Nicholas Taleb if I remember correctly: [http://www.fooledbyrandomness.com/minority.pdf](http://www.fooledbyrandomness.com/minority.pdf)

As the emotional tone of a debate is heightened, it's hard to argue for moderation. Anything that pushed emotional buttons forces people to the extremes and those arguing for compromise are often ridiculed by both sides.

Therefore we have the phenomenon that many debates end up being between over- the-top SJWs on one side and crazy racists and Red Pill types on the other.

And back in the real world, there is still indisputable injustice and discrimination that would be eminently tractable if everyone would come back down to earth.

EDIT - I'd like to point out that I'm aware of a major flaw in the above - _everyone_ \- myself included regards themselves as a reasonable moderate and others as dangerous extremists. I suppose I'd be quite content to be regarded as a flakey liberal by my friends on the right and a closet imperialist by those on the left. (Except - what happens if the sample of my social group is heavily skewed and my 'left/right' is off the scale? And down the rabbit hole we go...)

<comment><USER9> Everyone is a moderate; people reposition the callipers around their social group, defining people into and out of it, so as to always stay its most central and reasonable example.

</comment></comment></comment><comment><USER10> See also:

"In defence of Douglas Crockford" [https://news.ycombinator.com/item?id=12422420](https://news.ycombinator.com/item?id=12422420)

"Crockford" [https://news.ycombinator.com/item?id=12425061](https://news.ycombinator.com/item?id=12425061)

</comment><comment><USER11> I consider myself an ally on most social justice issues. The kind of abuse heaped on women online is unconscionable to me. Not to mention Black Lives Matter where people are actually dying because of systemic prejudice. So you have those issues on one side, there are a lot of them and we need to work on them as a society.

A step down from that big stuff, you have crass offensive behavior like sexual innuendo in conference talks and other things that can pretty readily be identified as going to make a lot of people uncomfortable. It makes sense for professional conferences to have policies against those things.

Then you have this long tail of ways that a person can be offended by subtle interpretations that are impossible to wholly avoid by premeditation except through sheer paranoid blandness. This is the bucket where it seems like this Crockford nonsense falls, and this is also where the movement loses my support. They've crossed the line from helping people to just reaching for the torches and pitchforks, and completely lost the thread that liberalism was once about _tolerance_.

<comment><USER6> I feel that these people do not and should not speak for liberalism. The are like the Alt-Right, they are an extreme fringe which give the movement and causes (very important causes) a bad name.

</comment></comment><comment><USER12> Inclusivity is an attempt to ban certain kind of speech. I have found that these people are downright religious in their zeal. Example: [https://github.com/nodejs/inclusivity/issues/9](https://github.com/nodejs/inclusivity/issues/9)

I'm not even going to comment further on this, I have found that arguments, sanity and reason do nothing here.

<comment><USER13> Of course there's a subreddit for these GitHub issues written by SJWs. [https://www.reddit.com/r/GitInaction/](https://www.reddit.com/r/GitInaction/)

I think it's striking how these people seem to be on a crusade, often they don't even seem to be users of the code in question and often barely developers at all.

<comment><USER14> The intention is to take over and subvert the organisation into a platform for there activism. The goals and tactics including codes of conduct are premeditated. Its a trojan horse technique called entryism used by radical leftist political groups.

[https://en.wikipedia.org/wiki/Entryism](https://en.wikipedia.org/wiki/Entryism)

</comment></comment></comment><comment><USER15> I liked it much more when open source was about the code and not the people behind it. Nowadays I worry that I might be called out for using a piece of code (however good it might be) just because the person who wrote it does not use "inclusive" language.

<comment><AUTHOR> AFAIK, this only affects the JavaScript-based communities.

I sincerely doubt one would find anything remotely similar in C++, Linux (C lang), or Assembly-programming communities.

The "harder" the language the less non-coding politics around.

<comment><USER16> When you have two people, you have politics. Nerds just have this ridiculous social signal where they have to pretend to be above it.

<comment><USER17> I sincerely do believe that as technology has become more accessible and more "normal" people get into the industry, this has lead to things being more about politics and less about solving problems. Sometimes I even think that ordinary people like arguing and drama and willingly misunderstands each other just to not get bored. True aspie-nerds don't need this, they have other interesting things to fill their head with.

<comment><USER18> Alternatively, is it possible that "normal" people have problems that are generally not encountered in the experience of "aspie nerds"?

The necessity of Unicode is a great example of how a seemingly-straightforward technical design can prove inadequate once it needs to serve the full set of humanity.

</comment></comment></comment></comment></comment><comment><USER19> Some people hear someone say X, put the most sickening meaning into it, get offended, cry on twitter. Pretty sure "saying X" is not the problem here.

</comment><comment><USER20> Anecdotally, this seems to be a stronger thing in Node.js community than others. I recall on occasion on the Node channel on Freenode when I got chewed out by the ops+ for not being inclusive enough with a casual "later, guys" (or "later, dudes").

(+ bona fide opped ops, notwithstanding the Freenode "low channel temperature" guidelines)

<comment><USER21> >Anecdotally, this seems to be a stronger thing in Node.js community than others.

I have seen people speculate that this is due to the lower barrier of entry in the JS community (as a whole), although I'm not certain how true this would be.

<comment><USER22> there's a pretty low barrier to entry in the PHP world, and I don't think we've seen anywhere near the same level of scrutiny.

<comment><USER23> Well I think PHP has fallen out of favor for Node among the "I wanna program" crowd. Of course this whole "social justice" shit-show is a more recent thing so all the heat is in that community, leaving PHP out of the festivities.

</comment></comment></comment></comment><comment><USER24> Paul Graham's Essay on 'What You Can't Say'

[http://www.paulgraham.com/say.html](http://www.paulgraham.com/say.html)

</comment><comment><USER25> Some people in the developer community need to get better at recognizing when a witch hunt is brewing. This blog post has essentially the same content as the one yesterday on the same subject[1].

Like the one yesterday, it attempts to provide its own explanation for why Crockford was disinvited as the keynote speaker. However, none of these details are mentioned in the actual statement given by Nodevember[2], and there are no sources given for how this explanation was arrived at. The Nodevember statement claims he was disinvited based on some public and private feedback from speakers who felt uncomfortable attending with him as the keynote speaker. Why should we take it on face value that the circumstances documented here are actual set of circumstances that lead to him being disinvited? Where is this information even coming from?

One of the alleged sources is a blog post from Kas Perch[3]. The alleged slut shaming incident seems to be a minor note in a post otherwise focused on his negative and dismissive attitude towards some of the other speakers. Perhaps this is the more salient part of why this person felt uncomfortable attending with him? Perhaps there's more feedback being kept private to protect the witch hunt from targeting those coming forward?

Notably I haven't even seen a statement from Crockford crying foul over this incident. It seems to be coming entirely from other Node developers upset about the fact that he was removed as the keynote speaker. It seems like this is an argument being played out as a proxy over political stances about diversity and inclusion tactics, without a lot of consideration for the actual circumstances. Furthermore I find it very disappointing that this poorly substantiated argument is being used to demonize inclusivity and diversity overall, which is something badly needed in developer communities.

[1]: [http://atom-morgan.github.io/in-defense-of-douglas- crockford](http://atom-morgan.github.io/in-defense-of-douglas-crockford)

[2]: [http://nodevember.org/statement.html](http://nodevember.org/statement.html)

[3]: [https://medium.com/@nodebotanist/why-i-won-t-be-speaking- at-...](https://medium.com/@nodebotanist/why-i-won-t-be-speaking-at- conferences-with-douglas-crockford-anymore-61bc29f028c8#.b640mips1)

<comment><USER26> > on some public and private feedback from speakers who felt uncomfortable > attending with him as the keynote speaker.

So you want to say, that there doesn't need to be a real reason anyway, it is just enough that a few other speakers have a problem with him. It doesn't even have to be made transparent what the problems actually is.

And you believe that this kind of closed door denunciation will result in a better, more inclusive world?

And that Crockford doesn't respond to this hypocritical nonsense is a kind of confession of guilt?

<comment><USER25> > So you want to say, that there doesn't need to be a real reason anyway, it > is just enough that a few other speakers have a problem with him. It doesn't > even have to be made transparent what the problems actually is.

No, what I'm saying is you (and everyone else) aren't owed an explanation, and furthermore there are good reasons for not offering a public explanation.

> And that Crockford doesn't respond to this hypocritical nonsense is a kind > of confession of guilt?

No, I'm acknowledging that this is a lot of frenzy being whipped up when the party directly affected by the decision hasn't released a statement questioning their motivation. He may have been given an explanation and has chosen not to make an issue of it for all you know. The only people seemingly angered by this decision are people who aren't affected.

<comment><USER9> > No, what I'm saying is you (and everyone else) aren't owed an explanation

Conferences are for-profit things, yes? Companies don't owe their customers anything, but if they don't _give_ their customers anything, then customers don't have any reason to give the company their money.

Or, to put that another way: a conference about Javascript that kicks out Douglas Crockford is pretty much in a default state from the moment they decide to do so of "so why should anyone attend this?" until they provide an explanation that serves to ameliorate the bozo-bit they just seemingly flipped.

</comment></comment></comment></comment><comment><USER27> Yes, one of life's harsher lessons is just how vicious Unitarians can be.

<comment><USER28> "Other grain."

</comment></comment><comment><USER29> Donald Trump:

\- "[Mexican immigrants are] bringing drugs. They're bringing crime. They're rapists."

\- "Rosie [O'Donnell] is just disgusting --- she's fat, she's a loser. She's a farm animal pig. She's a beast, ok. She's just a loser. She's no good."

RESULT: _Just might get elected US President in November!_

Obscure JavaScript geek:

\- "blah blah ... promiscuous ... blah blah ..."

RESULT: _Removed from speaking at some JavaScript conference in November._

These inclusivity people need to look around a little and have a reality check. Their incredibly narrow standard for what is acceptable is not even remotely shared by the American society they live in.

</comment><comment><USER30> The statement of the organizers doesn't give a very detailed reason why they didn't want him giving a keynote at their conference and it certainly doesn't say it was over a tweet or using the word 'promiscuous'. That part seems to be much-repeated speculation that does nothing but fuel outrage.

</comment><comment><USER29> You can put a network adapter into "promiscuous mode".

[https://en.wikipedia.org/wiki/Promiscuous_mode](https://en.wikipedia.org/wiki/Promiscuous_mode)

This causes it to disappear all night and crawl home at 11 in the morning with a hangover.

<comment><USER29> Hmm; I didn't think that was a good comment and am positive I deleted it.

</comment></comment><comment><USER31> The number of people who go around looking for ways to be offended is seriously troubling and a fat greater theeat to humanity's advancement.

If someone has something to teach me, I don't care what he does outside of the conference -- if he uses gender biased words or votes for evil bunnies, I'm not there to talk to him about those things.

It was better when people knew how to comparatamentalize work and politics and religion and all the other stuff that's personal and not relevant to the discussion at hand.

</comment><comment><USER32> If this is true, it is both ridiculous and terrible.

</comment><comment><USER14> I think the takeaway is that when you set up a group within your organisation to promote 'inclusion' or 'diversity' you open the door for entrism by seasoned radical activists who have an agenda. An attempt to include 'marginalized' people by excluding everyone who fails there ideological purity test is simply a witch-hunt tactic to consolidate power and subvert the direction of the organisation.

everyone has to be more diligent to protect there projects and communities form these corrosive people.

[https://en.wikipedia.org/wiki/Entryism](https://en.wikipedia.org/wiki/Entryism)

</comment><comment><USER33> Question: Is that Tweet Libel?

> "We will also be removing Douglas Crockford from our keynote speakers list > to help make the conference a comfortable environment for all." \- > Nodevember Tweet

The implication is he creates an uncomfortable environment.

Libel?

</comment><comment><USER34> We only need the one story on this on the front page, and it's here:

[https://news.ycombinator.com/item?id=12422420](https://news.ycombinator.com/item?id=12422420)

</comment><comment><USER35> pastebin of a nodevember slack channel discussing the incident:

[http://pastebin.com/3mQc7DfG](http://pastebin.com/3mQc7DfG)

Source: [https://www.reddit.com/r/javascript/comments/50u77r/douglas_...](https://www.reddit.com/r/javascript/comments/50u77r/douglas_crockford_removed_as_a_keynote_speaker_at/)

</comment><comment><USER36> Inclusivity is so last year. Look how well Trump is doing. Trump brought intolerance out of the closet. Like him or not, he's changed American politics.

</comment><comment><USER37> I'm guessing even the hardcore Victorians would consider this whole thing "a bit much".

</comment><comment><USER38> > _Well, it basically came from some very vocal bullying from "inclusivity" > folks, incidentally also a part of the Node.js inclusivity group._

The problem with "inclusivity groups" is that they have to find work for themselves -- even if that means busywork.

</comment><comment><USER39> This post is currently in page four where it's the most recent post of the page (by a large margin) and the third most upvoted post in the page. Sometimes it's weird how algorithms work.

</comment><comment><USER40> Node•vember? Or No•dev•ember?

Seems like it's trending towards the latter.

</comment><comment><USER41> It seems the SJW movement became a new form of inquisition. What's terrifiying is it actually convinces in real life.

</comment><comment><USER42> > No, inclusivity is not about banning speech

> Sometimes that means enforcing certain standards of speech

Do you hear yourself? The cognitive dissonance is incredible.

<comment><USER43> Sigh. What I obviously meant (btw, you should read up on the Principle of Charity [0]) is that banning speech is not the goal, it's a means to an end, and one that society has already largely accepted.

Enforcing a certain level of civility in a given place of discourse isn't "banning" and it isn't a free speech issue. It's a basic prerequisite for human interaction.

The "inclusivity" movement is just trying to extend that concept to be sensitive to groups of people that historically have not felt comfortable in certain technical environments.

Argue about the implementation if you like, but please don't assume bad faith on the part of everyone who tries to make tech a more welcoming place.

[0] [https://en.wikipedia.org/wiki/Principle_of_charity](https://en.wikipedia.org/wiki/Principle_of_charity)

<comment><USER44> I think we're conflating all kinds of stuff here.

In small social groups, the group norms around certain behaviors. That's normal. It's also normal that different small social groups will have different norms.

As a personal matter, don't be an asshole. You shouldn't say things to others to deliberately hurt them. The principle of charity is valid here as well, by the way. Sometimes people are hurt because even though you mean well, they take things the wrong way.

In larger groups, probably somewhere around Dunbar's Number, it becomes inevitable that norming will not work -- nor _should it work_. That's because larger groups of people naturally become echo chambers full of groupthink. It's imperative to have voices and opinions that some find harsh. c.f. On Liberty

These are three separate issues. They are related, yes, but one doesn't trump the others. Society needs all of this to function well.

ADD: One of the interesting things that happened with the invention of the television was that _there was no more adult talk anymore_. Adults said that in the past, there was plenty of time when the kids ran off and the grown-ups talked about more mature topics.

The TV took every kind of conversation and threw it into the middle of the living room with your 4-year-old. (Or 15-year-old, for that matter). Adult talk radically changed.

Perhaps the net is doing the same thing with small social groups -- eliminating them as a place where local norms can be far outside what most people would find polite. Everything now is just in one big bucket. If so, it promises a more radical change to human society than anything we've seen so far.

<comment><USER45> You make a great point about TV. I'd like to go farther.

We've evolved to function in small tribal groups, and that we instinctively want to do so in all sorts of contexts, be they political, economic, etc. But the fact is that the incentives that allow this to work on a tribal scale break down when we try to apply them so broadly. F.A. Hayek argues that this is a big part of the "Fatal Conceit" through which socialists wrongly believe that they can successfully manage an economy (and thus a society).

<comment><USER44> Yes, it's the same fallacy just in a different context.

I feel like mankind is having final exams and although we were given all the answers, none of us have studied very much. Whether it's the efficient allocation of resources, the nature of public versus private discourse, the necessity of reproducibility in science, or the overuse of aggregate data and correlation as a proxy for causation -- there are a bunch of fundamental topics we all need to be on the same page about. This is because they're all converging together as we as a species converge together online.</comment></comment></comment></comment></comment>


Embracing SQL in Postgres - <AUTHOR> http://rob.conery.io/2015/02/24/embracing-sql-in-postgres/ <comment><USER2> My CTO wrote custom PostgreSQL functions to generate all the JSON that our API returns. First time I saw it, I said "Holy crap, that query is two pages long. You could just tell Rails to serialize the object in 3 lines of code." He replied "I know. That's how we did it at first. But generating the JSON directly in postgres is about 700x faster."

Eventually we even moved a very complex scoring algorithm from an overnight Hadoop Java process, into Postgres as a compiled extension in C. We used to spend all night calculating those scoring results and caching them in an enormous table. But with the Postgres+C solution, we could calculate and store it _in realtime_ by having Postgres do the hard part.

<comment><USER3> You can skip the web tier entirely and have Pg returning JSON documents via an HTTP endpoint to a rich MVC js browser application that synchs to a local cache.

Thus re-inventing Lotus Notes.

<comment><USER4> I like OpenRESTy for such endpoints; YMMV.

But I refuse. REFUSE. to re-invent Notes.

<comment><USER5> I haven't used it yet but postgrest looks awesome for this.

[https://github.com/begriffs/postgrest](https://github.com/begriffs/postgrest)

<comment><USER4> That looks like a good tool, but have you met nginx before? I sorta view OpenRESTy as a reason to sneak nginx into my stack. :)

</comment></comment></comment></comment></comment><comment><USER6> Very happy to see all of this talk over the past few months on the power of modern--or anything beyond basic--SQL.

This article touches on one of my favorite things, too, which is built-in date and time arithmetic. That's something that basically just works and comes for free in the database but is often a hodgepodge of messy third-party libraries elsewhere.

The other enormous one, for me at least, is arbitrary precision math. Proper precision, rounding, division, and exponentiation isn't easy to come by. I'm so tired of dealing with libmpdec, BigDecimal (flimsy as it is), GMP, etc. It all works well in the database and it's pretty fast. Perhaps it's not suitable to 1000-digit scale scientific computing, but it sure does make building financial software easy.

</comment><comment><USER7> In Ruby World, Sequel ([http://sequel.jeremyevans.net/](http://sequel.jeremyevans.net/)) probably gives a bit of best of both ORM and direct SQL use, because what it really does is an object-oriented ("native" to language) interface to SQL database. And yes, it can build models like ActiveRecord, too!

In Common Lisp, postmodern ([http://marijnhaverbeke.nl/postmodern/](http://marijnhaverbeke.nl/postmodern/)) serves a similar role, with both DAO and lower-level access methods that compose pretty well. The 'perec' ORM from DWIM project was based on Postmodern, and among some weirder things I did quite easily was embedding custom SQL into query builder, so that the object-based accesses would use the advanced SQL. Really nifty feature :)

</comment><comment><USER8> _One thing that drives me absolutely over the cliff is how ORMs try so hard (and fail) to abstract the power and expressiveness of SQL._

I agree with this. It's nice to deserialise a DB row into objects, but actually _querying_ with an ORM is usually terrible and people should not be afraid to write smart queries. Especially like those in sibling comment [https://news.ycombinator.com/item?id=9112036](https://news.ycombinator.com/item?id=9112036) : date/time/arithmetic.

<comment><USER9> > actually querying with an ORM is usually terrible

What do you think of stuff like Hibernate Query Language? I'm currently working on a project that might use DQL (a PHP variation) to get our snarl of tables under control.

<comment><USER10> The fact that Hibernate Query Language even exists tells you that ORM is a bad idea.

<comment><USER11> That makes absolutely no sense.

The whole point of ORM is that it is database agnostic. Given how different databases twist the SQL standard and provide a whole raft of proprietary extensions you need an abstracted query layer.

Whether you give it a name like HQL or don't there will always be some layer.

<comment><USER12> I hope that's not the whole point of an ORM given how pervasive they seem to be in every project and how few any given projects ever switch their backend out. Choosing an ORM because it abstracts you away from the storage engine seems like a terrible reason.

I agree with Conery, choose the components that will compose your application wisely and then embrace those choices and use them to their fullest.

</comment></comment></comment></comment></comment><comment><USER13> Even though I think it's important for developers to have some understanding of the underlying SQL, I still believe a good ORM can save time and make code more readable. I think SQLAlchemy does a good job here - and it's close enough to SQL such that you are typically not surprised by the SQL it produces.

For more complicated queries, I often hand write them in SQL first and then translate them into SQLAlchemy's methods. It's still worth it, since it's both easier to build dynamic queries (e.g. dynamic WHERE clauses) and it makes the parameterisation trivial.

My problem with stored procedures is that you can end up with a lot of business code in the db.

<comment><USER14> Why is it that the DB is the correct place for business data, but not for business code?

Of course, even for practical reasons, it's important to keep the DB lean. But some code does really belong toghether with the data.

<comment><USER11> Sorry but putting business code in databases is a terrible, terrible idea.

(a) Oracle, Microsoft, Teradata etc all charge through the roof for scaling out your database. Which of course you're going to need to do if you're adding more and more business code. Scaling out normal code ? Cheap.

(b) What happens if you exceed the capabilities of your database (yes it happens). Then you have a major project on your hands migrating both data and code.

(c) The platform for developing/executing your business code in the database is like going back to the 1980s compared to the new flexible, microservices world we live in today. Really stored procedures over NodeJS, Scala, Go etc ? Performance isn't that important in businesses where most processes are batch orientated.

(d) Databases in businesses are as tightly controlled as they get. As a developer would you want to have to go through laborious change management processes every time you push a commit ? It would cripple software development teams.

There is a reason why "data lakes" are all the rage right now. Because people need cheap places to store and process their data and then use their SQL database simply for querying and reporting.

<comment><USER14> (a) Yes, databases scale badly. You don't want to run your entire application there. Yet, code that reads a huge volume of data, calculates something based on parameters, and write it back to the DB will put more weight on your DB servers if it's run from the application layer; code that enforces the consistency of the data needs a strongly enforced policy if you keep it in any other place, but it works completely transparently if you place it in the database; code that denormalize the data will be much easier to use if you can run directly on your queries...

(b) Been there, done that. Migrating code is EASY. Data is what's hard.

(c) Is that a joke? Honestly, I can't tell.

(d) That's more a reason to integrate those teams than to choose one place over the other. The programmers can disrupt the database on several ways without putting code there, and don't get any extra power by running their code in a different server.

By the way, the data that was famously leaking recently was mostly from email and file servers...

</comment></comment></comment></comment><comment><USER15> For context, the author Rob Conery wrote SubSonic - one on the first opensource ORM for .Net which was very popular at the time. [http://en.wikipedia.org/wiki/SubSonic_(software)](http://en.wikipedia.org/wiki/SubSonic_\(software\))

</comment><comment><USER16> I never got that much sold into ORMs when doing anything more complex than plain CRUD, I rather use the expressiveness and performance of plain SQL and its associated procedural extensions.

<comment><USER17> One thing you get with a good ORM is composability, though. Trying to build dynamic SQL queries with raw strings is a nightmare.

Another, less useful property, is a considerable reduction of boilerplate when persisting a complex object graph.

<comment><USER16> > Trying to build dynamic SQL queries with raw strings is a nightmare.

Create the optimized version in a SQL editor, then use the builder pattern to fill in the holes in the query.

Much less boilerplate than any ORM tool generates.

> Another, less useful property, is a considerable reduction of boilerplate > when persisting a complex object graph.

That depends how expressive is the application language's meta-programming capabilities.

The thing is, if I have to fine-tune the ORM generated SQL for optimal performance, its value diminishes.

<comment><USER17> > Much less boilerplate than any ORM tool generates.

I disagree. The SQLAlchemy query language is very nice, for instance.

> That depends how expressive is the application language's meta-programming > capabilities.

Certainly, but metaprogramming doesn't necessarily rhyme with readability.

> The thing is, if I have to fine-tune the ORM generated SQL for optimal > performance, its value diminishes.

Of course. However: the SQL generated will be fine for the majority of queries. What's going to bite is the use of lazy collections. For complex queries, you may want to fine-tune it by hand (though not necessarily).

That said, I rather agree that ORMs are best avoided. The existence of lazy collections makes it very easy to turn what ought to be a straightforward, fast query into something slow. What I'd like to work with is a query builder for select/insert, and avoid magic, even at the cost of creating by hand awkward structures like PersonWithAddress and PersonWithAddressAndBankAccount.

<comment><USER18> Yeah, query-building languages with good composability are a sweet-spot. In ruby, there is arel, which describes itself as "a relational algebra", rather than an ORM and is actually how activerecord, which is absolutely an ORM, is implemented. It's possible, even easy, but not particularly idiomatic, to drop down into using arel for more complex queries.

</comment></comment></comment></comment></comment><comment><USER19> Really happy to see some SQL appreciation. Of course ORMs can make code easier to read and allow you to change databases quickly... But I always asked myself if these 2 points are enough for the loss in performance and the use (in some cases) of really dodge background implementations of things that already are beautifully implemented by many databases.

</comment><comment><USER20> Another issue I have with ORMs is different projects end up with different views of the same database.

Why don't you use a foreign key to that table? We don't have that table... Yes we do, it's not because you haven't defined it in your project that it doesn't exist!

And... every project ends up with their own version of the "versioned schema", so to rebuild the DB, you need to aggregate all the liquidbase/flyway files from all the projects and run them all.

When I wear my sysadmin/pseudo DBA hat, ORMs are one of my more prominent pain.

<comment><USER21> I think this pain comes from using swl databases for integration, which is an antipattern in my book, and prevalent in the enterprise. Databases should have a single application talking to them, and have a service in from of them that makes it possible to get the data needed out. Services are easier to maintain backwards compatibility with, whereas databases are a massive pain to version and migrate and having to synch multiple teams to do such a job is a nightmare.

That being said, I realize its often much more convenient at the beginning to have one database for integration. SQL is much more expressive than your service's interface will be, and in the beginning this seems like a killer.

<comment><USER18> I've yet to see the real payoff of a database service like you describe over simply having a central database _library_. Perhaps the payoff comes if you want to use multiple languages, but if you don't, then pulling all the schema versioning and db-related client code into a single library that is used anywhere it's needed solves all the problems your parent brought up.

<comment><USER20> I haven't seen any large enough entity using a single programing language across teams in a long time!

<comment><USER18> Fair point!

</comment></comment></comment></comment></comment><comment><USER22> These are some very nice tips! One of the things I like so much about ActiveRecord is that it plays nice with pretty much every example here, e.g. `Product.where("title ~* 'title'")` or `Product.where("title ~* ?", title)`. A few other remarks:

\- I'm so glad to see someone talking about `generate_series` for time-series reports. I often see queries that are `GROUP BY date`, which is _usually_ okay, but will skip an output row if you have no data for a certain day. If you want to force one-row-per-day, use `generate_series`.

\- His `GROUP BY` query can be rewritten with less repetition like this:

        SELECT  sku,
                SUM(price),
                date_part('month', created_at) m
        FROM invoice_items
        GROUP BY m
        HAVING m = 9

In other words, `GROUP BY` and `HAVING` can reference expressions that are aliased in your `SELECT`.

\- Also on this query: In Postgres if `sku` is a primary key, then you can `SELECT` other columns from `invoice_items` without including them in `GROUP BY`, e.g. `SELECT sku, name, supplier_id, etc`. I _think_ even joined stuff is okay: `SELECT sku, suppliers.name`.

\- One more nit on this query: I think this is backwards from what he meant?: "having to be sure that whatever you GROUP BY is in your SELECT clause."

\- Usually I don't use window functions where a `GROUP BY` will do, but to me the biggest value in window functions is they don't force any particular structure on the overall query, so they don't constrain you the way `GROUP BY` does. He kind of alludes to this when he shows per-sku monthly sales combined with total monthly sales. Good example!

\- I'm not sure his CTE example shows much added value from the CTE, but maybe I'm missing something. The three places I really like CTEs are (1) recursion, (2) with INSERT/UPDATE/DELETE and RETURNING, (3) very big queries. But a lot there depends on taste.

\- When you use `string_agg` and friends, you can give an ordering for just that function: `string_agg(downloads.title, ',' ORDER BY products.sku)`. That syntax works for every aggregate function (I believe), although it's especially useful for the *_agg family.

Thanks for sharing these tips! I wish more people knew the cool things you can do beyond SELECT x FROM y.

</comment><comment><USER23> I've spent some time recently figuring out that SQL is nice. But my issue has always been the same : how do I coalesce that with best-practices in other things.

For example, how do I apply DRY and use SQL ? How do I apply type safety principles? How do I avoid syntax errors?

It feels like this ends up with building some sort of ORM.

Anyways, I'd love to hear experiences on interfacing SQL with "good" safety principles in larger-scale projects

<comment><USER24> DRY is the #1 reason I use an ORM. I also think that it's a factor that is rarely if ever considered by people who choose not to use an ORM.

<comment><USER25> Your database is just about the worst place in the world to be strict about DRY. It turns out, your model and validations don't actually prevent broken data. They just make you think you're safe from it...

...until your broken data starts biting you and your customers in places that don't typically see sunlight.

<comment><USER24> >Your database is just about the worst place in the world to be strict about DRY.

There are no places in any code base __at all __where it doesn 't pay to be rigorous about DRY.

>It turns out, your model and validations don't actually prevent broken data.

A) DRY isn't about preventing broken data.

B) Validations are _for_ preventing broken data. That's what they _do_.

</comment></comment></comment></comment><comment><USER26> The point of using an ORM is not about avoiding the difficulty of SQL or the ease of switching databases.

ORMs are about code reusability.

First off, validation of input data is painful without ORMs. Converting data between SQL, your languages' type system and the user interface in a reusable way almost necessarily leads to an abstraction which looks like an ORM. Not doing so quickly leads to bugs and vulnerabilities. I can usually tell at a glance if Django ORM code leads to an injection vulnerability or not (Hint: Unless there is custom/raw SQL there is no vulnerability). Harder to do in pure SQL.

Secondly, queries can be modified and introspected in code. Hard to do with SQL query strings, easy to do with ORMs. With the Django ORM you can progressively filter a query using variables from your context, you can modify a base query to get you a count, an aggregate and a list of model instances, and you can introspect a query for the tables it will touch.

Thirdly, an ORM makes queries reusable by different sub systems of your framework. Again in Django, you can pass a Queryset (without evaluating it before it's necessary) to the template system, to the input validation (django forms), to form widgets, the introspected admin, REST frameworks and so on.

Fourthly, ORMs help manage migrations. Migrating to and from different points of migrations can be hard to do in raw SQL or with your own tools. ORMs aren't perfect at this, but SQLAlchemy and the Django ORM both have very good migration tools which save you a lot of time and a lot of frustration, with minimal headache now and then. Migrations are easily testable and easily repeatable.

I also believe that ORMs are more important to the framework than for the individual application. A framework can only survive and grow a strong community if it can satisfy a large base of users. For Django's success it was necessary to support SQLite, Postgres, Mysql and Oracle, whereas single Django projects might thrive without ever changing to and from Postgres.

</comment><comment><USER27> Switching from mssql to postgres, these are the kinds of things I really loved where I didn't need to roll my own. In mssql I rolled my own regex, series generation, date formatting, and others. Once you've done it, it's there though and you forget about the time that went into implementing.

However there's plenty things I prefer in mssql, but I won't go into them all here.

Edit:

I didn't want to take away from the focus or be a jerk about it.

Things I prefer in mssql environment:

> Triggers work on entire dataset instead of row by row.

> Stored procs can return multiple data sets and output variables all from a > single call.

> Opinion: t-sql is friendlier than pgpsql to work in.

> Backups/restores are more straightforward.

<comment><USER28> Perhaps I'm missing something, but:

> Triggers work on entire dataset instead of row by row.

in pgsql you can have trigger that works per row or per dataset [1]

> Stored procs can return multiple data sets and output variables all from a > single call.

you can provide results through arguments by using "OUT" as argmode [2]

> Opinion: t-sql is friendlier than pgpsql to work in.

while it is hard to argue with an opinion, you can also use Tcl, Perl, Python (these three come standard), Java, PHP, R, Ruby, Scheme, sh[3].

[1] [http://www.postgresql.org/docs/current/static/sql- createtrig...](http://www.postgresql.org/docs/current/static/sql- createtrigger.html)

[2] [http://www.postgresql.org/docs/current/static/sql- createfunc...](http://www.postgresql.org/docs/current/static/sql- createfunction.html)

[3] [http://www.postgresql.org/docs/current/interactive/external-...](http://www.postgresql.org/docs/current/interactive/external- pl.html)

<comment><USER29> I'm generally a fan of pgsql, but mssql triggers are better in that they can operate on the entire set of affected rows. Postgres FOR EACH STATEMENT triggers don't get any OLD or NEW; you only get those with FOR EACH ROW triggers. In mssql OLD and NEW are the entire set of affected rows and can be used like tables. Batch operations are thus more efficient. [http://www.postgresql.org/docs/9.4/static/plpgsql- trigger.ht...](http://www.postgresql.org/docs/9.4/static/plpgsql-trigger.html)

</comment></comment></comment><comment><USER30> I'm sure anyone can come up with specific situations where writing SQL is much better than using ORM. If I had infinite time and dev resources I would never use an ORM. In reality Entity Framework makes abstracting my data-layer very easy and increases my productivity. It also makes me feel much more comfortable about switching databases if necessary. Even if I'm taking a 5% performance hit it is totally worth it to me.

<comment> jon-wood > It also makes me feel much more comfortable about switching databases if > necessary.

This is one of the big features touted by ORMs, but I wonder how often it actually comes into play. I've been using Rails with ActiveRecord for most of the last 10 years now, and I've not once changed databases after starting a project. There's one project where I'd like to, but despite the use of ActiveRecord, there's enough MySQL specific stuff in the code that its not going to be trivial to just copy the data over to a Postgres database and flip the switch.

<comment><USER4> > but I wonder how often it comes into play.

Databases are not interchangeable, though sharing a common query language makes the skill set somehat interchangeable. I think this is part of the nuance often lost in the discussion of ORMs and database-portability.

I have worked with many developers who actively deny this basic reality, in favor of trying to bury all that variability under an ORM, rather than exploit any of the proprietary features. I understood it as a crutch when I was still in the flat part of that learning curve, but I am a lot happier building a rich SQL application interface (non-ORM!) these days.

<comment><USER17> > Databases are not interchangeable, though sharing a common query language > makes the skill set somehat interchangeable. I think this is part of the > nuance often lost in the discussion of ORMs and database-portability.

I see two realistic reasons for why having an ORM/avoiding DB-specific queries is good idea:

\- your product supports multiple databases

\- you want to use something like sqlite in memory for tests

<comment><USER4> > your product supports multiple databases

In this case, I tend to see pretty light loads. You can do this with fairly vanilla (ORM-generated) SQL and design. When your business begins to lean heavily on the database for operations (I saw this in finance) around the clock, and you have to start being more judicious about your queries, these applications are usually the first to buckle.

> you want to use something like sqlite in memory for tests

Only if I have to support sqlite in the field!

</comment></comment></comment></comment></comment><comment><USER31> Using distinct and windowing functions to avoid writing group-by clauses may work fine with Postgres but is a very ugly hack.

<comment><USER32> This ugly hack is not useful in general and only looks interesting here because the original example query is in bad taste. Simplifying it removes the tedium motivating the use of window functions.

For example, this is equivalent to the original query:

      SELECT sku, sum(price)
      FROM invoice_items
      WHERE date_part('month',created_at) = 9
      GROUP BY sku

See how the tedium disappears? In the original, the HAVING clause doesn't use any aggregate functions, which means it can instead be a WHERE. Removing the HAVING means we can further simplify the GROUP BY.

Of course, that only works because this example needs only a single month group. If you want multiple months and per-month price totals, then my rewritten query is no longer equivalent. It would need the more complicated GROUP BY. However, the window function version would also get more complicated in just the same way. The complication is inherent to the problem, not due to standards conformance.

Actually, what's really tedious is the verbose expression required to get the month and the fact that the author is repeating it. The standard provides "WITH" to avoid that duplication, and Postgres implements it.

Here's a reasonable version for multiple months:

      WITH items AS (
        SELECT *, date_part('month',created_at) AS month
        FROM invoice_items
      )
      SELECT sku, month, sum(price)
      FROM items
      WHERE month in (7,8,9)
      GROUP BY sku, month

But suppose we make the example even more complicated. Suppose you want sums over different time periods, like per-month and per-quarter. Then you _can 't_ use a GROUP BY and _must_ use window functions and DISTINCT.

      WITH items AS (
        SELECT
            *
            ,date_part('year',created_at)    AS year
            ,date_part('month',created_at)   AS month
            ,date_part('quarter',created_at) AS quarter
        FROM invoice_items
      )
      SELECT DISTINCT
          sku
          ,year
          ,month
          ,quarter
          ,sum(price) OVER (PARTITION BY year)          AS yearly_total
          ,sum(price) OVER (PARTITION BY year, month)   AS monthly_total
          ,sum(price) OVER (PARTITION BY year, quarter) AS quarterly_total
          ,sum(price) OVER (PARTITION BY month)         AS month_number_total
          ,sum(price) OVER (PARTITION BY quarter)       AS quarter_number_total
      FROM items
      ORDER BY 1,2,3,4

</comment></comment><comment><USER33> SQLAlchemy can express SQL from author's post, so probably he just didn't try good ORMs.

</comment><comment><USER34> SQL is nice but most of those features work best when the user is a finance person doing reports (which was the original purpose for SQL, I think?). Developers don't want the sql server to format their numbers as money, that's a work for the UI. The main reason for me to use an ORM is to standarize on one way to retrieve data whatever the database engine is. Maybe an intermediate solution would be better, like a query builder or a sql-like syntax that transforms to the correct SQL for the database in use like Doctrine's DQL.

<comment><USER35> > whatever the database engine is I know, but... How often does that > flexibility come up? How often do you write code first against one DB type, > and then switch to a different that would require a re-write?

It's admirable and fun to think about, for sure, but how much use does that feature actually get?

<comment><USER34> I already said this in another thread, it's not about switching databases in one project, but using the same skillset across projects regardless of the database.

<comment><USER4> I find SQL is pretty portable. You have to learn each server's ins and outs to do performance work, but then, those differences are part and parcel of _why_ there are different servers, beyond basic business-competitive reasons.

ORMs just add a thick layer of fluff over an otherwise (mostly) portable language, where I'm concerned. I rather keep it simple between DBs and apps. If there is gross SQL in the app, make a view or function in the database. It isn't rocket surgery but you do need experienced staff to get it right.</comment></comment></comment></comment>


Pseudo-Meritocracies - <AUTHOR> http://medium.com/@fabianstelzer/on-pseudo-meritocracies-1a00d4b4da2e <comment><USER2> I am glad it's about class inequality for a change. On topic: how naive do you need to be to think that any of current civilizations are meritocratic? Especially given the recent positive discrimination trends.

</comment><comment><USER3> One problem with the meritocracy is achievement laundering. For instance if you get through Harvard you really have run the gauntlet and worked very hard, it gives you more of a feeling of entitlement.</comment>


Blog of a guy who lost 31K yesterday betting on markets - <AUTHOR> http://highprobability.blogspot.com/

<comment><USER2> Neat. This reminds me of 2000 all over again when the .com bubble burst.

Don't invest what you can't afford to lose. At the same time, there is no better teacher than reality.</comment>


How to Raise Prices Without Pissing Your Customers Off - <AUTHOR> http://blog.freshplum.com/raise-prices-without-pissing-customers/?utm_source=facebook&utm_medium=social&utm_content=5088625

<comment><USER2> Another great way to do this is to increase prices with a new version of a product or service. You're then no longer raising the price, but releasing something new. If you really want to be sneaky, you can simultaneously discontinue the "old" product or service as well. This is in-line with explaining to the consumer why you're increasing the price... because it's new!</comment>