reverted to an old version and this is working again
Iโm having issues with a Ref to another table ID getting put in when I add a record to the child table.
I have done this in other tables on the same app and it works, but from Customer to Order itโs leaving the โCustomerIDโ blank everytime I create a new order for a customer.
I know that is vague in way but thatโs the thingโฆ it seems vague.
Second column is set to Ref and in the details I pick the CustomerInfo Table and it picks up that it needs the CustomerID as the ReferencedKeyColumn.
I have it set to readonly and required, but every new order I create just leaves that field blank.
Then when it shows records for that customer it list every record because they all match.
Which they shouldnโt because itโs set to select based on CustomerID matching.
Hmmm
Any ideas?
Do I need to just delete that table and start again?
Just noticed another oddity.
There is no reference of a link FROM Customer Info to Order Info.
I broke itโฆ I renamed that virtual columnโฆ now I just have to figure out how to make it again.
@Kevin_Richard we can always make mistakes as itโs a nature of us. Provided you broke a ref ( others will not bother you that much really ), you can always set it back with checking and if needed editing the REF_ROWS expression in the related tableโs virtual column. The expressionโs structure is very basic:
REF_ROWS(โRefTableNameโ, โRefColumnNameโ)
@Levent_KULACOGLU Yeah, I donโt know what I did, but I couldnโt get it back.
I hadnโt done much work after causing the problem, so it wasnโt too hard to redo it.
Provided you set any column to read-only, it does not record anything to the base sheet
And provided you have the same key column of a table in another table (which is a normal column), AppSheet assumes there is a link/relationship between those 2 tables and creates a REF column automatically.
I just reverted back to before I hacked it up.
So Iโm goodโฆ just had to redo a bit of work.
@Levent_KULACOGLU I did make it Read Only at one point, but then I turned that off.
I also renamed the auto generated virtual column.
One of those broke it.
Thank you for the advice.
@Kevin_Richard what broke it was setting it to a read-only. You can always rename the auto-generated virtual columns for related tables
@Levent_KULACOGLU So I canโt even put it to โread onlyโ and then change it back?
@Kevin_Richard why would you need to assign a read-only to a REF column? itโs against its nature actually
@Levent_KULACOGLU I mean, if I made a mistake like I did.
I thought I was making the right call but then I realized I wasnโtโฆ so I switched it back.
At that point though, itโs just botched for good?
User | Count |
---|---|
40 | |
34 | |
29 | |
23 | |
17 |