Welcome Guest! Log in
×

Notice

The forum is in read only mode.
Due to some maintenance operations, stambia.org will be switched to read-only mode during the 13th November. It will be possible to read and download, but impossible to post on the forums or create new accounts. For any question please contact the support team.

Topic-icon Question Using variable in email from SqlOperation

More
18 Feb 2016 18:00 #1 by letancel
letancel created the topic: Using variable in email from SqlOperation
Hi,

I'd like to send by email, a list of results from a SQL query (select clause).

Here's how I'm trying to do that :
1. SqlOperation : "select clause" with a SqlOperation to get a list of results (type_demande is the column selected)
2. Scripting : store these results in a rhino variable (direct Bing from SqlOperation to Scripting)
3. SendMail : send by email the results

In the scripting operation, I do: %e(rhino){var typeDem = ":{type_demande}:";}e(rhino)%
But I get this error : com.indy.engine.common.exceptions.EngineExceptionI: com.indy.engine.common.exceptions.EngineExceptionI: com.indy.engine.common.exceptions.EngineExceptionI: Unknown Exception for ' var typeDem = ":{type_demande}:";'

I am doing something wrong?
And is it the good way to do it?

Thx
More
19 Feb 2016 11:31 #2 by Thomas BLETON
Thomas BLETON replied the topic: Using variable in email from SqlOperation
Maybe this article can help : www.stambia.org/doc/82-process/actions/i...elect-query-by-email
The approach is different from yours, but maybe it will suit you ?
More
22 Feb 2016 16:04 #3 by letancel
letancel replied the topic: Using variable in email from SqlOperation
Hi,

Looks good, I am gonna try it and give you a feedback shortly.

Thanks