Skip to main content
simply more productive

The Data Specialist

Thanks to our intuitive transformation designer, you can convert data effortlessly to a variety of formats without knowing how to program. It’s not only efficient, it’s also easy to use.
Flowheater Download

Update using lookup field

More
13 years 5 months ago #2067 by Francis
Update using lookup field was created by Francis
Hi M. Robert !

I'm getting another problem these days with mysql table as writer set to 'Update Data' only.

My problem is that I need to update all records related to the lookup field found ! It only update the first one as unfortunatly

It is a Part -> Items relation. I create items first, so then system don't create parts that has no items ( The lookup fail, so its ok! ). After I need to put information related to these items(Their part information) that are in another DB. But My lookup only update 1 record :S

I tried secondly using Group out Heater. Create part rows first, then do a Count(ID) lookup on my field to create as many rows as items related to part. The problem is that I must parse an excel to know this row number to create ( It is the column 1 named ID ).

So by now I did an ugly update .net script that grabs all fields that I need to update Items.
Then if the filter is good : AdapteWrite.Exec .. ( Update tblParts Set field 1 =... Field 2 =... field 3 =, field 4.. where pieceid = MYLOOKUPED_ID ! ).

Is there any other ways doing this ??.

Please Log in to join the conversation.

More
13 years 5 months ago #2068 by FlowHeater-Team
Replied by FlowHeater-Team on topic Re:Update using lookup field
Hi Francis,

I don't know what you mean :unsure: Could you post example data, please?

Only your last case let me know what you want. If this runs you can switch the primary key information only to the "pieceid" field. FlowHeater generates then the SQL WHERE update statements like you in the .NET Script Heater .

Go on the MySQL Adapter configurator for the WRITE side and click on the "Fields / Data types" tab. Here you can switch the primary key fields. Click on the field and enable/disable the primary key checkbox.

NOTE: This doesn’t change the primary key on the database table. By these fields FlowHeater just generates the SQL WHERE statement for updates.

Warning: If you change the primary key information by yourself FlowHeater can update more than one record per each row.

Best wishes
Robert Stark

Did this answer your question? We would be grateful if you provide a brief comment as feedback. It may also help others who may have encountered a similar problem.

Please Log in to join the conversation.

Time to create page: 0.289 seconds

FlowHeater - The Data Specialist

Efficient data integration and transformation with FlowHeater – the perfect solution for a seamless transfer of your data.

Rechtliches

Support & Contact

Kontaktinformation

Telefon:0951 / 99339792 E-Mail:This email address is being protected from spambots. You need JavaScript enabled to view it.

Copyright © 2009-2024 by FlowHeater GmbH. All rights reserved.