Skip to main content
Question

Inlinequerier UPDATE statement not returning any data?

  • December 17, 2015
  • 8 replies
  • 92 views

Forum|alt.badge.img

Hello,

I have found out that UPDATE statement used in inlinequerier does not return any data even though translation runs successfully. I need to update one column of my table with data from another table and there are more conditions in the update statement, otherwise I would have just overwritten the column using feature merger.

When I try to do the update, and add another statement I get an error "Unable to execute multiple statements at a time" (guess this is SQLite limitation)

If I try to select this updated data in another output port (after this update port) it is not updated as it should be.

Any idea how to make this work?

Thanks,

Radek

This post is closed to further activity.
It may be an old question, an answered question, an implemented idea, or a notification-only post.
Please check post dates before relying on any information in a question or answer.
For follow-up or related questions, please post a new question or idea.
If there is a genuine update to be made, please contact us and request that the post is reopened.

8 replies

david_r
Celebrity
  • December 17, 2015

How about using the SQLExecutor? It's pretty powerful.

You can even generate the SQL statement in your workspace before passing it on to the SQLExecutor.


Forum|alt.badge.img
  • Author
  • December 17, 2015

How about using the SQLExecutor? It's pretty powerful.

You can even generate the SQL statement in your workspace before passing it on to the SQLExecutor.

I would have used it, but the data I am accessing is read only and even if it was, I would like to update the data only locally on my computer.


takashi
Celebrity
  • December 17, 2015

I think that the InlineQuerier was designed only for querying data with SELECT statement. Here is a similar discuss: Update a table using InlineQuerier

Consider using other transformers to modify the features.


mark2atsafe
Safer
Forum|alt.badge.img+59
  • Safer
  • December 17, 2015

No the InlineQuerier doesn't work on Update commands. I will mention that the FeatureMerger does allow multiple join 'statements', so you could do the equivalent of "where a.attribute1=b.attribute1 and a.attribute2=b.attribute2 and etc". Use the "+" button at the foot of the dialog to add more clauses.


erik_jan
Contributor
Forum|alt.badge.img+26
  • Contributor
  • December 17, 2015

Have you tried using the DatabaseUpdater?

In FME 2016 the FeatureWriter transformer hopefully has the possibility to write to a database using the UPDATE parameter or even the fme_db_operation attribute to do just this.


david_r
Celebrity
  • December 17, 2015

Have you tried using the DatabaseUpdater?

In FME 2016 the FeatureWriter transformer hopefully has the possibility to write to a database using the UPDATE parameter or even the fme_db_operation attribute to do just this.

I'm not sure how the DatabaseUpdater would work when the SQLExecutor apparently wouldn't in his scenario, though.


erik_jan
Contributor
Forum|alt.badge.img+26
  • Contributor
  • December 17, 2015

I'm not sure how the DatabaseUpdater would work when the SQLExecutor apparently wouldn't in his scenario, though.

If it is because of the data being Read only, no scenario would update the data. That is the purpose of Read only data.


david_r
Celebrity
  • December 17, 2015

If it is because of the data being Read only, no scenario would update the data. That is the purpose of Read only data.

I understand the concept of read only data, but I'm not sure I understand what you mean :-)