Posts Tagged ‘update’

MySQL specific shortcuts

Thursday, July 24th, 2008

MySQL provides many extentions to SQL which help performance in many common use scenarios. Among these are INSERT … SELECT, INSERT … ON DUPLICATE KEY UPDATE, and REPLACE.

I rarely hesitate to use the above since they are so convenient and provide real performance benefits in many situations. MySQL has other keywords which are more dangerous, however, and should be used sparingly. These include INSERT DELAYED, which tells MySQL that it is not important to insert the data immediately (say, e.g., in a logging situation). The problem with this is that under high load situations the insert might be delayed indefinitely, causing the insert queue to baloon. You can also give MySQL index hints about which indices to use. MySQL gets it right most of the time and when it doesn’t it is usually because of a bad scheme or poorly written query.

Web Designing-Take advantage of the cascade

Wednesday, July 16th, 2008

The cascade lets you use multiple rules to specify the properties for an element. You can either redefine the same property or define additional properties. Let’s say you have the following markup:

1. <p class=”update”>Update: Lorem ipsum dolor set</p>

In the CSS, you can use separate rules to specify the properties that are common to all p elements and those that are specific to p elements with class=”update”:

1. p {
2. margin:1em 0;
3. font-size:1em;
4. color:#333;
5. }
6. .update {
7. font-weight:bold;
8. color:#600;
9. }

The two rules will be combined for p elements with class=”update”. Since a class selector is more specific than a type selector, the properties defined in the second rule will be used when a conflict occurs, as for color in this case.

More info on how the specificity of CSS rules is calculated can be found in Calculating a selector’s specificity in the CSS 2.1 specification.

Google Shares Three Ranking Philosophies

Monday, July 14th, 2008

The Google Search Quality Team is keeping its promise to explain more about how they conduct their work. As usual and expected, it’s fantastically vague, but since a chunk of our readers at any given time are new to search, it’s worth going over.

Writing on the Official Google blog, Amit Singhal, a Google Fellow on the Core Ranking Team, defines Google ranking:

“Google ranking is a collection of algorithms used to find the most relevant documents for a user query. We do this for hundreds of millions of queries a day, from a collection of billions and billions of pages. These algorithms are run for every query entered into most of Google’s search services. While our web search is the most used Google search service and the most widely known, the same ranking algorithms are also used - with some modifications - for other Google search services, including Images, News, YouTube, Maps, Product Search, Book Search, and more.”

Then he gave three philosophies that the Core Ranking Team follows:

1) Best locally relevant results served globally.
2) Keep it simple.
3) No manual intervention.

Singhal says that the team strives for simplicity in their architecture, something that Twitter has been struggling with lately. Obviously, with all the queries conducted and the massive amount of content to be indexed, it coud be easy to piece together a very complex architecture (similar to Google’s woes with their ad products). With approximately 10 ranking updates per week, Singhal says the team takes simplicity in architecture into consideration in every single update.

Singhal also emphasized philosophy #3 - that Google does not hand edit results.

“You are the ones creating pages and linking to pages. We are using all this human contribution through our algorithms. The final ordering of the results is decided by our algorithms using the contributions of the greater Internet community, not manually by us.”

MYSQL:How to GRANT SELECT, INSERT, UPDATE, DELETE in MySQL

Monday, June 30th, 2008

GRANT SELECT, INSERT, UPDATE, DELETE ON *.* TO ‘user’@'%’ identified by ‘password’;

PHP:Update user last login time

Monday, June 30th, 2008

//updates last login time
$USER_ID = $_SESSION[ 'USER_ID' ];
$last_login = gmdate(”Y-m-d”);
$sql = “UPDATE somedb.users SET last_login = ‘$last_login’ WHERE id = ‘$USER_ID’”;
$result = @mysql_query($sql,$connection) or die(mysql_error());

Firefox:Automated Update

Friday, June 27th, 2008

Our open-source security strategy lets us find—and fix—security issues in record time, making Firefox the safest way to surf. Install upgrades when you receive automatic notification or wait until you’re ready.

Does more content means better SEO?

