# /research/top1000/poll/favorites.asp

originally: http://www.oclc.org/research/top1000/poll/favorites.asp

# What's your favorite?

Select your favorite work from the short list you've created.

<% '---- CursorTypeEnum Values ---- Const adOpenForwardOnly = 0 Const adOpenKeyset = 1 Const adOpenDynamic = 2 Const adOpenStatic = 3 '---- CursorOptionEnum Values ---- Const adHoldRecords = &H00000100 Const adMovePrevious = &H00000200 Const adAddNew = &H01000400 Const adDelete = &H01000800 Const adUpdate = &H01008000 Const adBookmark = &H00002000 Const adApproxPosition = &H00004000 Const adUpdateBatch = &H00010000 Const adResync = &H00020000 Const adNotify = &H00040000 Const adFind = &H00080000 '---- LockTypeEnum Values ---- Const adLockReadOnly = 1 Const adLockPessimistic = 2 Const adLockOptimistic = 3 Const adLockBatchOptimistic = 4 '---- ExecuteOptionEnum Values ---- Const adRunAsync = &H00000010 Const adAsyncExecute = &H00000010 Const adAsyncFetch = &H00000020 Const adAsyncFetchNonBlocking = &H00000040 Const adExecuteNoRecords = &H00000080 '---- ConnectOptionEnum Values ---- Const adAsyncConnect = &H00000010 '---- ObjectStateEnum Values ---- Const adStateClosed = &H00000000 Const adStateOpen = &H00000001 Const adStateConnecting = &H00000002 Const adStateExecuting = &H00000004 Const adStateFetching = &H00000008 '---- CursorLocationEnum Values ---- Const adUseServer = 2 Const adUseClient = 3 '---- DataTypeEnum Values ---- Const adEmpty = 0 Const adTinyInt = 16 Const adSmallInt = 2 Const adInteger = 3 Const adBigInt = 20 Const adUnsignedTinyInt = 17 Const adUnsignedSmallInt = 18 Const adUnsignedInt = 19 Const adUnsignedBigInt = 21 Const adSingle = 4 Const adDouble = 5 Const adCurrency = 6 Const adDecimal = 14 Const adNumeric = 131 Const adBoolean = 11 Const adError = 10 Const adUserDefined = 132 Const adVariant = 12 Const adIDispatch = 9 Const adIUnknown = 13 Const adGUID = 72 Const adDate = 7 Const adDBDate = 133 Const adDBTime = 134 Const adDBTimeStamp = 135 Const adBSTR = 8 Const adChar = 129 Const adVarChar = 200 Const adLongVarChar = 201 Const adWChar = 130 Const adVarWChar = 202 Const adLongVarWChar = 203 Const adBinary = 128 Const adVarBinary = 204 Const adLongVarBinary = 205 Const adChapter = 136 Const adFileTime = 64 Const adDBFileTime = 137 Const adPropVariant = 138 Const adVarNumeric = 139 '---- ParameterDirectionEnum Values ---- Const adParamUnknown = &H0000 Const adParamInput = &H0001 Const adParamOutput = &H0002 Const adParamInputOutput = &H0003 Const adParamReturnValue = &H0004 '---- CommandTypeEnum Values ---- Const adCmdUnknown = &H0008 Const adCmdText = &H0001 Const adCmdTable = &H0002 Const adCmdStoredProc = &H0004 Const adCmdFile = &H0100 Const adCmdTableDirect = &H0200 If InStr(CStr(Request.ServerVariables("QUERY_STRING")), 1) > 0 Then %>

<% End If %>

<% ' See if we have the list in memory, if not, create it. Dim objCommand, rstDefault, cnnSQL, strList Set cnnSQL = Server.CreateObject("ADODB.Connection") cnnSQL.Open "WWW3_ORDERS","WWW3_ORDERS","&9a4ju#i8se!" Set objCommand = Server.CreateObject("ADODB.Command") Set rstDefault = Server.CreateObject("ADODB.RecordSet") strList = "" objCommand.ActiveConnection = cnnSQL objCommand.CommandType = adCmdStoredProc objCommand.CommandTimeout = 120 objCommand.CommandText = "wwwTop1000GetBooks" 'objCommand.Parameters.Append _ ' objCommand.CreateParameter("@intID", adInteger, adParamInput, 4, Session("intOrder")) rstDefault.Open objCommand, , adOpenStatic, adLockReadOnly dim intcount intcount = 0 Do While Not rstDefault.EOF if Request(cstr(rstDefault("intID"))) = "1" Then intcount = intcount + 1 if Not IsNull(rstDefault("strAuthor")) Then Response.write "
| " & rstDefault("strTitle") & ", by " & rstDefault("strAuthor") & "
" & vbcrlf else Response.write "
| " & rstDefault("strTitle") & "
" & vbcrlf End if End If rstDefault.MoveNext Loop If intCount = 0 Then %>
No favorites were selected. Please click the back button on your browser and select a few.

<% Else %>

<% End if rstDefault.Close cnnSQL.Close %>