Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
Please i have a question
i have this table
| Date | New Date | Field1 | Field2 |
|---|---|---|---|
| 2/1/2010 | ? | 1 | A |
| 3/1/2010 | ? | 1 | B |
| 4/1/2010 | ? | 1 | A |
| 5/1/2010 | ? | 2 | B |
| 6/1/2010 | ? | 2 | A |
| 7/1/2010 | ? | 1 | B |
i want an expression for the field New Date based on
if Field2 has a repeated value and the corresponding values in Field1 are equal
like the case 1,A and 1,A
so i want the New Date face these 2 records to be the minimum date of both
this is the final result i want
| Date | New Date | Field1 | Field2 |
|---|---|---|---|
| 2/1/2010 | 2/1/2010 | 1 | A |
| 3/1/2010 | 3/1/2010 | 1 | B |
| 4/1/2010 | 2/1/2010 | 1 | A |
| 5/1/2010 | 5/1/2010 | 2 | B |
| 6/1/2010 | 6/1/2010 | 2 | A |
| 7/1/2010 | 3/1/2010 | 1 | B |
Thanks in Advance
hei attach is an example
hei attach is an example
Thanks so much for your help ![]()
but what if i want this case
| Date | New Date | Field1 | Field2 |
|---|---|---|---|
| 2/1/2010 | ? | 1 | A |
| 3/1/2010 | ? | 1 | B |
| 4/1/2010 | ? | 1 | Ax |
| 5/1/2010 | ? | 2 | B |
| 6/1/2010 | ? | 2 | A |
| 7/1/2010 | ? | 1 | By |
and i want to compare A after removing x from it with A in the other record and if they are equal to apply the last situation,the same also for B after removing y from it to compare it with B
i.e the final result will also be
| Date | New Date | Field1 | Field2 |
|---|---|---|---|
| 2/1/2010 | 2/1/2010 | 1 | A |
| 3/1/2010 | 3/1/2010 | 1 | B |
| 4/1/2010 | 2/1/2010 | 1 | Ax |
| 5/1/2010 | 5/1/2010 | 2 | B |
| 6/1/2010 | 6/1/2010 | 2 | A |
| 7/1/2010 | 3/1/2010 | 1 | By |
then i would recomend you to go and create a new field in the load script
that will be something like
left(Field2,1) as Field3
then use Field 3 in the expression
Thanks so much for your help ![]()