|
[x]
The Solution Rating System
|
|
|
With so many solutions, how can you tell which solutions are most likely to help you and which ones are not? To provide you with a tool to use, we rate our solutions based on various elements that most accurately determine if a solution is a quality solution. To explain what factors affect the solution rating, here are the elements we take into consideration when formulating our solution rating. - The Grade of the Solution
- The Zone Rank of the Expert Providing the Solution
- The Number of Author and Expert Comments
- The Number of Experts Contributing
- The Feedback of the Community
Your Input Matters Because of the way the system is set up, the most important variable in this equation is you. As a member of Experts Exchange, you are able to cast your vote on the quality of the solutions in regard to how complete, accurate, helpful and easy to understand each solution is. When you provide your feedback, each rating is adjusted accordingly. So, if you see a solution that has a poor rating that you think is a good solution, let us know by rating it. As you do, the rating will be adjusted and will become more accurate for other members of our site. If you have any suggestions that you would like to make for our rating system, please ask a question in the Suggestions Zone of Community Support. Thank you! |
|
|
|
|
I currently have code that opens and updates Oracle tables. Need to modify to update a single field for Comments into the Oracle table. I am use to DAO What is the proper syntax to set the recordset to a sql string. See '<<<<<<<<<<<<<<<
Due to grouping issue and Jet engine errors I need to update this field after running the first set of sql.
Dim sConn As String
Dim oConn As ADODB.Connection
Dim lCnt As Long
Dim sSql, strSQL As String
Dim rstOra As ADODB.Recordset
Dim rsAccess As New ADODB.Recordset, rs As New ADODB.Recordset
Dim fld As ADODB.Field
On Error GoTo ErrorHandler
DoCmd.SetWarnings False
sConn = _
"Driver={Microsoft ODBC for Oracle};Server=(DESCRIPTION=(ADDRESS_LIST=(ADDRESS=(PROTOCOL=TCP)" _........
strSQL = "SELECT " & _
" MEASNO, FTEMNOMENCLATURE, NOMENCLATUREMODEL, " & _
" EquipID As EQUIPMENT_ID, MULTIPLE_ID, JOB_GROUP, " & _
" PROJECT, PRIORITY, COMPLETEBYDATE AS COMPLETE_BY_DATE, " & _
" RequestorId As REQUESTOR_ID, " & _
" CALIBRATION, REPAIR, MODIFICATION, ACCEPTANCE, EVALUATION, " & _
" MAINTENANCE, SUPPORT, CMIS_LAB, SERVICE_LAB, WORK_CODE, " & _
" CHARGE_NUMBER, DISPOSITION, INPUT_RANGE_MIN, " & _
" INPUT_RANGE_MAX, INPUT_UNITS, OUTPUT_RANGE_MIN, OUTPUT_RANGE_MAX, " & _
" OUTPUT_UNITS, GAIN, CUTOFF_FREQ, INPUT_FREQ, REF_FREQ, REF_VOLTAGE, " & _
" EXCIT_VOLTAGE, EXCIT_ENABLED, FTIR_ACCURACY, OFFSET, OFFSET_ENABLED, " & _
" REQ_EMO1, REQ_EMO2, REQ_EMO3, REQ_EMO4, REQ_EMO5, REQ_EMO6, " & _
" SPARECODE, CALIBRATION_ID " & _
"FROM QS_SRUpdatetoCMISdrt " & _
"WHERE job_group ='" & spar & "'"
Set rsAccess.ActiveConnection = CurrentProject.Connection
rsAccess.CursorType = adOpenStatic
rsAccess.Open strSQL
If rsAccess.EOF = False Then
Set oConn = New ADODB.Connection
oConn.Open sConn
Set rstOra = New ADODB.Recordset
rstOra.ActiveConnection = oConn
rstOra.CursorType = adOpenKeyset
rstOra.LockType = adLockOptimistic
rstOra.CursorLocation = adUseServer 'default
rstOra.Open "CMIS.UDV_RFS_SR"
Do While rsAccess.EOF = False
rstOra.AddNew
On Error Resume Next
For Each fld In rsAccess.Fields
rstOra(fld.Name).Value = fld.Value
Next
rstOra.Update
rsAccess.MoveNext
Loop
End If
strSQL = "Select REQUESTORCOMMENTS from Ta_SR WHERE job_group = '" & spar & "'"
Debug.Print strSQL
Set rs = CurrentDb.OpenRecordset(strSQL)'<<<<<<<<<<<<<<<<<<<<<
strSQL = "UPDATE CMIS.UDV_RFS_SR SET REQUESTORCOMMENTS = rs!REQUESTORCOMMENTS.value WHERE job_group = '" & spar & "'"
oConn.Execute strSQL, lCnt