(This is a classic asp page pulling data from an oracle database) I basically just want the first if statement to overwrite the second statement in the case that the criteria of the first if statement is met. So basically if the league_id value is 0 and the team id value is 0 I would like the tSQL function to display main.cfb_division_id = 1" and - Division: I-A"...any help on how to edit my code to do that would be great...thanks
The value of league_id along with other filter(TeamId, etc) decides what is going to be displayed on the page, I want the following to happen: If league_id and team_id filters are both unselected (so basically value = "0") I want league_id to display main.cfb_division_id = 1" otherwise if team_id has a value I want league_id to remain with a value of "0"...hope this clarify's
and incase it help's, here's the code that set's the other filters...
Code:
If iLeagueID = "0" and iTeamID = "0" then
tSQL = tSQL & " AND main.cfb_division_id = 1"
tPlayerFilter = tPlayerFilter & " - Division: I-A"
End If
If iLeagueID = "0" Then
tSQL = tSQL
tPlayerFilter = tPlayerFilter
ElseIf iLeagueID = "2" Then
tSQL = tSQL & " AND main.cfb_division_id = 2"
tPlayerFilter = tPlayerFilter & " - Division: I-AA"
ElseIf iLeagueID = "9" Then
tSQL = tSQL & " AND main.cfb_division_id = 9"
tPlayerFilter = tPlayerFilter & " - Division: I-A + I-AA"
ElseIf iLeagueID = "1" Then
tSQL = tSQL & " AND main.cfb_division_id = 1"
tPlayerFilter = tPlayerFilter & " - Division: I-A"
End If
The value of league_id along with other filter(TeamId, etc) decides what is going to be displayed on the page, I want the following to happen: If league_id and team_id filters are both unselected (so basically value = "0") I want league_id to display main.cfb_division_id = 1" otherwise if team_id has a value I want league_id to remain with a value of "0"...hope this clarify's
and incase it help's, here's the code that set's the other filters...
Code:
'Add Team/Conference Filter
If iTeamID <> "" Then
tSQL = tSQL & " AND main.team_id =" & iTeamID
tPlayerFilter = tPlayerFilter & " - Team:" & tTeamName
ElseIf iConfID <> "" Then
tSQL = tSQL & " AND main.conference_id =" & iConfID
tPlayerFilter = tPlayerFilter & " - Conf:" & tConfName
End If