HNHacker News
TopNewBestAskShowJobs

a_m0d

227 karma · joined May 5, 2010

.Net and web developer.

Github: https://github.com/am0d

submissionscomments
a_m0d··on New “Android Go” phones show how much you can get for $100
Must say I've had kind of the opposite experience - I found that the MiUI skin was actually quite confusing and definitely didn't add anything useful. Otoh, my Leagoo T5 has been a great phone, has better specs, a gorilla glass screen (RedMi Note 4X has regular glass and cracked within days of getting it), and has been getting system updates about once per month from Leagoo, all for less than the price of the Xiaomi. ymmv I guess, but that's been my experience so far.
a_m0d··on Modern SQL: With – Organize Complex Queries
SQL Server has a limitation of 1000 rows maximum allowed in a VALUES clause, so sometimes a SELECT ... UNION ALL is required instead (this limitation probably doesn't exist in Postgres, though).
a_m0d··on Modern SQL: With – Organize Complex Queries
This script works in SQL Server - I would think you could do the same in Postgres, but I'm not as familiar as I'd like to be with Postgres.

Note that it does require 2 separate steps rather than 1 as you appear to desire, so may not work for you:

    IF OBJECT_ID('dbo.dogs', 'U') IS NOT NULL
        DROP TABLE dbo.dogs
    GO
    
    IF OBJECT_ID('dbo.doghouses', 'U') IS NOT NULL
        DROP TABLE dbo.doghouses
    GO
    
    CREATE TABLE dogs (
        id INTEGER IDENTITY (1, 1) PRIMARY KEY
       ,name VARCHAR(MAX) NOT NULL
    );
    
    -- Now we want to give each dog a doghouse:
    CREATE TABLE doghouses (
        id INTEGER IDENTITY (1, 1) PRIMARY KEY
       ,name VARCHAR(MAX) NOT NULL
    );
    GO
    
    ALTER TABLE dogs ADD doghouse_id INTEGER REFERENCES doghouses (id);
    GO
    
    INSERT INTO dogs (name)
    VALUES
        ('Sparky'),
        ('Spot')
    ;
    
    DECLARE @DogsAndHouses TABLE (
        doghouse_id INT
       ,name VARCHAR(MAX)
    );
    
    INSERT INTO dbo.doghouses (name)
    OUTPUT INSERTED.id, INSERTED.name INTO @DogsAndHouses
    SELECT
        d.name
    FROM
        dbo.dogs d;
    
    UPDATE d
    SET
        doghouse_id = dah.doghouse_id
    FROM
        dogs d
        JOIN @DogsAndHouses dah ON d.name = dah.name;
    GO
a_m0d··on Are You Really Gluten-Intolerant? Maybe Not
Receiving an official diagnosis by a doctor for celiac is not always possible. Although my wife's doctor considered it a possibility that she was celiac, he did not do anything with that idea until she had tried being gluten free already for a few months and found that it helped her intense pain.

The test for celiac requires a person to have been eating regular amounts of gluten for 3 months before the test is done. When my wife is in a position such that a crumb of normal bread in her meal can cause her pain afterwards, there is no way she can eat gluten for 3 months in order to get a diagnosis by a doctor. The best she can get now is a statement that she is sensitive to gluten - but that sensitivity is enough that she can't have food cooked in the same pan as your food when you don't give any consideration to her.

So don't say this is "bullshit food intolerances" - just because you don't have to deal with it does not mean that it is not real.

a_m0d··on OpenBSD has started a massive strip-down and cleanup of OpenSSL
Did you mean

> NaCl aims to provide a simple, clean interface ...

a_m0d··on Why not to use infinite scroll on your website
Your site still breaks when scrolling by dragging the scroll thumb down. On a long page, dragging the scroll thumb down (the way many people actually do scroll) makes the page jump around very fast, and skip larger sections as the page goes further down.
a_m0d··on Google’s suggestion for a better infinite scroll?
Another reason to hate it, which my wife runs across all the time on Facebook - she scrolls by dragging the scroll-thumb down with her mouse. Once she gets near the bottom, the page jumps as the extra content gets loaded, and she has to find her place again.
a_m0d··on Solved By Flexbox – Cleaner, hack-free CSS
That doesn't include the possibility that the user right-clicks and selects "Open Link in New Tab"
a_m0d··on PostgreSQL 9.3 Beta 1 Released
We are currently using MS SQL Server, but have looked at the possibility of using Postgres in the future.

One major stopping point for us is the fact that on SQL Server we use a Case Insensitive, Accent Insensitive collation. Postgres doesn't support this, and apparently has no plans to.

We have many stored procedures in TSQL which are built around the assumption of CI,AI. Converting these will be a lot of work, but the lack of CI,AI collation would be by far the biggest pain point.

a_m0d··on Data journalism busts speeding cops, wins Pulitzer
What's the problem with the marked cars driving the speed limit? If all the cars drive at the speed limit, that's good, right?

I always thought the speed limit was there as a speed limit. I've found that in Australia, speed limits are obeyed much more than in North America, where they seem to be suggestions or lower bounds on speed. Many times in Canada I've been travelling in traffic that's doing 30 - 40 kph over the speed limit. That's enough to get your car confiscated in Western Australia!

a_m0d··on Groundwork - A Responsive HTML5, CSS and JavaScript Framework
This framework is quite broken on the iPad (in Chrome).

- The dropdown menu doesn't work well. It triggers on hover, but trying to do "hoverintent" on the iPad simply fires the click event on the button, causing the menu to appear briefly before the page navigates. - I can't even scroll at all on the demo pages. Dragging the page (to scroll) just drags the whole tab rather than actually scrolling.

a_m0d··on Ten predictions (2004)
I was thinking more of StackOverflow as an answer to this one.
a_m0d··on Why bother with a CSS build process?
How are these two code samples related to each other? They appear to be for completely different use cases, and therefore I'm not sure that they actually demonstrate anything useful.
a_m0d··on Show HN: Built a Hacker News radio web app I can listen to
Yeah, doesn't work on FF19 even with the arrow keys. But it did work on Chrome Canary - must be a bug on FF.

edit: It looks like FF19 is complaining about the content-type: "audio/mpeg" when changing articles. Not sure what one it is using, but it does manage to play the first article only.

a_m0d··on Show HN: Built a Hacker News radio web app I can listen to
longzheng, is there any way to be able to change articles? I'm on ff19, and clicking on a new article just continues the original article. Hovering over the left side of the article shows the "play" symbol, but clicking anywhere there just continues the original article. Not sure if this is a bug or not.
a_m0d··on The Curious Field of Metamaterials
I believe, from what I read in the past, that it actually bends the light around the object, somewhat like the way water will flow past rocks in a river.
a_m0d··on Extend Twitter Bootstrap with these Bootstrap Form Helpers
It also allows you to paste any text in, and it will no longer match the mask.
a_m0d··on Fiddler has joined the Telerik family
The above may all be true, but I'm sure you'd say the same about any of the "enterprise" suites of web controls. Speaking from experience with Infragistics, I'd say the exact same things. Perhaps it's the price to pay for trying to make the "be all and end all" of control suites.
a_m0d··on Markov chain paper title generator
From the article:

If you’re using a small corpus and long Markov chains, you’ll end up with lots of actual strings from the corpus, and no fake ones. If this happens, experiment with the second parameter to the constructor for the class “MarkovGenerator.”

For the authors you are using, the corpus is too small.

a_m0d··on Google Awarded Driverless Vehicle Patent
I don't think that was mis-parsed - I think that JabavuAdams is (rightfully ?) cynical that the insurance companies will lower prices.

Rather, they will make the current price the standard for (self-driving cars), and increase the price for (human-driven cars), thereby ensuring more money for themselves.

a_m0d··on Google can be used as a graphic calculator
It seems like it does sometimes, but not at other items. I clicked around on the page a bit, then clicked on the search button, and suddenly it showed me the zero click info, which was hidden before.
a_m0d··on foo@bar.com is a real email address
The "+" trick is great, except for sites that use hair-brained email "validation" scripts which reject the address. Sadly enough, these are often the ones that I most want to use the "+" for (its a great way to also keep track of who hands out your email address to spammers).
a_m0d··on Saving a Life is Easy, But I Didn't
The problem is that the percentages are higher than that. The biggest problem is that testing won't always pick up HIV and AIDS, because these diseases can lie "dormant" for quite a while, but yet they are still in the blood (undetectable) and will cause infections somewhere down the line.
a_m0d··on Saving a Life is Easy, But I Didn't
Australia - http://www.abmdr.org.au/dynamic_menus.php?id=1&subid=1&#...

Or sign up at the Red Cross centre when you're in there to donate blood - they'll take an extra blood sample for testing purposes.

a_m0d··on The power of Google: how the Panda update hit Experts Exchange
True, but it still does break google's requirement that the page Google sees must be the same as the one Google's user sees (which was the original reason they did this anyway).
a_m0d··on The power of Google: how the Panda update hit Experts Exchange
Part of the problem, though, is that they don't always show you the same results as the search engine sees. I've just started using the SSL version of Google search, and now I no longer see any answers on the EE pages, where I did before. It looks like they only display the answers in the bare minimum number of case necessary to still get search rankings, rather than displaying them for all google referrers.
a_m0d··on Groom your programming skills and make some money
Another interesting thing on the "How are programs run" page is the fact that the programs are apparently run on a Linux system, yet C# files are compiled with Microsoft Visual C# somehow!
a_m0d··on Google Deletes Last 7 Years Of User's Digital Life, Shrugs
There is also the .me TLD - not sure if it has the same intentions as .name, but it is less used so more widely available. I own my lastname.me domain, and so I can (if I ever set it up properly) send mail to firstname@lastname.me, which is slightly shorter but works just as well.
a_m0d··on Canadians Just Became World's Biggest Internet Losers.
No idea. This is a really bad ISP who seem to get nothing but complaints - they assume that all their users are really dumb, so their technical FAQ (http://oceanbroadband.net/info/faq.html) states only that they use a proprietary system from Motorola Canopy Wireless. As for the distance from the exchange, I think we are about 10kms away, but once again I'm not entirely sure.
a_m0d··on Canadians Just Became World's Biggest Internet Losers.
Could be quite expensive. Where I live (40kms from Perth, WA, in a semi-rural area) we use this Motorola wireless technology, and the prices are astronomical - $80 for 3GB on peak and 5GB off peak. When we first signed up, we also had major stability issues (connection constantly dropping out, connection hijacked by a hacker for a few months, etc.), although things are looking better now.
Page 1 of 2Next →