Hi!
I am trying to attach some attribute information to my dgn elements. Elements with the same info should be connected to the same row in database. Is it the simplest way?:
Say, DB connection (ODBC to MS SQL Server 2008) set and empty my_table with my_attribute column created.
And the following algoritm is:
- work with Linkage Mode = Duplicate, and Define Active Entity Graphically or with key-in FI=SELECT * FROM my_table WHERE my_attribute = XX
- if we have some new my_attribute value (key in FI=SELECT * FROM my_table WHERE my_attribute = XX returnes SELECT statement returned no rows), than switch temporary Linkage Mode to New, key-in AE=INSERT INTO my_table (my_attribute,MSLINK) VALUES (XX,1), Attach Active Entity and switch Likage Mode back to Duplicate.
Isn’t there some easier way to do it? May be using Visual SQL Query Builder?
If I forgotten to set Linkage Mode back to Duplicate, and worked for a while with New, making copy-rows with the same my_attribute, is there any way to fix it? I mean delete from my_table rows ("copies") with the same my_attribute value, leaving only one, and link corresponding dgn-elements to this row.
Regards,
Sergei Fadeev
P.S. WinXP, Microstation 08.11.07.177, MS SQL Server 2008