Results 1 to 3 of 3
  1. #1
    TheChairman is offline Novice
    Windows 7 64bit Access 2007
    Join Date
    Dec 2011
    Posts
    16

    Union query with attachment file type in Access 2007

    Hi everyone, I have two tables - tblEmployees and tblContacts. Both tables collect slightly different data, but they also have a number of similar fields, among which are fields for employee and contact photographs. These are of the attachment data type. I was attempting to generate a report that would display, among other things, the photos of all employees and contacts matching a certain criteria. So I created a union query.



    Everything was working great until I selected the attachment files and got an error. I understand that attachment data types don't work with union queries (sure wish someone had told me that BEFORE I had generated all the queries and reports). According to some of the stuff I read online, I was recommended to use OLE. Note that the files are JPEGs, which complicates matters since OLE only takes bitmaps. I need to do the following:

    1.) Replace the attachmentImage field in my tblEmployees and tblContacts tables;

    2.) Alter my data entry forms, frmEmployees and frmContacts, to allow the user to attach or reference a JPEG file

    3.) Generate a report based on my union query that will show the employee and contact pictures.

    Any help would be most appreciated! Thank you!

  2. #2
    hertfordkc is offline 18 year novice
    Windows XP Access 2007
    Join Date
    Mar 2011
    Posts
    481
    From your post, it seems that you could select a subset of records from the attached tables and create temporary tables on which to work the union query???

  3. #3
    TheChairman is offline Novice
    Windows 7 64bit Access 2007
    Join Date
    Dec 2011
    Posts
    16
    Thanks. I decided to just compromise by having two separate reports: one for employees and one for contacts.

Please reply to this thread with any new information or opinions.

Similar Threads

  1. Extract file attachment from email to Access
    By bet in forum Import/Export Data
    Replies: 3
    Last Post: 02-02-2011, 07:35 PM
  2. Attachment help in sub-form in Access 2007
    By turnertj in forum Forms
    Replies: 1
    Last Post: 06-28-2010, 01:40 PM
  3. Access 2007 Attachment and Listbox controls
    By anqoksan in forum Forms
    Replies: 0
    Last Post: 05-15-2010, 11:35 PM
  4. Replies: 0
    Last Post: 05-14-2010, 07:28 AM
  5. Access 2007 Code Guru please: Unbound Attachment
    By MatthewFF in forum Programming
    Replies: 2
    Last Post: 02-01-2010, 07:31 AM

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums