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.
Author |
Topic |
cpat258
Starting Member
3 Posts |
Posted - 2012-11-10 : 17:48:55
|
I have executed three tables in my program. They are MOVIE, VIEWER and RATING. Within the MOVIE table i have MovieID, MovieTitle,IMDB_URL and a couple movie genres. With every MovieTitle there is a date(year only) in it. I have to list all the movies that have been released in 1982 and sort them in alphabetical order. I DO NOT have a release date field in this. However i found out the MovieID of movies. They are 89,214,228,414,423,440,527,629,632,638 and 674) All these MovieID were released in 1982. I came up with a code but it doesn't work. Can somebody help me out here? What am i doing wrong?SELECT Movietitle FROM Movie WHERE MovieID=('89','214','228','414','423','440','527','629','632','638','674') ORDER BY MovieTitle ASCChirag Patel |
|
tkizer
Almighty SQL Goddess
38200 Posts |
|
cpat258
Starting Member
3 Posts |
Posted - 2012-11-10 : 19:52:04
|
Thanks i got it. Im using wildcard in thisSELECT MovieTitleFROM MovieWHERE MovieTitle like '%(1982)'ORDER BY MovieTitle ASCChirag Patel |
|
|
|
|
|
|
|