Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

which query u can write to sql server doesn't work
inbetween 7.00PM to nextday 9.00AM

Answer Posted / sumesh

Declare @hour varchar(100)
set @time=convert(varchar,getdate(),114)
set @hour=SUBSTRING(@time,1,2)
if(convert(int,@hour)>8 and convert(int,@hour)<19)
begin
print @time
print @hour
end

Is This Answer Correct ?    11 Yes 3 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

how can a database be repaired? : Sql server administration

979


What happens if time-only values are provided as date and time literals?

1019


Explain view in sql server?

1058


Difference Between ORDER BY Clause and GROUP BY Clause in SQL?

1060


What are subqueries in sql server? Explain its properties.

1022


Can I disable or restrict ssrs export formats (rendering formats)?

150


What is de-normalization and what are some of the examples of it?

976


you have separate development and production systems you want to move a copy of a development database into production to do this, you do a backup on the development system and restore to the production system after a few minutes, you begin getting calls from several customers saying that they are denied access to the system why? : Sql server administration

988


Can a synonym name of a table be used instead of a table name in a select statement?

1039


What are the common performance issues in sql server?

930


Explain what you mean by 3 tier architecture.

1077


How would you add a section to a table?

1051


Differentiate between mongodb vs. Sql server?

1102


What are the components of dbms?

954


What are the properties of sub-query?

1075