Skip to content

Mohsin Sumar

Writing and sharing my experience. I'm a Zend Certified PHP Professional with over 15 years of technical experience in all things web.

  • Contact
  • About Me

Tag Archives: mysql random number

Generate 4 digit random PIN number in MySQL

I recently came across a problem where I had to update hundreds of client records with a random 4 digit PIN code. After some research, I wrote the following SQL which did the trick. It will update all records on the table: table_name and set a random 4 digit PIN between 1,000 and 9,999 on […]

Posted byMohsin SumarApril 22, 2012Posted inMySQLTags: generate random number in mysql, mysql random number, mysql random pin number, random integer in mysql

Recent Posts

  • Security Advisory: New Email Scam claiming hackers have your password
  • “There is nothing so useless as doing efficiently that which should not be done at all.”  —  Peter Drucker
  • SSL is no longer optional for your website.
  • Don’t be afraid of being different
  • Preventing email spoofing with SPF

Archives

  • October 2018
  • September 2018
  • April 2017
  • January 2016
  • December 2015
  • November 2015
  • October 2015
  • April 2012
  • November 2011
  • March 2011
  • January 2011
  • December 2010
  • July 2010
  • June 2010
  • May 2010
  • March 2010
  • November 2009
  • October 2009
  • September 2009

Categories

  • Apache
  • Articles
  • BlackBerry
  • Books
  • Business
  • Entrepreneur
  • Extreme Web Technologies
  • General
  • Javascript
  • Marketing
  • MySQL
  • PHP
  • Search Engine Optimization
  • Security
  • Server Management
  • SSH
  • Startup
  • Tips & Tricks
  • Tutorials
  • Web Hosting
  • Web Presence
  • Words of Wisdom
Mohsin Sumar, Proudly powered by WordPress.