For any corporate training requirements Please mail To sudhakar@qtpsudhakar.com
Course Name Date Time Duration Type Location
An important update from QtpSudhakar. I stopped giving classroom training in MindQ Systems. I have bigger plans and I want to put an end to regular classroom training because very less people are practicing. From now onwards every session of mine is going to have explanation and practice. Everyone should practice in presence of mine and should go out of classroom with practical knowledge. So I started my own institute AnyTechLabs in Madhapur. Please reach out to +91-8328152362 for course details. Visit AnyTechLabs.com for address details.
Selenium + Cucumber 24th October 7.30 AM IST to 9.00 AM IST 45 Days WeekDay Online

A book "Cracking the QTP interview" authored by Sudhakar.Read More. Buy From FlipKart

Thursday, March 12, 2009

Regular Expression for Date and time

Date Regular Expression:

Format: MM/DD/YYYY

MM: (0[1-9]|1[0-2])

DD: (0[1-9]|1[0-9]|2[0-9]|3[0-1])

YYYY: ([0-9][0-9][0-9][1-9]|[1-9]000|[1-9][1-9]00|[1-9][1-9][1-9]0)

* Assuming that Max year is 9999

Time Regular Expression:

Max Time: 23:59:59
Min  Time: 00:00:00

Hours: ([0-1][0-9]|2[0-3])

Mins: ([0-5][0-9])

Secs: ([0-5][0-9])

Special Character Explanation
| -- OR
Ex: a|b means a or b

( ) -- Used to group multiple regular expressions
[-] -- To specify a range

a[x-z]=ax, ay , az

1 comment :

  1. include [1-9][1-9][1-9][1-9] in the year of a date so that 9999 matches.