Since the date is stored as String in hive you can use the date functions to get the hour.
Just check whether the hour falls in between 10 and 11 AM
In simple terms,
WHERE hour('date')>= 10 AND hour('date') <= 11
If you want to consider the date as well then you need to play with the unix timestamp value or extract the date and include the logic in where clause.
Sent from handheld, please excuse typos.
From: Soham Sardar <[EMAIL PROTECTED]>
Date: Mon, 25 Jun 2012 12:58:23
To: <[EMAIL PROTECTED]>
Reply-To: [EMAIL PROTECTED]
Subject: querying with datetime in hive and mysql
i have a problem with querying with the datetime format of mysql and
then it has to stored in the string format and nothing else and then
when i try to query in it say name the users who logged between 10 to
11 am in time coz i am using LIKE which matches pattern and then i
cant give like for all the time instances ... can some one help me out
with this as to how to implement these types of querying both in HIVE