Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2000 Forums
 SQL Server Development (2000)
 queries problem

Author  Topic 

asifbhura
Posting Yak Master

165 Posts

Posted - 2006-01-22 : 09:02:37
hi evryone

i want my freinds name who borrowed ever movies from me and movie name 'titanic'.

I tried like as below

select freinds_name from freinds where movie_name='titanic' and borrowin_date<today'sdate

I want to write like this but i dont know how to write borrowing date must be before today's date.

another question is related like this

i want query that will list the names of my friends who are current borrowing one or more CDs and the number of days since the borrowed it..

select freinds_name from freinds where returned_date = null and today's_date- borrowed date

I want number of days since CDs are borrowed. If returned date is not null means that cds have been returned.

I want both queries solved

Please help me.

Waiting for reply.

khtan
In (Som, Ni, Yak)

17689 Posts

Posted - 2006-01-22 : 09:08:57
Dup Post http://www.sqlteam.com/forums/topic.asp?TOPIC_ID=60680

-----------------
'KH'

Go to Top of Page
   

- Advertisement -