Monday 3 October 2011

various

This morning I tried to see if I could improve my mysql query for retrieving the info needed to build a feed for my photo website. I thought that maybe I could do a sort and limit on the subquery, but when I tried this I got an error message
#1235 - This version of MySQL doesn't yet support 'LIMIT & IN/ALL/ANY/SOME subquery'
(this is with MySQL 5.4, while I think most webhosts are still using 5.1).

Trying to find if there was any disadvantage to running DISTINCT on a query (or sub query) you are then going to GROUP BY the same column, I found this helpful article at Stack Overflow: What's faster, SELECT DISTINCT or GROUP BY in MySQL? In short, the answer is that if your column has an index on they will both be the same, otherwise DISTINCT will be faster.

After modifying my feed to include the image as HTML in the content tag, I found the image wasn't showing up. I did some testing, and found that on Firefox at least, if you include a summary tag, then the html in the content tag isn't included.

Flickr, RedBubble, and Picasa don't include a summary tag (possibly for this reason), so I just removed the summary tag. Next I looked at what size the images should be. Picasa uses a max width/height of 288px. Flickr uses 240px, and RedBubble uses 550px. Since my existing thumbs are 150px, and my small size is 500px, I think I will go with with the larger 500px size images.

After lunch I went out to help someone with their computer. For the rest of the afternoon I processed a few photos.

In the evening I watched Point Break with Mauser.

No comments: