Mostly about my amusement

Author: Jan Dembowski (page 55 of 96)

Cleaning up the WP database

WordPress blogs are based on MySQL and all the dynamic content is stored in a database. After trying out plugins, odd themes, and generally screwing around, my database has items in it that I can’t even recall what they were or if I need them.

One way to clean out the database is to export the blog to an XML file.  This will produce the posts, pages, and all the comments and not export the ton of junk in the database.  This way I create a clean empty blog, add the users, set up the theme and look I want and import the data.

This produces a very clean installation. It also removes me as the author for the comments I’ve left on my own blog. The table wp_comments table has a user_id field that the XML file does not have.

What I wanted to do is run a MySQL command that will find all instances in wp_comments which match my e-mail address, and update that record with my user_id on the blog. I could do this one at a time using phpMyAdmin but that’s pretty inefficient, not geeky, and time consuming.

After some research I found out to run these commands:

$ mysql -p
USE blogdatabase;
Database changed
SELECT * FROM wp_users WHERE user_email = 'notreally@myemail.com';

That gets me the ID number for my user.  Since it’s the first user created the ID is 2.

UPDATE wp_comments SET user_id = 2
WHERE comment_author_email = 'notreally@myemail.com';
Query OK, 113 rows affected (0.00 sec)
Rows matched: 113  Changed: 113  Warnings: 0

This updates the wp_comments table so comments left by me using my e-mail address.

Governor Palin abused her position and so what?

The report is in and apparently Governor Palin (or her husband, I can’t tell which) has abused her position. And it does not matter one bit. The folks who will vote for McCain only care about ethics, rules, and laws when it applies to Those Darned Socialist Democrats.

If anything this will solidify the base of voters who will claim that Governor Palin is the target of a political hit job. Any conservative who writes about Palin in anyway negative will simply get targeted as a not-country-first turncoat. That’s what Joe Six Pack says, anyway.

John McCain does show some signs of realizing what he’s doing, but he apparently still wants to get elected at any cost.  I still believe that he’s not really this scare mongering talking head (I liked McCain in 1999). But this is his last chance and I think in the next 2 weeks we’ll see the McCain campaign full out the stops.

Gundam 00 Season 2 begins

The second season of Gundam 00 has begun.  No huge surprises yet but this season seems to be imitating Zeta Gundam more and more.  I’m pretty sure we’ve just met the group that will be this series Titans.

I wonder how long it will be before Bandai produces a Master Grade 1/100 scale version of the Exia?  The Exia looks like this episode is it, so that ought to make it a good candidate.

60 foot tall fighting robots.  The kids and I will have fun watching this one.

That was totally expected, no release for those 17

Those 17 not-enemy-combatants that Pakistan handed to the U.S.? An emergency motion blocking their release was granted to the administration.

That’s not surprising; I expected that the administration would not have bothered with a court order.  I mean, they could have just refused to comply.

This whole situation is ridiculous.  If this is really an immigration issue, why not transfer them to an immigration detention center?  Isn’t that where immigrants who are being processed for deportation go? That way it really does become an immigration status problem.

The Bush administration has already released over 400 prisoners to other countries. While the 17 do not have a place to go, keeping them in the U.S. gulag can’t be the right thing to do.

Oh, come on, what next?

When Senator McCain was running in the primary against George W., Karl Rove ran a dirty whisper campaign and W. won the primary. It was your typical get elected at all cost move and sadly it worked.

Now this?

“Our opponent though, is someone who sees America, it seems, as being so imperfect that he’s palling around with terrorists who would target their own country.”

Governor Palin – ENGLEWOOD, Colorado

That’s some Maverick behavior alright.  The statement is nonsense and the McCain campaign knows it.

Next up Palin will be saying things about his religion (he’s Christian), and his upbringing (he did not attend a madrasah), and his patriotism (his wife does not hate America).

I like how this is orchestrated to have Governor Palin spout this nonsense.  You don’t want to have McCain dirty his dress whites after all.

Senator McCain knows this is his last shot for the brass ring. So scruples be damned, his campaign will do and say whatever it takes to get anyone to vote for him.

McCain really needs to fire his ad guys

First they released a “McCain Wins Debate” ad a day early and now this.

