select record from table then attach to email as an attachment by email script
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-02-2024 03:15 AM
Step 1, suppose there is a table: [sc_req_item] which stores a lot of data
Step 2, now select the required data (including value from variables, value from multiple variables set) through javascript in [email script]
Step 3, store the data in [Step 2] in the array [recordArray]
Step 4. Is there a way to send the data in [recordArray] as an attachment via email?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-02-2024 06:08 AM
First: As what kind of record?
Second: Why through email script? Why not create an attachment linked to sc_task and include it in the email?
Third: Is your question just step 4 or are 1, 2 and 3 already done?
Fourth: Why? What is the use case that you need to send an attachment with data in an unknown format (see 'first')?
Please mark any helpful or correct solutions as such. That helps others find their solutions.
Mark
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-02-2024 09:34 PM
Thank you for your reply first Mark,
======================================================
Here is my requirement: The data is stored in the table one by one. I want to set up a schedule job to send the data regularly through email. The attachment of the email contains the data I selected from the table.
1, the record are some normal GlideRecord in table [sc_req_item], e.g. with Field "Number", "Submit Date", "..." and Variables (variables.sys_id1, variables.sys_id2, ...) and Multi-Row Variable Set
2, “create an attachment linked to sc_task”, is that the solution ? i don't get it(this is the question: how to put the data into an attachment)
3, my question is just "Step 4"(send the data[select from table] as an attachment via email)
4, why use email script, because it's more flexible, you can select data in any table you want and format the data then send data via email, the only question is: i don't know how to put this data into an attachment.
======================================================
Before i post this question, i've try this:
Try 1, base on [DocsLink1], you can only export data with the field in the table(like: number, submit date,...) and variables, but can NOT export the Multi-Row Variable Set in that Gliderecord
Try 2, base on [DocsLink2], the same problem, you can only export data with the field in the table(like: number, submit date,...), but can NOT export variables and the Multi-Row Variable Set in that Gliderecord
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-03-2024 05:23 AM
Send a GlideRecord as attachment? What? This really doesn't make sense!
Please mark any helpful or correct solutions as such. That helps others find their solutions.
Mark