<% if session("sql") <> "" then
''Response.Write Request.querystring
Call SpecialistList(Request.QueryString("search"), "", "", Request.QueryString("extra"), Request.QueryString("Spec3"), Request.QueryString("Spec4"), Request.QueryString("search"), Request.QueryString("Spec1"), Request.QueryString("Spec2"))
else
Response.Write("Sorry but the parameters set to display this information have been lost, please search the information again")
end if
%>
|
<%else %>
<%dim where, val, tbl, buildwhere, txtCriteria, idfield, descfld1, descfld2
session("sql") = ""
buildwhere = ""
txtCriteria = ""
'Response.Write request.form("WIDESPECIALISTSEARCHSUBMIT")
if (request.form("subject") <> "" AND Request.form("WIDESPECIALISTSEARCHSUBMIT") <> "") OR (Request.querystring("subject") <> "" AND Request.querystring("num") <> "") then
if Request.Form("subject") <> "" then
callsubject = request.form("subject")
else
callsubject = Request.QueryString("subject")
end if
'direct call from specialistsearch.asp
'criteria passed will be subject dependant
if callsubject = "ab" then
'ARCHAEBOTANY RECORD
subject = "ArchaeoBotany"
if Request.Form <> "" then
if Request.Form("AreaList") <> "" then
if buildwhere <> "" then buildwhere = buildwhere & " AND "
buildwhere = buildwhere & "[Area] LIKE '%" & Request.form("AreaList") & "%'"
txtCriteria = txtCriteria & " Area: " & Request.form("AreaList")
end if
if Request.Form("YearList") <> "" then
if buildwhere <> "" then buildwhere = buildwhere & " AND "
buildwhere = buildwhere & "[Year] = " & Request.form("YearList")
txtCriteria = txtCriteria & " Year: " & Request.form("YearList")
end if
if Request.Form("SoilVol") <> "" then
if buildwhere <> "" then buildwhere = buildwhere & " AND "
buildwhere = buildwhere & "[Soil Volume] = '" & Request.form("SoilVol") & "'"
txtCriteria = txtCriteria & " Soil Vol: " & Request.form("SoilVol")
end if
if Request.Form("FlotNum") <> "" then
if buildwhere <> "" then buildwhere = buildwhere & " AND "
buildwhere = buildwhere & "[Flot Number] = '" & Request.form("FlotNum") & "'"
txtCriteria = txtCriteria & " Flot Number: " & Request.form("FlotNum")
end if
if Request.Form("SampleNum") <> "" then
if buildwhere <> "" then buildwhere = buildwhere & " AND "
buildwhere = buildwhere & "[Sample Number] = '" & Request.form("SampleNum") & "'"
txtCriteria = txtCriteria & " Sample Number: " & Request.form("SampleNum")
end if
if Request.Form("FlotNotes") <> "" then
if buildwhere <> "" then buildwhere = buildwhere & " AND "
buildwhere = buildwhere & "[Flot Team Notes] LIKE '%" & Request.form("FlotNotes") & "%'"
txtCriteria = txtCriteria & " Notes: " & Request.form("FlotNotes")
end if
'new jan 2007 - unit num added to search
if Request.Form("unit") <> "" then
if buildwhere <> "" then buildwhere = buildwhere & " AND "
buildwhere = buildwhere & "[Unit Number] = " & Request.Form("unit")
txtCriteria = txtCriteria & " Unit: " & Request.Form("unit")
end if
' ClayObjectShapes
else
'call to show a list of numbers for a unit
if Request.Querystring("num") <> "" then
if buildwhere <> "" then buildwhere = buildwhere & " AND "
buildwhere = buildwhere & "[Unit Number] = " & Request.Querystring("num")
txtCriteria = txtCriteria & " Unit: " & Request.querystring("num")
end if
end if
idfield = "Flot Number"
descfld1 = "Sample Number"
descfld2 = "Flot Team Notes"
'update subject to Flot
subject = "Flot"
if txtCriteria <> "" then txtCriteria = " where " & txtCriteria
if buildwhere <> "" then where = "WHERE " & buildwhere
tbl = "[view_Web_Specialist_Bot_Basic_Data]"
elseif callsubject = "cer" then
'CERAMICS RECORD - two sets of different data exist must see which one has GId
subject = "Ceramics"
'CeramicElements
elseif callsubject = "clayobj" then
'CLAY OBJECTS RECORD
subject = "Clay Objects"
if Request.Form <> "" then
if Request.Form("AreaList") <> "" then
if buildwhere <> "" then buildwhere = buildwhere & " AND "
buildwhere = buildwhere & "[Area] LIKE '%" & Request.form("AreaList") & "%'"
txtCriteria = txtCriteria & " Area: " & Request.form("AreaList")
end if
if Request.Form("YearList") <> "" then
if buildwhere <> "" then buildwhere = buildwhere & " AND "
buildwhere = buildwhere & "[Year] = " & Request.form("YearList")
txtCriteria = txtCriteria & " Year: " & Request.form("YearList")
end if
if Request.Form("ClayObjectShapes") <> "" then
if buildwhere <> "" then buildwhere = buildwhere & " AND "
buildwhere = buildwhere & "[Shape] LIKE '%" & Request.form("ClayObjectShapes") & "%'"
txtCriteria = txtCriteria & " Shape: " & Request.form("ClayObjectShapes")
end if
if Request.Form("ClayObjectColors") <> "" then
if buildwhere <> "" then buildwhere = buildwhere & " AND "
buildwhere = buildwhere & "[Color] LIKE '%" & Request.form("ClayObjectColors") & "%'"
txtCriteria = txtCriteria & " Colour: " & Request.form("ClayObjectColors")
end if
'new jan 2007 - unit num added to search
if Request.Form("unit") <> "" then
if buildwhere <> "" then buildwhere = buildwhere & " AND "
buildwhere = buildwhere & "[Unit No] = " & Request.Form("unit")
txtCriteria = txtCriteria & " Unit: " & Request.Form("unit")
end if
' ClayObjectShapes
' ClayObjectColors
else
'call to show a list of numbers for a unit
if Request.Querystring("num") <> "" then
if buildwhere <> "" then buildwhere = buildwhere & " AND "
buildwhere = buildwhere & "[Unit No] = " & Request.Querystring("num")
txtCriteria = txtCriteria & " Unit: " & Request.querystring("num")
end if
end if
idfield = "GID"
descfld1 = "Shape"
descfld2 = "Color"
if txtCriteria <> "" then txtCriteria = " where " & txtCriteria
if buildwhere <> "" then where = "WHERE " & buildwhere
tbl = "[view_Web_Specialist_ClayObjects]"
elseif callsubject = "cs" then
'CHIPPED STONE RECORD
subject = "Chipped Stone"
if Request.Form <> "" then
if Request.Form("AreaList") <> "" then
if buildwhere <> "" then buildwhere = buildwhere & " AND "
buildwhere = buildwhere & "[Area] LIKE '%" & Request.form("AreaList") & "%'"
txtCriteria = txtCriteria & " Area: " & Request.form("AreaList")
end if
if Request.Form("YearList") <> "" then
if buildwhere <> "" then buildwhere = buildwhere & " AND "
buildwhere = buildwhere & "[Year] = " & Request.form("YearList")
txtCriteria = txtCriteria & " Year: " & Request.form("YearList")
end if
if Request.Form("CSRawMat") <> "" then
if buildwhere <> "" then buildwhere = buildwhere & " AND "
buildwhere = buildwhere & "[RawMaterial] LIKE '%" & Request.form("CSRawMat") & "%'"
txtCriteria = txtCriteria & " Raw Material: " & Request.form("CSRawMat")
end if
if Request.Form("CS>Count") <> "" OR Request.Form("CS "" then
if buildwhere <> "" then buildwhere = buildwhere & " AND "
if Request.Form("CS>Count") <> "" then
buildwhere = buildwhere & "[Count] > " & Request.form("CS>Count")
txtCriteria = txtCriteria & " Count >: " & Request.form("CS>Count")
end if
if Request.Form("CS>Count") <> "" AND Request.Form("CS "" then
buildwhere = buildwhere & " AND "
txtCriteria = txtCriteria & " and "
end if
if Request.Form("CS "" then
buildwhere = buildwhere & "[Count] < " & Request.form("CS "" then
if buildwhere <> "" then buildwhere = buildwhere & " AND "
buildwhere = buildwhere & "[Unit] = " & Request.Form("unit")
txtCriteria = txtCriteria & " Unit: " & Request.Form("unit")
end if
else
'call to show a list of numbers for a unit
if Request.Querystring("num") <> "" then
if buildwhere <> "" then buildwhere = buildwhere & " AND "
buildwhere = buildwhere & "[Unit] = " & Request.Querystring("num")
txtCriteria = txtCriteria & " Unit: " & Request.querystring("num")
end if
end if
idfield = "BagNo"
descfld1 = "RawMaterial"
descfld2 = "GeneralDescription"
if txtCriteria <> "" then txtCriteria = " where " & txtCriteria
if buildwhere <> "" then where = "WHERE " & buildwhere
tbl = "[view_Web_Specialist_ChippedStone_Basic_Data]"
'CSRawMat
elseif callsubject = "cons" then
'CONSERVATION RECORD - new Jan 2007
subject = "Conservation"
if request.form <> "" then
if Request.Form("AreaList") <> "" then
if buildwhere <> "" then buildwhere = buildwhere & " AND "
buildwhere = buildwhere & "[Area] LIKE '%" & Request.form("AreaList") & "%'"
txtCriteria = txtCriteria & " Area: " & Request.form("AreaList")
end if
if Request.Form("YearList") <> "" then
if buildwhere <> "" then buildwhere = buildwhere & " AND "
buildwhere = buildwhere & "[ConservationRef_Year] = " & Request.form("YearList")
txtCriteria = txtCriteria & " Year: " & Request.form("YearList")
end if
if Request.Form("ConservatorName") <> "" then
if buildwhere <> "" then buildwhere = buildwhere & " AND "
buildwhere = buildwhere & "[ConservatorNames] like '%," & replace(Request.form("ConservatorName"), "'", "''") & ",%'"
txtCriteria = txtCriteria & " Conserved By: " & Request.form("ConservatorName")
end if
if Request.Form("Description") <> "" then
if buildwhere <> "" then buildwhere = buildwhere & " AND "
buildwhere = buildwhere & "[Description] like '%" & Request.form("Description") & "%'"
txtCriteria = txtCriteria & " Description contains: " & Request.form("Description")
end if
if Request.Form("Condition") <> "" then
if buildwhere <> "" then buildwhere = buildwhere & " AND "
buildwhere = buildwhere & "[Condition] like '%" & Request.form("Condition") & "%'"
txtCriteria = txtCriteria & " Condition contains: " & Request.form("Condition")
end if
if Request.Form("PreviousTreatment") <> "" then
if buildwhere <> "" then buildwhere = buildwhere & " AND "
buildwhere = buildwhere & "[Previous Treatment] like '%" & Request.form("PreviousTreatment") & "%'"
txtCriteria = txtCriteria & " Previous Treatment contains: " & Request.form("PreviousTreatment")
end if
if Request.Form("Treatment") <> "" then
if buildwhere <> "" then buildwhere = buildwhere & " AND "
buildwhere = buildwhere & "[Treatment] like '%" & Request.form("Treatment") & "%'"
txtCriteria = txtCriteria & " Treatment contains: " & Request.form("Treatment")
end if
if Request.Form("Packing") <> "" then
if buildwhere <> "" then buildwhere = buildwhere & " AND "
buildwhere = buildwhere & "[Packing] like '%" & Request.form("Packing") & "%'"
txtCriteria = txtCriteria & " Packing contains: " & Request.form("Packing")
end if
if Request.Form("TechAnalysis") <> "" then
if buildwhere <> "" then buildwhere = buildwhere & " AND "
buildwhere = buildwhere & "[Technical Analysis] like '%" & Request.form("TechAnalysis") & "%'"
txtCriteria = txtCriteria & " Technical Analysis contains: " & Request.form("TechAnalysis")
end if
if Request.Form("Recomend") <> "" then
if buildwhere <> "" then buildwhere = buildwhere & " AND "
buildwhere = buildwhere & "[Recommended] like '%" & Request.form("Recomend") & "%'"
txtCriteria = txtCriteria & " Recommendation contains: " & Request.form("Recomend")
end if
if Request.Form("ConsRelatedTo") <> "" then
if buildwhere <> "" then buildwhere = buildwhere & " AND "
select case Request.form("ConsRelatedTo")
case "1"
txtCriteria = txtCriteria & " Related to: Building"
case "2"
txtCriteria = txtCriteria & " Related to: Space"
case "3"
txtCriteria = txtCriteria & " Related to: Feature"
case "4"
txtCriteria = txtCriteria & " Related to: Unit"
case "5"
txtCriteria = txtCriteria & " Related to: Objects in Unit"
case "6"
txtCriteria = txtCriteria & " Related to: Samples in Unit"
end select
if Request.Form("ExcavationIDNumber") <> "" then
'related to subtype (unit, feature, space etc) plus a number
buildwhere = buildwhere & "[RelatedToList] like '%," & Request.form("ConsRelatedTo") & ";" & Request.Form("ExcavationIDNumber") & ",%'"
txtCriteria = txtCriteria & " " & Request.Form("ExcavationIDNumber")
else
'only related to type
buildwhere = buildwhere & "[RelatedToList] like '%," & Request.form("ConsRelatedTo") & ";%'"
end if
'txtCriteria = txtCriteria & " Related to: " & Request.form("ConsRelatedTo")
end if
else
'call to show a list of numbers for a unit
if Request.Querystring("num") <> "" then
if Request.QueryString("type") <> "" then
'related to something other than a unit number
if Request.QueryString("type") = "building" then
buildwhere = buildwhere & "([RelatedToList] like '%,1;" & Request.Querystring("num") & ",%')"
txtCriteria = txtCriteria & " Building: " & Request.querystring("num")
elseif Request.QueryString("type") = "space" then
buildwhere = buildwhere & "([RelatedToList] like '%,2;" & Request.Querystring("num") & ",%')"
txtCriteria = txtCriteria & " Space: " & Request.querystring("num")
elseif Request.QueryString("type") = "feature" then
buildwhere = buildwhere & "([RelatedToList] like '%,3;" & Request.Querystring("num") & ",%')"
txtCriteria = txtCriteria & " Feature: " & Request.querystring("num")
end if
else
if buildwhere <> "" then buildwhere = buildwhere & " AND "
'buildwhere = buildwhere & "([RelatedToSubTypeID] = 4 AND [ExcavationIDNumber] = " & Request.Querystring("num") & ")"
'buildwhere = buildwhere & " OR ([RelatedToSubTypeID] = 5 AND [ExcavationIDNumber] = " & Request.Querystring("num") & ")"
'buildwhere = buildwhere & " OR ([RelatedToSubTypeID] = 6 AND [ExcavationIDNumber] = " & Request.Querystring("num") & ")"
'buildwhere = buildwhere & " OR ([RelatedToSubTypeID] = 7 AND [ExcavationIDNumber] = " & Request.Querystring("num") & ")"
buildwhere = buildwhere & "([RelatedToList] like '%,4;" & Request.Querystring("num") & ",%')"
buildwhere = buildwhere & " OR ([RelatedToList] like '%,5;" & Request.Querystring("num") & ",%')"
buildwhere = buildwhere & " OR ([RelatedToList] like '%,6;" & Request.Querystring("num") & ",%')"
buildwhere = buildwhere & " OR ([RelatedToList] like '%,7;" & Request.Querystring("num") & ",%')"
txtCriteria = txtCriteria & " Unit: " & Request.querystring("num")
end if
end if
end if
idfield = "FullConservation_Ref"
descfld1 = "Description"
descfld2 = "Condition"
if txtCriteria <> "" then txtCriteria = " where " & txtCriteria
if buildwhere <> "" then where = "WHERE " & buildwhere
''response.write buildwhere
'tbl = "[view_Web_Specialist_Conservation_RelatedTo]"
tbl = "[view_Web_Specialist_Conservation_Basic_2005on]"
elseif callsubject = "faunal" then
'FAUNAL RECORD
subject = "Faunal"
if request.form <> "" then
if Request.Form("AreaList") <> "" then
if buildwhere <> "" then buildwhere = buildwhere & " AND "
buildwhere = buildwhere & "[Area] LIKE '%" & Request.form("AreaList") & "%'"
txtCriteria = txtCriteria & " Area: " & Request.form("AreaList")
end if
if Request.Form("YearList") <> "" then
if buildwhere <> "" then buildwhere = buildwhere & " AND "
buildwhere = buildwhere & "[Year] = " & Request.form("YearList")
txtCriteria = txtCriteria & " Year: " & Request.form("YearList")
end if
if Request.Form("FaunalElement") <> "" then
if buildwhere <> "" then buildwhere = buildwhere & " AND "
buildwhere = buildwhere & "[ElementText] = '" & Request.form("FaunalElement") & "'"
txtCriteria = txtCriteria & " Element: " & Request.form("FaunalElement")
end if
if Request.Form("FaunalTaxon") <> "" then
if buildwhere <> "" then buildwhere = buildwhere & " AND "
buildwhere = buildwhere & "[TaxonText] = '" & Request.form("FaunalTaxon") & "'"
txtCriteria = txtCriteria & " Taxon: " & Request.form("FaunalTaxon")
end if
'new jan 2007 - unit num added to search
if Request.Form("unit") <> "" then
if buildwhere <> "" then buildwhere = buildwhere & " AND "
buildwhere = buildwhere & "[Unit Number] = " & Request.Form("unit")
txtCriteria = txtCriteria & " Unit: " & Request.Form("unit")
end if
'FaunalElementList
'FaunalTaxonList
else
'call to show a list of numbers for a unit
if Request.Querystring("num") <> "" then
if buildwhere <> "" then buildwhere = buildwhere & " AND "
buildwhere = buildwhere & "[Unit Number] = " & Request.Querystring("num")
txtCriteria = txtCriteria & " Unit: " & Request.querystring("num")
end if
end if
idfield = "GID"
descfld1 = "TaxonText"
descfld2 = "ElementText"
if txtCriteria <> "" then txtCriteria = " where " & txtCriteria
if buildwhere <> "" then where = "WHERE " & buildwhere
tbl = "[view_Web_Specialist_Fauna_Bone_Basic_Faunal_Data_RestrictedDataAllYears]"
elseif callsubject = "fig" then
'FIGURINE RECORD - extend dec 06
subject = "Figurines"
if Request.Form <> "" then
if Request.Form("AreaList") <> "" then
if buildwhere <> "" then buildwhere = buildwhere & " AND "
buildwhere = buildwhere & "[Area] LIKE '%" & Request.form("AreaList") & "%'"
txtCriteria = txtCriteria & " Area: " & Request.form("AreaList")
end if
if Request.Form("YearList") <> "" then
if buildwhere <> "" then buildwhere = buildwhere & " AND "
buildwhere = buildwhere & "[Year] = " & Request.form("YearList")
txtCriteria = txtCriteria & " Year: " & Request.form("YearList")
end if
if Request.Form("FigObjectType") <> "" then
if buildwhere <> "" then buildwhere = buildwhere & " AND "
'buildwhere = buildwhere & "([Object type1] = '" & Request.form("FigObjectType") & "' OR [Object type2] ='" & Request.form("FigObjectType") & "' OR [object type3] = '" & Request.form("FigObjectType") & "')"
buildwhere = buildwhere & "[ObjectTypes] like '%," & Request.form("FigObjectType") & ",%'"
txtCriteria = txtCriteria & " Object Type: " & Request.form("FigObjectType")
end if
if Request.Form("FigPrimaryFabric") <> "" then
if buildwhere <> "" then buildwhere = buildwhere & " AND "
buildwhere = buildwhere & "[Primary Fabric] LIKE '%" & Request.form("FigPrimaryFabric") & "%'"
txtCriteria = txtCriteria & " Primary fabric: " & Request.form("FigPrimaryFabric")
end if
'new dec 2006 - unit num added to search
if Request.Form("unit") <> "" then
if buildwhere <> "" then buildwhere = buildwhere & " AND "
buildwhere = buildwhere & "[UnitNumber] = " & Request.Form("unit")
txtCriteria = txtCriteria & " Unit: " & Request.Form("unit")
end if
if Request.Form("FigObjectForm") <> "" then
if buildwhere <> "" then buildwhere = buildwhere & " AND "
'buildwhere = buildwhere & "([Object form1] = '" & Request.form("FigObjectForm") & "' OR [Object form2] ='" & Request.form("FigObjectForm") & "' OR [object form3] = '" & Request.form("FigObjectForm") & "')"
buildwhere = buildwhere & "[Object Form] = '" & Request.form("FigObjectForm") & "'"
txtCriteria = txtCriteria & " Object Form: " & Request.form("FigObjectform")
end if
if Request.Form("FigForm") <> "" then
if buildwhere <> "" then buildwhere = buildwhere & " AND "
'buildwhere = buildwhere & "([form1] = '" & Request.form("FigForm") & "' OR [form2] ='" & Request.form("FigForm") & "' OR [form3] = '" & Request.form("FigForm") & "')"
buildwhere = buildwhere & "[FigForms] like '%," & Request.form("FigForm") & ",%'"
txtCriteria = txtCriteria & " Form: " & Request.form("Figform")
end if
if Request.Form("FigFormType") <> "" then
if buildwhere <> "" then buildwhere = buildwhere & " AND "
'buildwhere = buildwhere & "([form Type1] = '" & Request.form("FigFormType") & "' OR [form Type2] ='" & Request.form("FigFormType") & "' OR [form Type3] = '" & Request.form("FigFormType") & "')"
buildwhere = buildwhere & "[FormTypes] like '%," & Request.form("FigFormType") & ",%'"
txtCriteria = txtCriteria & " Form Type: " & Request.form("FigformType")
end if
if Request.Form("FigSexFeature") <> "" then
if buildwhere <> "" then buildwhere = buildwhere & " AND "
'buildwhere = buildwhere & "([Sex Features1] = '" & Request.form("FigSexFeature") & "' OR [Sex Features2] ='" & Request.form("FigSexFeature") & "')"
buildwhere = buildwhere & "[SexFeatures] like '%," & Request.form("FigSexFeature") & ",%'"
txtCriteria = txtCriteria & " Sex Features: " & Request.form("FigSexFeature")
end if
if Request.Form("FigSexInterpretation") <> "" then
if buildwhere <> "" then buildwhere = buildwhere & " AND "
'buildwhere = buildwhere & "([Sex Interpretation1] = '" & Request.form("FigSexInterpretation") & "' OR [Sex Interpretation2] ='" & Request.form("FigSexInterpretation") & "')"
buildwhere = buildwhere & "[SexInterp] like '%," & Request.form("FigSexInterpretation") & ",%'"
txtCriteria = txtCriteria & " Sex Interpretation: " & Request.form("FigSexInterpretation")
end if
if Request.Form("FigDetail") <> "" then
if buildwhere <> "" then buildwhere = buildwhere & " AND "
'buildwhere = buildwhere & "([Details1] = '" & Request.form("FigDetail") & "' OR [Details2] ='" & Request.form("FigDetail") & "' OR [Details3] = '" & Request.form("FigDetail") & "')"
buildwhere = buildwhere & "[Details] like '%," & Request.form("FigDetail") & ",%'"
txtCriteria = txtCriteria & " Detail: " & Request.form("FigDetail")
end if
else
'call to show a list of numbers for a unit
if Request.Querystring("num") <> "" then
if buildwhere <> "" then buildwhere = buildwhere & " AND "
buildwhere = buildwhere & "[UnitNumber] = " & Request.Querystring("num")
txtCriteria = txtCriteria & " Unit: " & Request.querystring("num")
end if
end if
idfield = "ID number"
'descfld1 = "ObjectTypeList"
descfld1 = "ObjectTypes"
descfld2 = "Primary fabric"
if txtCriteria <> "" then txtCriteria = " where " & txtCriteria
if buildwhere <> "" then where = "WHERE " & buildwhere
'tbl = "[view_Web_Specialist_Fig_MainData]"
tbl = "[view_Fig_MainData_Collated]"
'Response.Write buildwhere
' FigObjectType
' FigPrimaryFabric
elseif callsubject = "gs" then
'GROUNDSTONE RECORD
subject = "Ground Stone"
if Request.Form <> "" then
if Request.Form("GSWorked") = "GSWorkedYes" OR Request.Form("GSWorked") = "GSWorkedNo" then
'worked or unworked
if Request.Form("GSWorked") = "GSWorkedYes" then
if buildwhere <> "" then buildwhere = buildwhere & " AND "
'buildwhere = buildwhere & "[Worked?] = 1"
'change 2010
buildwhere = buildwhere & "[Worked?] <> '1 - UNWORKED'"
txtCriteria = txtCriteria & " Worked: Yes"
elseif Request.Form("GSWorked") = "GSWorkedNo" then
if buildwhere <> "" then buildwhere = buildwhere & " AND "
'buildwhere = buildwhere & "[Worked?] = 0"
'change 2010
buildwhere = buildwhere & "[Worked?] = '1 - UNWORKED'"
txtCriteria = txtCriteria & " Worked: No"
end if
end if
if Request.Form("AreaList") <> "" then
if buildwhere <> "" then buildwhere = buildwhere & " AND "
buildwhere = buildwhere & "[Area] LIKE '%" & Request.form("AreaList") & "%'"
txtCriteria = txtCriteria & " Area: " & Request.form("AreaList")
end if
if Request.Form("YearList") <> "" then
if buildwhere <> "" then buildwhere = buildwhere & " AND "
buildwhere = buildwhere & "[Year] = " & Request.form("YearList")
txtCriteria = txtCriteria & " Year: " & Request.form("YearList")
end if
if Request.Form("GSRawMat") <> "" then
if buildwhere <> "" then buildwhere = buildwhere & " AND "
'buildwhere = buildwhere & "[RawMaterial] LIKE '%" & Request.form("GSRawMat") & "%'"
'change 2010
buildwhere = buildwhere & "[Raw Material] LIKE '%" & Request.form("GSRawMat") & "%'"
txtCriteria = txtCriteria & " Raw Material: " & Request.form("GSRawMat")
end if
if Request.Form("GSArtType") <> "" then
if buildwhere <> "" then buildwhere = buildwhere & " AND "
'buildwhere = buildwhere & "[GeneralDescription] LIKE '%" & Request.form("GSArtType") & "%'"
'change 2010
buildwhere = buildwhere & "[Artefact Type] LIKE '%" & Request.form("GSArtType") & "%'"
txtCriteria = txtCriteria & " Artefact Type: " & Request.form("GSArtType")
end if
'new jan 2007 - unit num added to search
if Request.Form("unit") <> "" then
if buildwhere <> "" then buildwhere = buildwhere & " AND "
buildwhere = buildwhere & "[Unit] = " & Request.Form("unit")
txtCriteria = txtCriteria & " Unit: " & Request.Form("unit")
end if
else
'call to show a list of numbers for a unit
if Request.Querystring("num") <> "" then
if buildwhere <> "" then buildwhere = buildwhere & " AND "
buildwhere = buildwhere & "[Unit] = " & Request.Querystring("num")
txtCriteria = txtCriteria & " Unit: " & Request.querystring("num")
end if
end if
idfield = "GID"
'descfld1 = "RawMaterial"
'descfld2 = "GeneralDescription"
'change 2010
descfld1 = "Raw Material"
descfld2 = "Artefact Type"
if txtCriteria <> "" then txtCriteria = " where " & txtCriteria
if buildwhere <> "" then where = "WHERE " & buildwhere
tbl = "[view_Web_Specialist_Groundstone1_Basic_Data]"
elseif callsubject = "hr" then
'HEAVY RESIDUE RECORD
subject = "Heavy Residue Materials with GID "
if Request.Form <> "" then
if Request.Form("AreaList") <> "" then
if buildwhere <> "" then buildwhere = buildwhere & " AND "
buildwhere = buildwhere & "[Area] LIKE '%" & Request.form("AreaList") & "%'"
txtCriteria = txtCriteria & " Area: " & Request.form("AreaList")
end if
if Request.Form("YearList") <> "" then
if buildwhere <> "" then buildwhere = buildwhere & " AND "
buildwhere = buildwhere & "[Year] = " & Request.form("YearList")
txtCriteria = txtCriteria & " Year: " & Request.form("YearList")
end if
if Request.Form("HRMaterial") <> "" then
if buildwhere <> "" then buildwhere = buildwhere & " AND "
buildwhere = buildwhere & "[Material] LIKE '%" & Request.form("HRMaterial") & "%'"
'buildwhere = buildwhere & "[MaterialList] LIKE '%," & Request.form("HRMaterial") & ",%'"
txtCriteria = txtCriteria & " Material: " & Request.form("HRMaterial")
end if
'new jan 2007 - unit num added to search
if Request.Form("unit") <> "" then
if buildwhere <> "" then buildwhere = buildwhere & " AND "
buildwhere = buildwhere & "[Unit] = " & Request.Form("unit")
txtCriteria = txtCriteria & " Unit: " & Request.Form("unit")
end if
else
'call to show a list of numbers for a unit
if Request.Querystring("num") <> "" then
if buildwhere <> "" then buildwhere = buildwhere & " AND "
buildwhere = buildwhere & "[Unit] = " & Request.Querystring("num")
txtCriteria = txtCriteria & " Unit: " & Request.querystring("num")
end if
end if
idfield = "GID"
descfld1 = "Material"
'descfld1 = "MaterialList"
descfld2 = "Comments"
if txtCriteria <> "" then txtCriteria = " where " & txtCriteria
if buildwhere <> "" then where = "WHERE " & buildwhere
tbl = "[view_Web_Specialist_HR_Material]"
'tbl = "[view_Web_Specialist_HR_Basic_Data]"
'HRMaterial
elseif callsubject = "mf" then
'MICROFAUNAL RECORD - new march 2007
subject = "Microfaunal"
if request.form <> "" then
if Request.Form("AreaList") <> "" then
if buildwhere <> "" then buildwhere = buildwhere & " AND "
buildwhere = buildwhere & "[Area] LIKE '%" & Request.form("AreaList") & "%'"
txtCriteria = txtCriteria & " Area: " & Request.form("AreaList")
end if
if Request.Form("YearList") <> "" then
if buildwhere <> "" then buildwhere = buildwhere & " AND "
buildwhere = buildwhere & "[Year] = " & Request.form("YearList")
txtCriteria = txtCriteria & " Year: " & Request.form("YearList")
end if
if Request.Form("MFElement") <> "" then
if buildwhere <> "" then buildwhere = buildwhere & " AND "
buildwhere = buildwhere & "[ElementText] = '" & Request.form("MFElement") & "'"
txtCriteria = txtCriteria & " Element: " & Request.form("MFElement")
end if
if Request.Form("MFTaxon") <> "" then
if buildwhere <> "" then buildwhere = buildwhere & " AND "
buildwhere = buildwhere & "[TaxonText] = '" & Request.form("MFTaxon") & "'"
txtCriteria = txtCriteria & " Taxon: " & Request.form("MFTaxon")
end if
if Request.Form("unit") <> "" then
if buildwhere <> "" then buildwhere = buildwhere & " AND "
buildwhere = buildwhere & "[Unit Number] = " & Request.Form("unit")
txtCriteria = txtCriteria & " Unit: " & Request.Form("unit")
end if
else
'call to show a list of numbers for a unit
if Request.Querystring("num") <> "" then
if buildwhere <> "" then buildwhere = buildwhere & " AND "
buildwhere = buildwhere & "[Unit Number] = " & Request.Querystring("num")
txtCriteria = txtCriteria & " Unit: " & Request.querystring("num")
end if
end if
idfield = "GID"
descfld1 = "TaxonText"
descfld2 = "ElementText"
if txtCriteria <> "" then txtCriteria = " where " & txtCriteria
if buildwhere <> "" then where = "WHERE " & buildwhere
tbl = "[view_Web_Specialist_MicroFauna_Basic_Data_Restricted]"
elseif callsubject = "phyto" then
'PHYTOLITH RECORD
'new jan 2007
subject = "Phytolith Sample "
if Request.Form <> "" then
'if Request.Form("AreaList") <> "" then
' if buildwhere <> "" then buildwhere = buildwhere & " AND "
' buildwhere = buildwhere & "[Area] LIKE '%" & Request.form("AreaList") & "%'"
' txtCriteria = txtCriteria & " Area: " & Request.form("AreaList")
'end if
'if Request.Form("YearList") <> "" then
' if buildwhere <> "" then buildwhere = buildwhere & " AND "
' buildwhere = buildwhere & "[Year] = " & Request.form("YearList")
' txtCriteria = txtCriteria & " Year: " & Request.form("YearList")
'end if
if Request.Form("PhytoYear") <> "" then
if buildwhere <> "" then buildwhere = buildwhere & " AND "
buildwhere = buildwhere & "[ProcessYear] = " & Request.form("PhytoYear")
txtCriteria = txtCriteria & " Year: " & Request.form("PhytoYear")
end if
if Request.Form("PhytoStage") <> "" then
if buildwhere <> "" then buildwhere = buildwhere & " AND "
buildwhere = buildwhere & "[AnalysisStage] = '" & Request.form("PhytoStage") & "'"
txtCriteria = txtCriteria & " Analysis Stage: " & Request.form("PhytoStage")
end if
if Request.Form("Notes") <> "" then
if buildwhere <> "" then buildwhere = buildwhere & " AND "
buildwhere = buildwhere & "[Notes] like '%" & Request.form("Notes") & "%'"
txtCriteria = txtCriteria & " Notes contains: " & Request.form("Notes")
end if
if Request.Form("unit") <> "" then
if buildwhere <> "" then buildwhere = buildwhere & " AND "
buildwhere = buildwhere & "[Unit] = " & Request.Form("unit")
txtCriteria = txtCriteria & " Unit: " & Request.Form("unit")
end if
else
'call to show a list of numbers for a unit
if Request.Querystring("num") <> "" then
if buildwhere <> "" then buildwhere = buildwhere & " AND "
buildwhere = buildwhere & "[Unit] = " & Request.Querystring("num")
txtCriteria = txtCriteria & " Unit: " & Request.querystring("num")
end if
end if
idfield = "GID"
descfld1 = "AnalysisStage"
'descfld1 = "MaterialList"
descfld2 = "Notes"
if txtCriteria <> "" then txtCriteria = " where " & txtCriteria
if buildwhere <> "" then where = "WHERE " & buildwhere
tbl = "[view_Web_Specialist_Phytolith_Basic]"
'Response.Write buildwhere
end if
end if
'Response.Write request.form
if where <> "" then
'Response.Write " idfield: "& idfield & " where: "& where & " tbl: "& tbl & " txtCriteria: "& txtCriteria & " subject: "& subject & " callsubject: "& callsubject & " idfield: "& idfield & " descfld1: "& descfld1 & " descfld2: "& descfld2 &" "
Call SpecialistList(idfield, where, tbl, txtCriteria, subject, callsubject, idfield, descfld1, descfld2)
else
Response.Write("No criteria entered")
end if%>
|
<% end if
end if%>