MySQL and Snow Leopard Don’t Play Nice: Backups to the Rescue

5 09 2009

So I upgrade my Apple MacBook Pro to Snow Leopard and all is well until I go to access my MySQL Server installation (5.1.30 Community Edition). The install is completely fubared: The server won’t start. All my data files are there, but hardly accessible since to access them requires a good knowledge of the command line terminal and changing permissions on the data folder itself since it assigned to the _mysql user directly and not to the root user.

Looking around the interweb, I find a few people who claim that the Snow Leopard upgrade breaks the soft link to the mysql directory and that’s why it is screwed up. Well, fixing the soft link may have worked for other people, but not for me.

After spending and hour and a half putzing around with the command line trying to relink my old database files with a new install of 5.1.37, I decided to spend the ten minutes to recreate my databases and reload them from the backups I had made before the OS upgrade. See, backups are like the cavalry.

So after spending way too much time dealing with this fairly annoying upgrade problem, I was back were I needed to be. On the other hand, my MAMP installation survived the upgrade without a hitch. Go MAMP!





Happy New Year!

2 01 2009

Happy New Year, Everybody! I hope you and yours have a safe, wonderful, happy, and prosperous new year. Best wishes to you all and thanks for reading this blog!

Regards,

Stephen Arbour





Power.com is not so powerful

1 12 2008

Referring to TechCrunch post: “Power.com: For Social Networking Power Users”

Good idea, but underwhelming execution. I agree with other comments regarding the bugs. But my chief complaint is the lack of aggregation functionality. I hooked up my MySpace and Facebook accounts, and as far as I can tell, while I can switch between them, never do I see a combined list. My list of Friends only seems to have my Facebook friends. My list of messages only has my Facebook messages. etc. In addition, the updates list is only for a single network, so there’s no intersection or aggregation across networks so that I can track conversations which cross social networks.

Michael Arrington also states that I can use Power.com to update my status across the networks. How? There does not seem to be any functionality to accomplish this. There is an ability to send messages to users in multiple social networks at once, but that’s not the same thing as updating my status message.

Right now, Power.com functions ok as a launch pad, but due to the bugs and otherwise missing functionality, I think I’ll stick to using Flock with tabs for each social network and save the screen real estate.

Crossposted on zyggyrat.wordpress.com.





MS SQL Server Has Issues With Math

25 11 2008

I ran into a known issue with MS SQL Server 2005 that threw me for a loop. Essentially, casting a rounded float value as a string led to the number losing significant digits when the number of significant digits was greater than three.

Ok, digest that for a minute: Values stored in the float datatype in SQL Server aren’t accurate past ten-thousands! Uh, isn’t that a big deal?

Don’t believe me? Check this out yourself:

declare @res as float

select @res = 123.123456789

select @res

select CAST(@res as float(8))

select CONVERT(FLOAT, @res)

select ROUND(@res,8)

select CONVERT(varchar, ROUND(@res, 8))

I think the real reason its broken is because the underlying datatype stores values in scientific notation then breaks the integer and decimal parts into base numeric datatypes. n x 10^x. So, 123.9994 is actually stored as 1.239994 x 10^-2 then placed into variables holding the constituent parts: 1, 239994, and -2. The rounding problem is when a numeric component (say the 239994 part) is larger than the base datatype holds. A way to hold that number is to also store it as a float, also held in scientific notation (e.g., 2.39994 X 10-5). Doing this recursively until every component numeric is stored in a short int (or any convenient datatype), works fine for storage, until you try to do math on the mess.

See the thing is, you could do the inverse and it would work fine to regenerate the original number; however, math operations on floating point numbers are much simpler when dealing with numbers already stored in scientific notation. I bet they’re making the same mistake Intel did with the original Pentium chip. Recall that the original Pentiums incorrectly stored numbers in scientific notation incorrectly past the 14 digit past the decimal. My guess? Because the number was being stored in a word (2 bytes, 16 digits) instead of a long (4 bytes, 32 digits). The 16 digits were being stored as x.yyyyyyyyyyyyyy. If there were more significant digits that 14, the Pentium chip programmers incorrectly handled these, I allege.

The problem with changing a bug like this in SQL Server is that it is probably in the original code delivered by SyBase when MS acquired the SQL Server technology from them in the early ’90s. Back then, we had very few 32-bit chips, so who cares about storing a number with more significant digits than could be stored? So the bug is in the bowels and I wonder if anyone at Microsoft understands that original code very well. The problem with fixing it is probably due to people’s memory and not the desire to get it right. The bug is just too fundamental for me to believe that no one caught it since it’s pretty obvious. Clearly they are rationalizing it away and hoping no one has to have this fixed. How else could such a fundamental bug be swept under the rug for so long?

This is just speculation, of course. Let’s hope it is fixed in MS SQL Server 2008!





Welcome to Zyggy’s Lounge

17 11 2008

Hi all,

This site is my pure Tech site. I’ve decided to blog about all things Tech, Web2.0 and Social Media here, and keep my activism, personal thoughts, and artistic material over at Whiskey Mambo. Hope you like what you see, but since the is the first post, that’s not much. Look out for “the in sound from way out” as it were, and please keep the conversation going!

Thanks,

Stephen