I have created a list via a load table objects using “create list with” this seems to work
then I want to pull an entry out of another table and add it to this same list using the “in list … add” block.
The problem I’m having is even though I call “in list add” twice only one item is added fully and the second item is missing one of the fields. let me explain in detail with images.
I create a list from table view "data_table_view " this way.
this creates a list of objects with properties Name, Value, Units
this part works ( I have no idea if this is important but the value column in the table is type number)
now I have two pieces of data for “sample_d” in another table ( this will always return only one row as each sample_id is listed only once in this table )
I wanted to take the two columns from “sample_validation_table” : proximate_validation and utlimate_validation and add them to list validation_obj_list
I did it this way
this will return one object with sample_id = value of "selected_coal_sample " the same value from the data_table_view above without the AND. Thus the only object returned should have properties for each column in the table. Specifically proximate_validation and ultimate_validation. Here is a quick shot of the table
so I am trying to add proximate_validation and ultimate_validation to the list “validation_obj_list” ( I have tried to do this in several different ways so what you’ll see is just the latest attempt. )
so I run the query and store the one record reply in proximate_obj_list (as shown above)
then I use a for loop to assign the object to var “j” then create objects with properties Name, Value, Units and set the Value field to "the value of get property ultimate_validation of j and again to get proximate_validation. like this
I did try this without the loop as a object and just adding the entries but that also failed.
let me show you the results
as you can see, even though I am setting the value for Ultimate, it is blank.
I checked the table and it is not blank IE it does have a value and finally just added a new table with with just a query to the sample_validation_table which shows
there is a value for this property
what is odd is I do get the proximate value added to the table and the Name and Units for ultimate but no value.
so I added a print for the item “j” to make sure a) both properties where there and b) they had a value
and finally in my log which is written just before my to list add statements I see (see messages sent to log in the for loop above)
sample id:W213953
proximate output
proximate >Acceptable<
ultimate >Excellent<
so I know the data is there. I can see from a print statement, I can send it to a log, but I can’t add it to my list. I even tested add to list manually with all text for each of the three properties and you can see that as name “debug” in the screenshot (which did work ).
what am I doing wrong?
H