Showing posts with label date. Show all posts
Showing posts with label date. Show all posts

Thursday, March 22, 2012

AT the moment i have an SQL SELECT Statement as follows....

SELECT H.id, H.CategoryID ,H.Image ,H.StoryId ,H.Publish, H.PublishDate, H.Date ,H.Deleted ,SL.ListTitle

FROM HomePageImage H

JOIN shortlist SL on H.StoryId = SL.id

order by date DESC

is it possible to join to another table in the same query to get a value out.

it would be JOIN categories C on H.CategoryID = C.CategoryID

is this possible. can anyone help?

This should help

http://www.vb-tips.com/InnerJoin.aspx

|||

is this what you want?

SELECT H.id, H.CategoryID ,H.Image ,H.StoryId ,H.Publish, H.PublishDate, H.Date ,H.Deleted ,SL.ListTitle

FROM HomePageImage H

JOIN shortlist SL on H.StoryId = SL.id JOIN categores C on h.CategoryID=C.CategoryID

order by H.date DESC

|||

Yes, Thanks for help.

Monday, March 19, 2012

assistance please....

What is the easiest way to check the date and time of service pack updates?

What do you mean by that `?

Thursday, February 16, 2012

asp.net want to make SQL time format of 00:00:00:000 to 14:42:51:153 when inserting in dat

I have asp.net 1.1 web form and it inserts date and time in SQL database, but it insert only date not time , It insert date time in following format

2002-01-22 00:00:00.000

some one tell me why it is not inserting time or why it is inserting time as 00:00:00:000.

I want to my time to look like 14:42:51:153. (format)

How can I change my time format

give me asp.net codes for time formating or what do I need to do to resolve the problem,

thank you

maxmax

I think your application is not sending the date properly. Do a response.write of the value you are sending to the db and verify.

asp.net SQL query between given two time

I have asp.net applicatin with SQL database communicating. in database I have date field and time field. Now I wan to do SQL query which can pull informatin on particular date between given start time to given end time

Can some one show me sample SQL query so I can pull informatin on particular day between two times

thank you

maxmax

http://sqljunkies.com/HowTo/6676BEAE-1967-402D-9578-9A1C7FD826E5.scuk

|||

select *
from sometable
where datefield between '11/2/07' and '11/15/07'

returns all records from 12:00:00 AM on 11/2/07 (that is, just after midnight of 11/1) through and including midnight of 11/15/07

You can add time values very easily:

select *
from sometable
where datefield between '2007-11-1613:30:31.497' and '2007-11-1613:31:05.670'