"Tirelle" <(E-Mail Removed)> wrote in message
<79862CE9-A760-4FE7-AE15-(E-Mail Removed)>:
> Tried all below... No success. Yes this is Jet data. Anymore
> suggestions?
>
> "RoyVidar" wrote:
>
>> "Tirelle" <(E-Mail Removed)> wrote in message
>> <663EC7A9-F3BA-4D39-8BE4-(E-Mail Removed)>:
>>> I am trying to create a recordset based on a query. Each time i
>>> run code, I get the following error:
>>> -2147217900:Invalid SQL statement,expected
>>> 'DELETE','INSERT','PROCEDURE','SELECT',or 'UPDATE'.
>>>
>>> Here is the statement... rst.Open "qryCalculateAmpHrs",
>>> CurrentProject.Connection, adOpenDynamic, adLockOptimistic,
>>> accmdtexT How do I resolve this?
>>
>> Try changing adCmdText to adCmdStoredProc
>>
>> BTW, if this is Jet data, I doubt you will get dynamic. Better go
>> for keyset or static (it will be coerced to keyset anyway, I think,
>> if it is based on Jet data).
>>
>> --
>> Roy-Vidar
>>
>>
>>
Describe "No success", in terms of (errornunmber), errormessage and
current code please (toss in the SQL too?).
--
Roy-Vidar
|