The transition to NetApp MS Azure AD B2C is complete. If you missed the pre-registration, you will be invited to register at next log in.
Please note that access to your NetApp data may take up to 1 hour.
To learn more, read the FAQ and watch the video.
Need assistance? Complete this form and select “Registration Issue” as the Feedback Category.

Active IQ Unified Manager Discussions

WFA : Getting an Output of a SQL Query in a Mail

raj_shrivastava11

Hi Guys,

 

I am trying to write a Workflow to get a list of all "offline" volume in a filer.

 

I have written a below SQL Query which will give me a list of volumes which are "offline" or have an gaurantee as "volume"

 

Now i m trying to get this complete output in a mail but unable to get it done. I have created a filter also but unable to proceed further.

 

Kindly help

 

BR

Raj

 

SELECT
volume.name,
volume.state,
volume.volume_guarantee
FROM
storage.volume,
storage.array
WHERE
(
storage.array.name = '${array}'
OR storage.array.ip = '${array}'
)
AND volume.array_id = array.id
AND (
volume.state not like "online"
OR volume.volume_guarantee = 'volume'
)

1 ACCEPTED SOLUTION

coreywanless

WFA isn't necessarily the platform for this type of work. I have actually built my own dashboard that performs the queries against the WFA database.  I have built it with apache and php.

 

Anyways, onto your question. You can do this from WFA.  You will just need to build a custom command to do that for you.  Instead of doing it within the User Inputs section, you can use a custom command to run the powershell command "invoke-mysqlquery".  Then you can format that however you want, and use the 'send-mailmessage' command to send an email with the data.

View solution in original post

2 REPLIES 2

coreywanless

WFA isn't necessarily the platform for this type of work. I have actually built my own dashboard that performs the queries against the WFA database.  I have built it with apache and php.

 

Anyways, onto your question. You can do this from WFA.  You will just need to build a custom command to do that for you.  Instead of doing it within the User Inputs section, you can use a custom command to run the powershell command "invoke-mysqlquery".  Then you can format that however you want, and use the 'send-mailmessage' command to send an email with the data.

View solution in original post

Thanks

Announcements
NetApp on Discord Image

We're on Discord, are you?

Live Chat, Watch Parties, and More!

Explore Banner

Meet Explore, NetApp’s digital sales platform

Engage digitally throughout the sales process, from product discovery to configuration, and handle all your post-purchase needs.

NetApp Insights to Action
I2A Banner
Public