Skip to main content
Solved

AttributeManager Text Editor Language?


vxn43
Supporter
Forum|alt.badge.img+18

What language does the text editor in the AttributeManager Transformer use? is it SQL, Python, both, or ?

Best answer by thijsknapen

Hi @timh​ ,

 

I'm not really sure how to answer your question but I suppose none of the above. I believe it's just an internal text editer, where you can enter and/or set plain text to be used as the value for your attributes.

 

To construct the text value using information of your workspace, you can use e.g. Parameter Values, FME Feature Functions, String Functions, Math Functions, etc. Some of these may be based on other Languages (e.g. when you use an Arithmetic Expression, which is based on the @Evaluate() FME Feature Function, you also see Math Operators in the left bar, which I believe are based on TCL). Nevertheless, in general I suppose functions like these are part of the FME language if you would call it as such.

 

But if you truly have statements c.q. query's in some other language, you probably need to use dedicated transformers to execute these. E.g. PythonCaller for Python. SQLExecutor for SQL, XMLXQueryExtractor for XQuery, TCLCaller for TCL, etc.

 

Furthermore, if a text string in the Text Editor would represent a statement c.q. query from some other language such as SQL or Python, you do have the option to change the Syntax highlighting. E.g. see below screenshot;

image

View original
Did this help you find an answer to your question?

3 replies

egge
Contributor
Forum|alt.badge.img+14
  • Contributor
  • January 3, 2023

Nope, neither SQL nor Python...

The Text Editor provides a convenient way to construct text strings (including regular expressions) from various data sources, such as attributes, parameters, and constants, where the result is used directly inside a parameter. There is a set of functions available in the editor, like FME Feature Functions, String Functions, Math Functions and Date/Time Functions.

Can you tell us what you want to accomplish?


vxn43
Supporter
Forum|alt.badge.img+18
  • Author
  • Supporter
  • January 3, 2023

Nothing in particular. You have confirmed what I already thought. I wanted to get a 2nd opinion. Thank you.


thijsknapen
Contributor
Forum|alt.badge.img+10
  • Contributor
  • Best Answer
  • January 3, 2023

Hi @timh​ ,

 

I'm not really sure how to answer your question but I suppose none of the above. I believe it's just an internal text editer, where you can enter and/or set plain text to be used as the value for your attributes.

 

To construct the text value using information of your workspace, you can use e.g. Parameter Values, FME Feature Functions, String Functions, Math Functions, etc. Some of these may be based on other Languages (e.g. when you use an Arithmetic Expression, which is based on the @Evaluate() FME Feature Function, you also see Math Operators in the left bar, which I believe are based on TCL). Nevertheless, in general I suppose functions like these are part of the FME language if you would call it as such.

 

But if you truly have statements c.q. query's in some other language, you probably need to use dedicated transformers to execute these. E.g. PythonCaller for Python. SQLExecutor for SQL, XMLXQueryExtractor for XQuery, TCLCaller for TCL, etc.

 

Furthermore, if a text string in the Text Editor would represent a statement c.q. query from some other language such as SQL or Python, you do have the option to change the Syntax highlighting. E.g. see below screenshot;

image


Reply


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings