/build/static/layout/Breadcrumb_cap_w.png

Update query on CreateFolder table is not working

When I am trying to use update query on CreateFolder table in msi then I am getting runtime exception but it is working fine with other tables.

string value = textBox2.Text.Trim();
MessageBox.Show(value);
database.Execute("Update `CreateFolder` Set `CreateFolder`.`Component_` = '" + value + "'");

0 Comments   [ + ] Show comments

Answers (1)

Answer Summary:
Posted by: ur00361883 9 years ago
Black Belt
0

Top Answer

Not like traditional databases, In MSI file we can't update a primary key with update query.In CreateFolder table, both Directory_ and Component_ are primary keys.

So, the approach I followed now is to read the complete row and delete it and create again with new value of Component_.
 
This website uses cookies. By continuing to use this site and/or clicking the "Accept" button you are providing consent Quest Software and its affiliates do NOT sell the Personal Data you provide to us either when you register on our websites or when you do business with us. For more information about our Privacy Policy and our data protection efforts, please visit GDPR-HQ