johnkrytus
Registered User.
- Local time
- Today, 14:08
- Joined
- Mar 7, 2013
- Messages
- 91
We just converted our database from postgres to SQL Server. This error appears to be all over our code.
I am only a novice level coder and the guy who often helps me just left on vacation. Any help would be appreciated greatly.
Apparently it dislikes this line of code:
Which is called from here:
You must use the dbSeeChanges option with OpenRecordset when accessing a sql serverI am only a novice level coder and the guy who often helps me just left on vacation. Any help would be appreciated greatly.
Apparently it dislikes this line of code:
Code:
Public Sub clearFilterForBucket(bucket_name As String, filter_id As Integer)
CurrentDb.Execute ("delete from filter_actions where filter_id= " & filter_id & " AND action= '" & bucket_name & "'")
End Sub
Which is called from here:
Code:
Private Sub b_send_Click()
Dim title_id As Integer
Dim rstFilters As DAO.Recordset
Dim rstPeople As DAO.Recordset
Dim filterQry As String
Dim answer As String
Dim newFilter As DAO.Recordset
Dim ctrl_bucket_name As String
Dim maxSize As Integer
maxSize = 100 '--how many records we can add to a filter at once
If IsNull(ctrl_company_id) Then
MsgBox ("You did not select a company")
ElseIf IsNull(ctrl_company_titles) Then
MsgBox ("You did not select a Title")
ElseIf IsNull(ctrl_filtername) Then
MsgBox ("You did not select a filter")
Else
Set rstPeople = [Forms]![Search_Filter_People]![filter_people_results].[Form].Recordset
If rstPeople.RecordCount > maxSize Then
MsgBox ("You are trying to add more than " & maxSize & " records to a filter. Please use a smaller data set")
Else
Call clearFilterForBucket("added", Forms.Search_Filter_People.Form.ctrl_filtername.Value)
Call addPeopleToFilter(rstPeople, Forms.Search_Filter_People.Form.ctrl_filtername.Value)
Me.filter_people_results.SourceObject = "filter_people_results"
ctrl_bucket_name = "added"
Me.filter_people_results.Form.RecordSource = "select (FirstName + ' ' + LastName) as fullname, * from people where EmployeeID IN ( select person_id from filter_actions where filter_id =" & ctrl_filtername & " and action='" & ctrl_bucket_name & "') order by LastCnct desc"
Me.filter_people_results.Form.Requery
update_bucketcounts
End If
End If
End Sub