Thursday, June 26th, 2008

Search Engine Optimization is complicated because Search Engines do not want you to figure out how they work or how they rank web sites. This is important because otherwise everyone would be able to manipulate them in order to be able reach the top. This is also why Search Engines always update their algorithms.

What you need to do is remember what the basic reasons are for people to go to a web site. These include:

1. Entertainment
2. Information
3. It sells something that you need.

Ensuring that you have a site that people will want to go to will help you rank better with the Search Engines. Of course, if you have a specialized web site then there is probably already enough content for anyone who wants it. However, many pages of really good content will help you here. Plus, as you create more content people will want to return to your web site to see what you have written. They will then continue to return if they like what they see.

All of this has to do with on site SEO, meaning the steps that you take in order to optimize your web site from the inside out. This is important because every page of content will be indexed by the Search Engines and thus each one will have its own title and tags. This will in turn bring you a lot more traffic to your web site. So, yes, more content does mean better SEO for your web site.

10 Spring Cleaning Tips for your Web Site

Thursday, June 26th, 2008

1. Update Any Scripts and Plugins - Look at WordPress, Joomla and any other scripts or services you have installed and see if it is time to give them an upgrade. You should be doing this more often than every spring but now is a good time to check and make sure.

2. Do Your E-mail Addresses Work? - I recently got an e-mail from a friend who told me, “Sorry I didn’t get back to you I just figured out I had major problems with my e-mail account”. Send yourself a dummy message to make sure you don’t fall into the same boat.

3. Clean up Your Sidebars - This ‘bit of advice would be mainly for blogs. I have seen some people become really addicted to having sidebar widgets and gadgets. If you have more than five per sidebar, might be time to ditch some or at least make them look pretty again.

4. Review your Terms of Service - Make sure your terms of service and acceptable use policy are up to date and include everything you wish to include there. You may have made some changes to your web site and business since the last time you reviewed it so check it out now to make sure all your bases are still covered.

5. Check and Update your Sitemaps - If you have a Google Webmaster Tools account, it might be a good time to login and check to make sure Google didn’t find any errors, which would keep them from indexing certain parts of your web site.

6. Is Your Contact Information Correct? - Check out your contact page and make sure that the numbers, e-mail addresses and postal addresses listed there are up to date and show the correct information.

7. Renew Your Domains - When does your domain name run out of date? Might need to check and also be sure that you have all your hosting bills paid up too. This also makes for a good time to upgrade your hosting account to one with a few more perks.

8. Test Your Web Site Links - Are all your web site links working? Check your error logs in your various stats packages to see where people are finding 404s and try to fix all the broken links or non-existent pages you can find.

9. How Out of Date is Your “About Us” Section? - Checking out my own about us page on one of my other web sites I see I pretty much haven’t updated it since the launch of the site. Always good to keep this up to date because well, this is how people lean more about you and what you do.

10. Spellcheck Your Web Site Content - How many grammar errors can you find on your web site? If you don’t want to read through everything you have posted - you might try just going through a few of the most popular ones and making sure they are correct. Bad spelling really peeves some people, so best not to get on anybody’s bad side.

Update your blog frequently

Thursday, June 26th, 2008

Update your blog frequently using all the rules mentioned above and your blog will surely get top rankings in a short time.

GOOGLE FACTS

Friday, June 20th, 2008

Google’s index is updated every day as Google crawls the web. There pretty much is always an update going on.

Google has algorithms and data pushes that are going out on a less frequent basis. The latest were on 27 June, 28 July and 17 August.

Google’s BigDaddy update was a software infrastructure upgrade that finished in February. The BigDaddy update introduced a new way how they crawl the web.

Matt Cutts mentions in the video that another software infrastructure update is on the way. The new update should increase the quality of the search results:

“If we find out that we can improve quality by changing our algorithms or data or infrastructure, or anything else, we’re going to make that change.

The best SEO’s in my experience are the ones that can adapt, and that say ‘OK, this is the way the algorithms look right now to me, if I want to make a good site that will do well in search engines, this is the direction I want to head in next.’”