ex·ag·ger·at·ed
–adjective
1. unduly or unrealistically magnified: to have an exaggerated opinion of oneself.
2. abnormally increased or enlarged.

I did not watch the debates but, you betcha, I’m dog gonnit, gonna read up on it.

The success criteria for each VP candidate was pretty low.  I mean, all Governor Palin had to do was form complete sentences and she exceeds expectations.  All Senator Biden had to do was not look across the room and shout “Are you kidding me?”

This is why I can’t really get into the debates.  It’s just an extended ad.

Nikon D60 and auto ISO

I got to learn about a useful DSLR feature called auto ISO.

A friend brought in his mint Nikon D90 and let me play with it. He had on the Sigma 17-70mm f/2.8-4.5 HSM macro lens and I was really impressed.  It’s not a D700 but for someone like me it’s really good.  Low noise at high ISO (compared to my D60), good color handling, and it’s fast.

We switched lenses for comparison and I was struck how his D90 took better exposed pictures than my D60.  I took pictures of the same things using both the D90 and the D60. Same lens, but the D90’s pictures handled poorly lit subjects better.

The D90 is a more current model but the difference was (wait for it) night and day.  Getting home I found the answer once I cracked open the manual.  His D90 had auto ISO turned on, while my D60 had it turned off.

Auto ISO on the Nikon D60 works like this: You set the maximum ISO sensitivity and the minimum shutter speed.  The minimum shutter speed is what triggers the auto ISO. Right now my maximum sensitivity is set to ISO 1600 and my minimum shutter speed is 1/15th of a second.  Using a flash turns off auto ISO.  I leave my camera set to ISO 200.

Most of my pictures are taken in P mode.  When the lighting works out that the shutter speed takes longer than 1/15 of a second, the camera will automatically raises the ISO from 200 to whatever works out to get the exposure time back down to 1/15 of a second.

Here’s an example using my son (he was the star student today in his class, way to go!) I set the minimum exposure for auto to 1/8 of a second from my usual 1/15.  I did this because my light is poor right now and at 1/15 I was shooting up to ISO 1400.

Both are at f/3.5 and the D60 was in P mode. The picture on the left is with auto ISO turned off, ISO 200 and exposed at 1/2 second.  The one on the right has auto ISO turned on.  This raised the ISO from 200 to 640 and is exposed at 1/8 of a second.  Even with VR 1/2 of a second suffers from hand shake.

It’s not perfect, and if I were using manual mode I would want to turn off all auto settings. But here it reduced the exposure time from 1/2 a second to the minimum 1/8 of a second.

For what I take pictures of it’s very useful; I almost never use the built in flash and don’t yet own a SB-600. As long as my shutter speed remains at or above 1/15 this will not be used.  Lower than 1/15 and I’ll get better pictures.

Tomorrow I’m going to a 4 year old’s birthday party so I’ll see how this works in practice.

Update: The day after I posted this, I went to the New York Hall of Science with Lily and the kids.  We attended a birthday party for a 4 year old and I borrowed my Dad’s SB-600 flash.

Auto ISO did get engaged with the flash on.  I left my camera set to ISO 200 and when the bounce was not enough to get it over the 1/15 second minimum, the ISO was bumped up.  This is one that I was surprise to see it get a small boost to ISO 280:

She sure knows how to pick them

I need to look into this some more.  With the flash, the exposure was dialed down to 1/60th of a second. I’m not complaining but I’d like to firm up my understanding.

Overall I took +300 shots and I liked the results. You can see the 40 pictures I posted with a SB-600 and auto ISO turned on Flickr.

Don’t you worry, the government is on the job

With the House Republicans apparently (it is a closed door negotiation) walking out of the talks, it makes me wonder who exactly wants to do the $700 B bailout?  The White House does, but are the Senate and the House acting only because they don’t want to appear ineffective and out of touch?

That alone would be a lousy reason to make a deal.  If it’s to stop a massive recession, great. If it’s for politics as usual… that would be one expensive photo op.

Last night JP Morgan Chase made out well picking at WaMu’s bones.  It’s Friday and no deal is being publicly touted and the financial companies are still here for now.  Even if a bailout does occur in some form, the NYC area is going to lose jobs and feel the impact, so it’s hard for me to take Washington seriously.

Maybe tonight’s debate town hall election event will be enlightening.