addressalign-toparrow-leftarrow-rightbackbellblockcalendarcameraccwchatcheckchevron-downchevron-leftchevron-rightchevron-small-downchevron-small-leftchevron-small-rightchevron-small-upchevron-upcircle-with-checkcircle-with-crosscircle-with-pluscrosseditemptyheartexportfacebookfolderfullheartglobegmailgoogleimageimagesinstagramlinklocation-pinmagnifying-glassmailminusmoremuplabelShape 3 + Rectangle 1outlookpersonplusprice-ribbonImported LayersImported LayersImported Layersshieldstartickettrashtriangle-downtriangle-uptwitteruseryahoo

Re: [ruby-99] Tech interview questions

From: Paul H.
Sent on: Monday, May 24, 2010 11:49 AM
Can I ask, what was the context for these questions? What was the role? What was the intersection, if any, between what the business needed to do and solving this technical problem?

Cheers!
Paul Hamann



From: ambert ho <[address removed]>
To: [address removed]
Sent: Sun, May 23,[masked]:29:31 PM
Subject: Re: [ruby-99] Tech interview questions

Q1: Flattening out by using more columns, and putting more data in each column, increases insertion performance since you don't have to insert into multiple tables for things that you would have split up in 1st, 2nd, 3rd normal form. But depending on your schema, denormalizing also means redundant inserts if multiple tables reference the table that you just got rid of. So if the database isn't sharded, I'm not sure how much gain you get if you get rid of an extra insert, only have to insert twice.

Caveat with having lots of columns is if you collapse several tables into one but end up needing to index multiple columns in the same table. Slows down insertion since the db has to calculate where an object goes on the b-tree every time there's an insert.

Q2: Dunno too much about this, someone educate me! I believe PostgreSQL and Oracle have journaling and MySql doesn't, I dunno http://en.wikipedia.org/wiki/Write-ahead_logging




On Fri, May 21, 2010 at 12:39 PM, DAN BIKLE <[address removed]> wrote:
Q1:
What denormalization techniques can we use at the database layer to
speed up INSERTS.

Q2:
Compare/Contrast features and behaviors of MySQL, PostgreSQL, (and
Oracle if you want) which are interesting to the Rails developer and
Rails site operations dept.

--Dan

--
[address removed]



--
Please Note: If you hit "REPLY", your message will be sent to everyone on this mailing list ([address removed])
http://www.meetup.com/silicon-valley-ruby/
This message was sent by DAN BIKLE ([address removed]) from Silicon Valley Ruby Meetup.
To learn more about DAN BIKLE, visit his/her member profile: http://www.meetup.com/silicon-valley-ruby/members/165657/
To unsubscribe or to update your mailing list settings, click here: http://www.meetup.com/silicon-valley-ruby/settings/
Meetup, PO Box 4668 #37895 New York, New York[masked] | [address removed]






--
Please Note: If you hit "REPLY", your message will be sent to everyone on this mailing list ([address removed])
This message was sent by ambert ho ([address removed]) from Silicon Valley Ruby Meetup.
To learn more about ambert ho, visit his/her member profile
To unsubscribe or to update your mailing list settings, click here

Meetup, PO Box 4668 #37895 New York, New York[masked] | [address removed]

Our Sponsors

People in this
Meetup are also in:

Sign up

Meetup members, Log in

By clicking "Sign up" or "Sign up using Facebook", you confirm that you accept our Terms of Service & Privacy Policy