------- Forwarded message follows -------
Send reply to:          "Bjarne Jensen" <[EMAIL PROTECTED]>
From:                   "Bjarne Jensen" <[EMAIL PROTECTED]>
To:                     "John Jensen" <[EMAIL PROTECTED]>
Subject:                
Date sent:              Mon, 29 Jan 2001 13:17:29 -0800

We need help solving a mysql programming problem on our commercial
website. We have an online database of over 5,000 college degree
programs that can be searched by our customers.

To narrow the search results down to a manageable number, our
customers select from predefined search parameters.  They also 
specify
their state of residence so the search will return the appropriate
in-state vs out of state tuition for each degree program.

The search looks for degrees that match the customer search 
parameters
and compares the customers state with the state of the college to
return in-state vs out-of-state tuition.

The search routine returns appropriate degree information but shows
in-state tuition for all customers. As I see it, the problem is, we
are conducting a search within a search. If anyone can help us we are
willing to pay for your expertise.

See code particulars below.
------- End of forwarded message -------
In determining tuition for a query, we can do:

        $FORMATQUERY ORDER BY RequirementExpenses.TuitionInState $sortby"; 

or: 
        $FORMATQUERY ORDER BY RequirementExpenses.TuitionOutState $sortby";

but not both at the same time. Every school has the state listed in a 
table, which is compared with the state input with the query. Once 
all the information is extracted and a selection is made, the 
subsequent display can show the correct tuition with an if-then 
routine:

if ($State eq $row[40]) {
  $TUITION = $row[28];
 } else {
  $TUITION = $row[29];
 }

but our customer, in making the initial query, does not have correct 
tuition to make a selection from. This is not acceptable and we need 
a solution to this problem.

John Jensen
Jensen's Directories
www.college-without-classes.com/

---------------------------------------------------------------------
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/           (the list archive)

To request this thread, e-mail <[EMAIL PROTECTED]>
To unsubscribe, e-mail <[EMAIL PROTECTED]>
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php

Reply via email to