09-17-2012 01:45 PM
I cross-posted this over in the HE community; my apologies to those who see it twice. (This posting is a little different, anyway.)
We are revisiting our Student AFKWS and want to add a couple keyword types for one of our offices. One of the secondary keyword types is Major. A relatively small number of students (about 1.5%) have two majors.
If we were manually indexing (and weren't using keyword type groups?) we could make a second instance of the Major keyword type on the documents. But I want to maintain the keywords from the student information system using an AFKWS processor.
Am I correct in concluding that I cannot create a second instance of the Major keyword type on a document through an AFKWS? I think that leaves me with three choices:
09-17-2012 02:09 PM
Hi Les
I have this exact type of case for some of my AFKWS. You can do what you want. In setting set "expand All Matching Instance".
I hope this helps (BTW I am on 12 But first used it in 10)
Scott
Here is an example Vb code (note rule_nbr may have multiple values):
Sub GetKeywordSetRecords(primaryvalue, keysetdef, results)
Set conn = CreateObject("ADODB.Connection")
conn.ConnectionString = "DSN=<DSNNAME>;"
conn.Open()
Dim rs
Dim txt
Dim strQuery
Dim primaryval
primaryval = primaryvalue
txt = " My Query String ...."
strQuery = Replace(txt, "_filter_", trim(primaryval))
set rs = conn.execute(strQuery)
If (Not rs.EOF) Then
Call rs.MoveFirst
dim RecFound
RecFound = false
Do While Not rs.EOF
Dim keyvalue
Call results.BeginRow()
keyvalue = rs("fac_id")
If Not Isnull(keyvalue) Then
Call results.AddData("Facility ID", keyvalue)
End If
keyvalue = rs("case_nbr")
Call results.AddData("HB Case Nbr", keyvalue)
keyvalue = rs("name")
If Not Isnull(keyvalue) Then
Call results.AddData("Facility Name", keyvalue)
End If
keyvalue = rs("address")
If Not Isnull(keyvalue) Then
Call results.AddData("Address", keyvalue)
keyvalue = rs("hb_city")
Call results.AddData("City", keyvalue)
keyvalue = rs("hb_zip")
Call results.AddData("Zip Code", keyvalue)
Else
keyvalue = rs("address2")
If Not Isnull(keyvalue) Then
Call results.AddData("Address", keyvalue)
keyvalue = rs("city")
Call results.AddData("City", keyvalue)
keyvalue = rs("zip")
Call results.AddData("Zip Code", keyvalue)
End If
End If
keyvalue = trim(rs("rule_nbr"))
If Not Isnull(keyvalue) Then
Call results.AddData("Rule Nbr", keyvalue)
End If
Call results.EndRow()
RecFound = true
Call rs.MoveNext
Loop
Else
'No records found
End If
rs.close
set rs = nothing
conn.close
set conn = Nothing
End Sub
09-17-2012 02:43 PM
Scott, is that code for an External AFKWS? I don't think I can use an External AFKWS: I'm trying to update keyword sets and also keyword values on existing documents as changes occur in our ERP. I know how to do that with an AFKWS Processor, but I didn't think you could do that with External AFKWS?
Find what you came for
We want to make your experience in Hyland Connect as valuable as possible, so we put together some helpful links.