It's better not to but the same data "shipped" in two different tables. Given that you have a relationship between "E" and "Shipping", any time you are working with either table, the status field in E can be used to show the status.
What is the relationship between E and Shipping?
Is there only one related record in Shipping for each record in E or are there multiple records in Shipping for a given record in E?
I use a order number to build relationship between E and Shipping, and this is the only relationship they have. One order number often reflect more than one record. There could be several models under the same order number.
Actually, "Shipped" is the only value overlap between Status in E and Shipping. For E, I have status like "Pending" and "Shipped", while in Shipping I have "Shipped", "Dock" and "Closed". May be I can not use status in E to replace status of Shipping.
You have this?
E----<Shipping (---< means "one to many")
E::OrderID = Shipping::OrderID
There could be several models under the same order number
In which table? E? Shipping? or a third table not yet identified here?
This script could create one new record in Shipping with that status field set to "shipped", but I'm not sure that it will do what you want here...
Set Variable [$OrderID ; E::OrderID]
Go to Layout [Shipping]
Set Field [Shipping::OrderID ; $OrderID]
Set field [Shipping::Status ; "Shipped"]
Go to Layout [original layout]
I have Shipping----<E through Order number
Since you have multiple records in Shipped, some might have a status of "shipped" and others might not.
What happens then? (seems like the "shipped" status should only be in the shipping table--not table E.
If you have "Allow creation of records via this relationship" enabled for this relationship, the following script would avoid creating duplicate records in Shipping:
#Perform this from a layout based on E
Set Field [Shipping::Status ; "Shipped"]
That will create a new related record if one does not exist, it will update the status to "Shipped" if it does exist.
May be I misunderstood the one to many symbel. I mean in Shipping table, I select one order number, and portal will draw all models under the same order number.
Actually shipping table is an extend from table E. After Status of specified model changed to "Shipped", it will enter the records in Shipping table.
I want to allow all records with "Shipped" status in E table create records in table Shipping.
Both in E and Shipping table, exist dozens of records with "Shipped" status or other status.
You did not misunderstand. You have a one (shipping) to many (table E) relationship.
Let me try that question again.
Say you have these records in Table E:
OrderID Model Status
2 A Shipped
2 B Pending
2 C Pending
Now you want to create a record for OrderID = 2 in Shipping with "shipped" as it's status. But not all records in E have that status. What happens then?
If all records in E for a given order should always have the same status, then this status field should not be present in Table E--it should be in either shipping or a Parent table of E where you have just one record for each order.
If you mean what happens in table Shipping, it will have new record of shipping, and I will add information like container number to the record. For table E, everything remains the same.
For a given order number, records can have different status.
Thank you so much for your patience and clear advice for my questions!
I just got a small problem, when I set conditional format in layout, I choose value "less than or eaqul to" -10, then the text color should be white. But somehow the conditional format can not recognize -10, when I have a value like -28, it still has a black text color.
How can I "vanish" all numbers less than or eaqual to -10?
Is the field a text or number field? Looks like it might be a text field instead of number.
I just double checked, it's a number field
It works in my tests in Windows XP.
This isn't being viewed in a web browser in instant web publishing? (conditional formatting won't work with IWP) ?
It viewed in normal Win7 OS...
It's really wierd....
I'm using windows XP and tested this in both FM11 and 12.
II've even tried putting a space between the - and 1 in -10 and it still works.
I'd check the rest of your conditional format settings.
Is this the only format expression or are there others?
Exactly what options did you specify for when the value is less than -10?