Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
* appearing as total
Message
From
25/11/1999 16:44:00
 
 
To
All
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Title:
* appearing as total
Miscellaneous
Thread ID:
00295641
Message ID:
00295641
Views:
69
Here is my query:

select distinct instructor.instructorid, course.courseid, studentcourse.sckey,;
(iif(studentcourse.ispaid = .T.,(course.hours * paymodel.rate) *
count(studentcourse.courseid),0)) as total;
from course left join studentcourse on course.courseid = studentcourse.courseid;
left join instructor on studentcourse.instructorid = instructor.instructorid;
left join paymodel on instructor.training = paymodel.traintype;
into cursor temppay;
group by course.courseid

This gives me all the courses even if they don't have an instructor. I then want to check if in the studentcourse table if the ispaid field is true. If it is I want to total up how much they are to be paid. If not they get 0 for that student. The total is 0 for all the ones that ispaid = .F. but the ones that equal true the total field equals a star(*). Does anyone know why this is happening? I don't know if it really makes sense.

Thanks in advance,
Tyler
Next
Reply
Map
View

Click here to load this message in the networking platform