Skip to main content
Announcements
Introducing Qlik Answers: A plug-and-play, Generative AI powered RAG solution. READ ALL ABOUT IT!
cancel
Showing results for 
Search instead for 
Did you mean: 
Safus
Creator
Creator

How does Data binding works on TKC

Hi all,

I just wanted to know how data-binding works in TKC ?

I am just imagining this scenario :

I have a Query (a textArea Field) with a @DefaultValue("SELECT * FROM Table LIMIT 10"),

like this :

@Option

@TextArea

@Required

@DefaultValue

("\"SELECT * FROM Table LIMIT 10\"")

@Documentation("TODO fill the documentation for this parameter")

private String sqlQuery;

 

Can the component's rendering be refreshed dynamically with a click on "guessSchema" Button for example?

So guessSchema in my service will have two functionalities :

 

1-Retrieve Schema (It's Done and at this point, no problem and @DiscoverSchema works fine.)

 

2-Update the "private String sqlQuery" 's value and refresh component rendering. Is it even possible ? Or is it possible to create a new button similarly to "Guess Query" that generates the query according to the detected schema ?

 

Regards,

Safus

Labels (3)
2 Replies
undx
Creator
Creator

Hi @safouane BEN MANSOUR​ ,

For updating an object in your form configuration, you may use the `Update` action (https://talend.github.io/component-runtime/main/1.31.0/ref-actions.html#_update).

You have a working example available here: https://talend.github.io/component-runtime/main/1.31.0/gallery.html

 

Best regards

 

--

Emmanuel

Safus
Creator
Creator
Author

Thank you very much for your help.

 

I managed to create the updatable config.

 

Best Regards,

Safus