This topic is locked

Adding a temporary field

3/6/2009 9:01:38 AM
PHPRunner General questions
K
kplunkert author

I have a situation where the user is picking tires for a car. There are over 5000 unique products.
I am using drop downs to pick the correct product.
For example Goodyear-Aquatred-195/70R15

The user picks Goodyear

The next drop down shows all the Goodyear brands

He pics Aquatred

Then all the next drop down shows the available sizes.
I don't need to store The Brand and line information. Just the product number of the final box.
Is it possible to add fields on a page that are not linked to a database field?
If so how?
KJ Plunkert

J
Jane 3/10/2009

Karl,
you can add aliases on the Edit SQL query tab and then remove it from update query in the Before record added/updated events on theEvents tab.

Here is a sample query:

select field1

field1 as field1_a,

field1 as field1_b,

...

from TableName



Here is a sample event:

unset($values["field1_a"]);

unset($values["field1_b"]);

M
MikeB941 5/26/2009

PHPRUNNER 5.0 BUILD 766
Hi Jane:
I've used this technique in other situations - but tried tonight to use it for nesting dependent dropdown boxes per this example and at least for me, the aliased fields don't show up as category control column (only real columns from the table).
Am I missing something?
Thanks a million for all your help and advice!
Take Care... Mike.

J
Jane 5/26/2009

Mike,
you can select only real fields as Category control.