How to export attachments?

I have a question how to export attachments. We have a few distant ones
departments that use smart data. And they need photos in addition to tables.
I found 2 options for exporting attachments: 1) through queries 2) through reports.

  1. When exporting attachments to the query menu, photos are exported without information. Photo titles are not related with incidents. If the name contained, for example, the ID of the incident, then everything would be fine. (It is not clear what is in this photo and where it was taken).
  2. When I try to export a photo through reports I encountered the problem of what table is being created does not contain information - most columns are simply empty. Although the same table that uses the source the query contains all the data.
    I use smart 7.4
    Please share your experience of how to export attachments. I will be grateful.




Hi Volodimir,

You’re correct that the query export is just the image without the associated data. You do in fact need to use the report.

There’s some information on this in the Advanced Reporting Handbook.

The data you’re looking for should be available in the output columns. Can you double check that the output columns in fact contain the desired observations (i.e. they were input when the image was taken)? Could it be that for this observation these categories were not populated?

Cheers,

Alex

[quote=“Alex_Wyatt, post:2, topic:855, full:true”]
Hi Volodimir,

You’re correct that the query export is just the image without the associated data. You do in fact need to use the report.

There’s some information on this in the Advanced Reporting Handbook.

The data you’re looking for should be available in the output columns. Can you double check that the output columns in fact contain the desired observations (i.e. they were input when the image was taken)? Could it be that for this observation these categories were not populated?

Cheers,
Thanks for the answer.
I have now created a new report. Added two data sources to it. One called a request, the other a photo. Both of them are based on the request “Kevlev Raid 00006”. The only difference is that I created one through Data set type: query, and the other through Data set type: attachment. As a result, the first table contains data, but the second table does not. Only the date and several other system columns (coordinates, etc.) work in the second table. Am I doing something wrong or is it a smart problem? Could there be a problem with Data set type: attachment? Do you have all this working correctly?
I am attaching screenshots that illustrate my actions.









Result:


Hi Volodimir,

Ah, I see. Yes, you want to use the “SMART Query Attachments” as your data set type.

This, should, though allow you to see a table which includes the observations (whatever you select for your output columns) as well as the images (see example from my demo database below).

Thanks a lot for the screenshots. It looks like you’re doing everything correctly, so there’s no issue there.

Would it be possible to upgrade to SMART 7.5.3 to see if the issue is present in the more recent update?

Cheers,

Alex

I would like to upgrade to 7.5.3. Please send me the link by which I can download the new version of smart.
P.S.
All the speakers you have on your screen also work for me. Observation category 0, 1. Others that are deeper in the data model do not work. For example, the type of animal, the number of animals observed, a comment on the observation, and so on. And all of this works in Data set type: query.

Hi Volodimir,

Yes, sorry, it appears attribute data are not displaying which is not resolved in 7.5.3, so there’s no use in upgrading to get around this issue.

Thank you for bringing this to our attention. We’ll work to resolve this ASAP.

Cheers,

Alex

P.s. you can access 7.5.3 here for now while awaiting an updated version.

Thanks for the answer

Hi.
I installed smart 7.5.6 but this problem is not removed. Did the developers get smart information about this bug? It is critical for us that it works. We will be very grateful for the solution.

Hi Volodimir,

Apologies, but we don’t currently have a solution for this issue in the latest build of SMART. We’re aware of the need here and will continue to review the possibility of including this.

Cheers,

Alex

Hi there. Thanks for the answer. I look forward to solving this problem.
I found a possible workaround for this problem by joining the tables. To implement this, I created two resources from the same request. Only one for attachments another for text data. Next, I tried to connect them using a left join. It was possible to get a photo and text in one table. But unfortunately, so far I have not achieved compliance. If it was possible to specify 2 fields by which the table is connected, then it would work. This field is the patrol identifier and patrol point identifier. These two fields could be used to combine these tables. Sorry for my bad English.
Perhaps this method can be configured faster. Can anyone tell me how to use left join to extract attachments?
Is there any way to correct the SQL request directly? If not, then perhaps it would be possible to consider creating such a possibility in new versions of the program.
Screenshot_6

Found a way.
I created a new field in both tables that consists of the values of the patrol identifier and the waypoint identifier. Next, I connected these two tables by the newly created fields. Now my attachments appeared in the table in the right place.

@Volodimir glad you were able to come to a solution. For the benefit of the forum, would you be willing to post a video of the correct solution/workflow? Or maybe a PDF of sequential screenshots? I’m sure that others would benefit from this! Thanks!

1 Like

I made a short video about how to open an attachment with information in a report.

Next, this report is best (in my opinion) exported to html.
After looking at the source code of the created html, I noticed that it refers to the photos placed in the folder
C:\Users*** \AppData\Local\Temp.
That is, it will work only on our computer. To be able to move it to other computers, you need to make certain changes.

  1. HTML resource files must be copied to the directory we need
    (for example, create a “ZooPhoto” folder, create a “img” folder in it and place it in the “img” folder).
  2. Correct the html so that all links now point to our created folder
    For example, replace all entries:
    C:/Users/*** /AppData/Local/Temp/
    on
    pictures/
    and place it in the “ZooFoto” folder
    Now our HTML can be transferred with its resources to other computers. To do this, it is enough to copy the folder with all the contents where we need.


3 Likes

Hi Volodimir,

Fantastic. Thank you very much for sharing your solution. I hope we can make this simpler going forward but this is very useful.

Kind regards,

Alex

Hi Drew, this is pretty close to the improvement I suggested a while ago that SMART should have a better naming of the pictures. I think this has not been prioritized as “high”. cheers!

Hola, alguien que me ayude con esta consulta de observacion y adjuntos. En la imagen pueden ver que la misma foto se muestra en las otras observaciones. ¿Por qué ocurre ello?
Se ha revisado el patrullaje y solo una observacion cuenta con adjunto (foto)

Quedo atenta a sus repsuestas.

@Zeveyda Have you reviewed the above thread? The solution is likely above… Based on your question - is the issue here that the photo is only associated with one of the observations, so it shouldn’t be present in each line/associated with all the other observations?

Without knowing the specifics of your query/report structure, I’d suggest working back from the beginning: 1) making sure the query is asking the right question; 2) making sure the correct data (query) has been added to the report; 3) making sure the correct query is used in the table; 4) making sure the correct query attachments have been included, etc. Getting the right images to appear is often just a matter of patience and making sure all the correct steps in the process have been followed correctly. Again, suggest reviewing the thread above and then working through the process again, step by step. Keep us posted.

Hello. I think your problem is how you linked the two tables.
If you select only one field to connect, the program will connect a very large number of records that are not actually connected. Because they were all made in one patrol. To prevent this from happening, connect two tables by several fields.
I usually make a field by which I connect several as shown in the screenshot