| | |
Complicated SQL SELECT Statement - NEWBIE
Please support our MS SQL advertiser: Intel Parallel Studio Home
![]() |
It's me again...the newbie. I have a web application that I am developing for a school project. Quick overview; the user submits one of multiple different types of "requests" and then a technican begins work on the project. Anyway; with the help of others I have gotten the EXTREMELY long insert query complete and functional. My next step is to pull data for the "home page". The home page will show users a "summar" of requests that their name is associated to but is also (obviously) based on who is logged in. Anyway; I have created this query but it is returning NOTHING so I know it's not right but I'm not sure where I messed up...even though the query may not be done in the best manner this is all the data that i would need from my tables.
SELECT Project.ProjectID, RequestorName, BusinessUnitName, ProjectTypeName
FROM Project,Requestor,BusinessUnit,ProjectType, aspnet_Users, ProjectTechs
WHERE (Project.RequestorID = Requestor.RequestorID
AND Project.BusinessUnitID = BusinessUnit.BusinessUnitID
AND Project.ProjectTypeID = ProjectType.ProjectTypeID)
AND aspnet_Users.DisplayName = Requestor.RequestorName
OR aspnet_Users.DisplayName = ProjectTechs.UserId
Thank you; in advance!
SELECT Project.ProjectID, RequestorName, BusinessUnitName, ProjectTypeName
FROM Project,Requestor,BusinessUnit,ProjectType, aspnet_Users, ProjectTechs
WHERE (Project.RequestorID = Requestor.RequestorID
AND Project.BusinessUnitID = BusinessUnit.BusinessUnitID
AND Project.ProjectTypeID = ProjectType.ProjectTypeID)
AND aspnet_Users.DisplayName = Requestor.RequestorName
OR aspnet_Users.DisplayName = ProjectTechs.UserId
Thank you; in advance!
![]() |
Similar Threads
- Hi,Need help on sql select statement structure (MS SQL)
- SQL select statement help (MS Access and FileMaker Pro)
- Question about SELECT statement (MySQL)
- Getting current value in Select Statement (MS SQL)
- cfselect issue trying to get results from a sql select statement (ColdFusion)
- Program Problem with a select statement to access Data base (C)
Other Threads in the MS SQL Forum
- Previous Thread: help with paging in sql 2000
- Next Thread: datetime decrement
| Thread Tools | Search this Thread |
Tag cloud for MS SQL
"last autogrowth business connectingtodatabaseinuse count cursor data database dateadd datepart day" dbsize deadlock delete_trigger getdate highperformancecomputing hpc hpcserver2008 ibm iis limit loop maximum microsoft ms mssql multiple multithreading news number permission position query reporting result server services sets single source sql sqlserver sqlserver2005 subtype supercomputing supertype tables uniqueid update view weekday





