MySQL

This is for those who work with MySQL.


The article at the end of this entry talks about how the storage engines(MyISAM, InnoDB, etc.) works. Since I use the default storage engine (MyISAM), it’s helpful to know about the difference between static rows and dynamic rows.


I’m going to review the database structure I’ve come up with for a project at work and see if I can make changes to make the rows static.


MySQL Storage Engine Architecture, Part 2 – An In-Depth Look


Wishing you lower seektimes.

Wow…

Must be a damn unlucky day for me. I received a code red 2 attack but I could not confirm the damage it had done if any. Downloaded the tool from symantec but it did not detect any code red viruses on my web server, Chii. Worse, I experienced network problems and could not get my server online to get a virus scan done.


Then I tried reinstalling the OS, didn’t work too. So I tried connecting the ethernet cable to another port on my router and it worked! Guess it’s a faulty router port [:(]. Still thinking whether or not I should get it replaced. I certainly can’t stand being disconnected from the net or unable to access my computer while I’m outside.


I’ve installed as much patches as I could find from Microsoft’s website. And installed URLScan 2.5 for IIS 4.0 and above. The default configuration for URLScan immediately blocks .asp extension which is why my blog didn’t work well today. I’m done with the config file now. To those who run their webservers from home, on IIS, I highly recommend this tool, URLScan 2.5. Just remember to take a look through the documentation to learn about the config file. If you have it installed on IIS 6.0, remember to recycle your worker processes to have the new changes in URLScan config file applied.


My projects at work are slowly progressing and getting more interesting. Each day there’s a different problem to tackle and many things to learn. Today, I learned that magic_quotes_gpc turned on in a php configuration is EVIL.

A 1am blog

Right now, I’m reading up on IIS6.0 and helping out someone on PHP. Then I looked at my desk lamp and thought of LAMP.


LAMP basically means a combination of Linux, Apache, MySQL, PHP. Operating system, web server, database server, server-side scripting technology(?). Then I’ve heard of WAMP: Windows, Apache, MySQL, PHP. Then, note that in the office, I’m using Windows2000 and IIS5.0, we have WIMP: Windows, IIS, MySQL, PHP.


I’m basically a WIMP! [X(]

Public holidays on Saturdays don’t mean a thing

Unless it’s on Sunday or a weekday, public holidays on Saturdays are practically useless to me. I don’t need to work on Saturdays anyway.


I have been communicating with my company’s webhost for the past few days. Mostly because I have to shift our website to a Linux server from a Windows server. We needed 2 websites on the same server in order to share the same database. Main point: the admins must be working so hard and are so tired that they typed ‘play’ instead of ‘please’.


A lot of updates/changes have to be done with my codes for Linux systems are strict on case sensitivity. ‘Cat’ and ‘cat’ may be the same thing to Windows but different to a Linux. I guess I have myself to blame for bicapitalizing my table names. There were some issues with mySQL that lower cased my table names but I wasn’t affected much since I was using Windows on my development machine so was my webhost.


Haven’t been playing Lineage 2 much because of an update. The update servers were so flooded I had to wait 2 days for my updating to speed up. But because of that, I was able to spend some time on my other tasks.


And finally, owing to what I experienced at work today, I would like to shout out INDEXES ARE IMPORTANT to all who wish to dive into databases. Because they may help speed up your sql queries greatly and ENSURE NO DUPLICATE ENTRIES.


Good luck and may you have better clockspeeds. [:)]

hows and whys for PHP

Ever since I picked up PHP as my next server scripting language, I did not look back to ASP or ASP.NET. PHP has so many built in functions such as file uploads, sending email that we can readily use unlike ASP, where we would have to purchase and install 3rd party DLLs.


I can’t say much about ASP.NET cos I’ve only experienced it for 3-4 months during my Final Year Project at Nanyang Polytechnic. But I believe it is as good as PHP and could be better because the ASP.NET page is “compiled”. PHP may have this same feature by purchasing Zend’s products or some free alternatives I’ve seen.


Why I’m so concerned about already-built-in functionalities is because of webhosting providers. The company I work pays a certain webhost company to host our projects. The first project for me when I first joined the company was done in ASP. It was hell because I needed file uploads and the script I was using heavily burdens the CPU on the webserver. Uploading a small file would take ages and I do not have access to install 3rd party DLLs to handle file uploads. The webhost only provided mySQL as the database server. No SQLServer. Getting ASP to run with mySQL was another big problem. [:(]


Then for my next 2 projects, I decided to give PHP a try. I had confidence in my learning skills because of my past experiences in ASP and some other scripting/programming languages. I believed I had a good grasp of the essence of programming (and I still do now! hee).


It didn’t take me long to get used to the new syntax and coding style. In fact, it was quite easy. Pretty soon, I could code without the need to refer to examples in ebooks I have downloaded. I loved the file uploads capability built into PHP. We could even specify a maximum filesize limit so the user doesn’t have to upload the whole file only to realize it’s too big and then he has to go through the long process of uploading again. PHP has support for mySQL so I didn’t need to install any plugins like I did for ASP on my development machine in order to connect to a mySQL database. [:D]


I learned to use the PHP manual online which turned out to be the greatest help. I also got some simple questions answered on IRC at freenode’s #php and #mysql (in case the links don’t work for you, the IRC server is irc.freenode.net). Questions like “How do I do this?” would be asked at a forum called NerdBrains where friendly knowledgeable people would provide helpful hints to the best solution.


I wouldn’t mind .NET only if instructed by my boss. I would never go back to ColdFusion or ASP. I am currently satisfied and happily living in the world of PHP. [XD]


Note: I do realize that my blog and quotes website are in ASP. They were both created before I learned PHP. I just needed to find time to convert them both to PHP but I’m quite reluctant to do so because I wish to use Access database to store my data. [:)]