Problem with append query for attachment fei

ahmadrezaahmad

Registered User.
Local time
Today, 14:49
Joined
Jun 25, 2013
Messages
30
Hello
I have 1 "main" access file and "Portable".
in the form of main I creat buttom to open and apped the table of other access file-portable.accdb- to the main table!
I have a problem, it is that when I add field content of attachment to the main table I can not use "Append" buttom !
attach:
1-befor adding attachmend field=ok!
2-after adding attachment field=ERRROR!!!!
I upload my file in this link and in this froum:
http://ul.to/0c4auu84

Please help me!
Thank you
 

Attachments

Your zipped is a rar filetype, can't open it.
 
soryy
in 1st file I rename the .rar to .zip and in this file this is realy .zip file
thanks for attention!
 

Attachments

Hello
I have 1 "main" access file and "Portable".
in the form of main I creat buttom to open and apped the table of other access file-portable.accdb- to the main table!
Hmm - I see none table in both databases.
 
If you comment out the error handing then you'll see the problem.
You've to rewrite the query below, where you omit the "IN" clause.
strSql = "DELETE * FROM asli " & _
" WHERE to IN(SELECT to FROM asli IN '" & strPath & "');"
attachment.php
 

Attachments

  • Error.jpg
    Error.jpg
    21 KB · Views: 1,925
I knew my problem from multi-valued field;I want the way to solve this problem!!!
this is a answer to my problem :
http://blogs.office.com/b/microsoft...-the-new-attachment-field-in-access-2007.aspx
but my problem is appending from one db to another db!
for example in my file ,main db is (main.accdb) and other persons fill forms in other db (portable.acccdb),I want to append forms that recieved from persons in many file as (portable.accdb) to one main file=main.accdb!
for this sitution what your idea???(
thanks!
 
I knew my problem from multi-valued field;I want the way to solve this problem!!!
[FONT=&quot]
Ok - for me it sounded like you didn't know the problem.
When I open your database and click the Append button the 1. problem appearers with the delete query and the IN clause, because it referred to an other database. This issue can you overcome by linking the table to the Main database by code.
2. problem - you can't add records containing a multi-value field by an INSERT INTO query.
One way to do it, is to use a Recordset, like I've done it in the attached database.

[/FONT]
 

Attachments

Users who are viewing this thread

Back
Top Bottom