Getting rid of duplicate Entries in your MySql database

Thanks for Justin Cook for doing all the leg work on this one.

All you have to do is create a new table from the old one, which filters out the duplicate entries

SELECT * FROM old_table WHERE 1
GROUP BY [colum_to_remove_duplicates_from];

so as an example

SELECT * FROM news WHERE 1 GROUP BY [title]; <a href="" class="more-link">Continue reading <span class="meta-nav">&rarr;</span></a>

How to run a Webkit Nightly build on windows.

This is very straight forward, but for those who think it might be complicated. Here is all it entails.

inside a webkit nightly build folder Continue reading

fixing webrick error – WARN TCPServer Error: Bad file descriptor – bind(2) – on windows

I was working on a Ruby on Rails project with Netbeans today when I went to fire up webbrick to test something in the app.

I immediately got an error like this

=> Booting WEBrick...
=> Rails application started on
[2008-03-18 16:36:59] INFO  WEBrick 1.3.1
=> Ctrl-C to shutdown server; call with --help for options
[2008-03-18 16:36:59] INFO  ruby 1.8.6 (2007-03-13) [i386-mswin32]
[2008-03-18 16:36:59] WARN  TCPServer Error: Bad file descriptor - bind(2)
C:/ruby/lib/ruby/1.8/webrick/utils.rb:73:in `initialize': Bad file descriptor - bind(2) (Errno::EBADF)
        from C:/ruby/lib/ruby/1.8/webrick/utils.rb:73:in `new'
        from C:/ruby/lib/ruby/1.8/webrick/utils.rb:73:in `create_listeners'
        from C:/ruby/lib/ruby/1.8/webrick/utils.rb:70:in `each'
        from C:/ruby/lib/ruby/1.8/webrick/utils.rb:70:in `create_listeners'
        from C:/ruby/lib/ruby/1.8/webrick/server.rb:75:in `listen'
        from C:/ruby/lib/ruby/1.8/webrick/server.rb:63:in `initialize'
        from C:/ruby/lib/ruby/1.8/webrick/httpserver.rb:24:in `initialize'
        from C:/ruby/lib/ruby/gems/1.8/gems/rails-1.2.3/lib/webrick_server.rb:58:in `new'
         ... 7 levels...
        from C:/ruby/lib/ruby/gems/1.8/gems/rails-1.2.3/lib/commands/server.rb:39
        from C:/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:27:in `gem_original_require'
        from C:/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:27:in `require'
        from script/server:3

Continue reading

SxSWi day four: Javascript secrets

This sesssion was pretty much standing room only and I came in 15 minutes late.
I didn’t get to really settle in and pay attention as I’d like, so I’ll have to view the slides later (I’ll link to them because they were really frickin’ great)
This jumps around a bit, as I’m writing from memory.

  • They talk about memory leaks in IE, I dunno if the newly released Jscript 5.7 addressed what they were talking about
  • There was this very interesting part of the talk where they talk about being able to access dom elements using Xpath.
  • Apparently Xpath is faster in situations where you want to get all divs of class foo (for example)
  • With Xpath … the engine just goes and gets them, with dom it gets all the divs, then loops around and gets the ones you want
  • This can be slow when you’re dealing with a lot of elements Continue reading

SxSWi Day Four: Considerations for scalable web ventures (How to scale)

Panelists of Scalable web ventures

Kevin Rose | Digg
Cal Hendersen | Flickr
Joe Stump | Digg
Chris Lea | Media Temple
Garrett Camp Stumble Upon
Matt Mullenweg | WordPress

{Discussion: Kevin seems to be moderating}

  • Consensus is that you think about scaling when you get there
  • Joe Stump says that it (not worrying about scaling initially) helped them concentrate on building cool features
  • Software load balancers suck … Squid is highly recommended
  • Pound is good for http load balancing
  • Joe Stump says that at 15 million pageviews you should start thinking of specializing servers (images, db, static files … that sort of thing) Continue reading

SxSwi Day three: Design Eye for the South By

Today was terrible … the weather was nasty (cold and rainy) and I forgot my badge at home.But one of the more interesting panels was the Design Eye for the South By.

In it a group of designers, got together to redesign the current SxSW website. I really loved the concept they came up with, which was to personalize the site for each user and throw in a social networking component to it, sounds cliche but read on … Continue reading

SxSWi Day one: … Expression Engine 2.0

Woohoo!! First full day of SxSWi.

Missed the morning sessions but got in to see a sneak peak of Expression Engine 2.0 (latest version 1.6).

Its hard to describe, but version 2.0 is amazing, almost everything has some kind of neat little effect on it. Things seem to be organized in a very different (but seemingly more intuitive) way from most other CMS’s. And I mention that it looks gorgeous … completely web 2.0’ed out.

I’ve never been a fan of Joomla, but it looks like the folks from Ellislabs have a winner on their hands.

Its that good.

No word when it’ll be out though.

Safari/Webkit Nightly scores a 90 on Acid 3 test …

I am  a huge fan of Safari and Webkit … what it lacks in cool features, it more than makes up for in blazing fast speed and javascript performance.

When the Microsoft released a beta for IE8, I was prompted to run the Acid3 test on the browsers I had on my system.

Here are the results I got on my windows box, testing all the installed browsers against Acid 3 Continue reading