Re: UPDATE QUERY PLEASE HELP!



I explained the problem with the Update SQL in the orginal thread: you are
doing a Boolean-value comparison on the Field [Attachments] and then
assigning a Text value to the SAME Field. The Field [Attachments] canNOT be
of Boolean type and Text type. Thus, the database engine will give you an
error every time.

In the Select SQL, the IIf expression is a Calculated Value only (not being
forced back to the Table Field) so its type is not important.

--
HTH
Van T. Dinh
MVP (Access)



"troy" <troy@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote in message
news:5535D4DE-DED6-42FE-80B2-63E3F4EED779@xxxxxxxxxxxxxxxx
Thank you very much for your time and effort. For some reason it still
will
not work. I took your SQL and just tried to add on filed with the
expression
and I received the same error. It is a simple expression that works time
and
time again.
Attachments: IIf(dbo_tblProductversion.Attachments=-1,"Y","N"), but for
some
reason it will not allow me to continue adding the table where this
expression came from. Only in the update query. Do you believe this?
Thanks
agai for all your time. I will mess with it somemore. It is something I
hae
to get done. Take care



.



Relevant Pages

  • Re: Strip inbox details and populate db
    ... Easy enough to do using ADO code. ... them to the file system and then opening the files using something like ... tests it would be very similar, just a different connection to the SQL ... > outlooks inbox as well as any attachments. ...
    (microsoft.public.outlook.program_vba)
  • Re: Why wont this work in a update query
    ... If [Attachments] is a Text Field, the first argument of the IIf is incorrect ... Either way (Text or Boolean Field), you will have errorwith the Update ... SQL due to data type mismatch! ... filed not a Y/N datatype ...
    (microsoft.public.access.queries)
  • Multiple tables refer to one -To use foreign keys or not?
    ... As one of my first encounters with SQL, ... To be able to relate each object to its eventual attachments, ... colleague felt that too many fields would remain empty with the first ... against it when the rest of the design does not. ...
    (comp.databases.theory)
  • Re: Oracle update command and timestamp - how to get it back?
    ... Toward the bottom of the article they have an example of an UPDATE sql ... I tried typing this in the query builder but ... Another dead end - the "Refresh the DataSet" option is ...
    (microsoft.public.dotnet.framework.adonet)
  • Get attachments during an asynch OnSave event
    ... Information about it is placed into a SQL db ... The code is attached to an asynch onSave event. ... I can see if there are attachments by checking oRecord.Fields[ ... ADODB.Record oRecord = pNewEventInfo.EventRecord; ...
    (microsoft.public.exchange.development)

Quantcast