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
 Transact-SQL (2000)
 No results

Author  Topic 

bharatvly
Starting Member

1 Post

Posted - 2014-09-30 : 06:09:29
Hi Team,

I write very basic SQL queries and for some reason below query isn't pulling any data. It is blank. Can someone help please if anythign is wrong here?

select p.provider_id, p.provider_name, cps.provider_status_name, ces.external_system_name, cpt.property_tier_name
from provider p, c_provider_status cps, extsys_content esc, c_external_system ces, c_property_tier cpt, property_config pc, c_property_config_param cpcp
where p.provider_status_code = cps.provider_status_code
and ces.external_system_id = esc.external_system_id
and p.provider_id = esc.provider_id
and ces.external_system_id in ('82')
and pc.provider_id = p.provider_id
and pc.config_param_value = cpt.property_tier_id
and pc.property_config_param_id = cpcp.property_config_param_id
and cpcp.property_config_param_id in ('5');

Bharat.

gbritton
Master Smack Fu Yak Hacker

2780 Posts

Posted - 2014-09-30 : 10:35:38
Please post some sample data as
1. CREATE TABLE commands for the tables involved
2. INSERT INTO commands to populate the tables with test data
3. The results you get by running your query against the tables built in steps 1 and 2
4. The results you want when run against the same data.
Go to Top of Page
   

- Advertisement -