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)
 16 table max in SQL 6.5

Author  Topic 

AskSQLTeam
Ask SQLTeam Question

0 Posts

Posted - 2002-04-24 : 10:40:55
nevets72 writes "I just attempted to create a Crystal Report, via a view, but I got the following message:

The query and the views in it exceed the limit of 16 tables.

I'm not sure what options I have.....I really can't create a table based on the functionality of the application I'm using. What can I do?

The view in question is as follows:

CREATE VIEW Rpt_Actuals (Month, Pool_Category_ID, Staffing_Pools_ID, Project_ID, Manager_ID, PIV_ID, Task_ID, Division_ID, Group_ID, Team_ID, Job_Code_ID, Employee_ID, Hours, Total_Hours, MA_Indicator) AS
SELECT Manpower.Month, Pool_Category.Pool_Category_ID, Staffing_Pools.Staffing_Pools_ID, Projects.Project_ID, Employees_1.Employee_ID, Task.PIV_ID, Task.Task_ID, Employees.Division_ID, Employees.Group_ID, Employees.Team_ID, Employees.Job_Code_ID, Employees.Employee_ID, Sum(Manpower.Hours), Totals.Hours, "N"
FROM Access_Code Access_Code, Employees, Employees Employees_1, Manpower Manpower, Pool_Category Pool_Category, Project_Categories Project_Categories, Projects Projects, Staffing_Pools Staffing_Pools, Task Task, Totals Totals
WHERE Employees.Employee_ID = Manpower.Employee_ID AND Task.PIV_ID = Manpower.PIV_ID AND Task.Task_ID = Manpower.Task_ID AND Projects.Project_ID = Project_Categories.Project_ID AND Access_Code.Access_Code_ID = Project_Categories.Access_Code_ID AND Access_Code.Access_Code_ID = Task.Access_Code_ID AND Staffing_Pools.Staffing_Pools_ID = Project_Categories.Staffing_Pools_ID AND Pool_Category.Pool_Category_ID = Staffing_Pools.Pool_Category_ID AND Totals.Employee_ID = Employees.Employee_ID AND Totals.Month = Manpower.Month AND Employees_1.Employee_ID = Projects.Employee_ID AND (Employees.Status_ID IN (1, 2, 3, 4, 5)) and Projects.Project_ID != 435
GROUP BY Manpower.Month, Pool_Category.Pool_Category_ID, Staffing_Pools.Staffing_Pools_ID, Projects.Project_ID, Employees_1.Employee_ID, Task.PIV_ID, Task.Task_ID, Employees.Division_ID, Employees.Group_ID, Employees.Team_ID, Employees.Job_Code_ID, Employees.Employee_ID, Totals.Hours
Union All
SELECT * FROM dbo.Rpt_Actuals_MA"

AndrewMurphy
Master Smack Fu Yak Hacker

2916 Posts

Posted - 2002-04-24 : 11:29:04
I don't see where the 16 is being exceeded...i can only count 10 tables, 1 view and whatever is the contents of the UNION ALL....


is this a VIEW?....based on multiple tables?...given that it NAMED something LIKE the view being created?


could you convert this VIEW into a TEMPORARY table....fill the table, then use it, then dispose of it?




Running the query ouside of Crystal Reports, will help decide if Crystal is the source of your problem....if QA refuses to run the query, then Crystal isn't the problem...if QA does...then Crystal is the problem.

Go to Top of Page
   

- Advertisement -