silesianeu
Programmer
Hi,
I have problem with NULL values in report. There is query taken from stored procedure and I cannot change source. For understand, I put sample data:
COL1 COL2 COL3
1 643 NULL
NULL NULL varchar1
NULL NULL abcdef2
2 5453 NULL
NULL NULL agsdg
NULL NULL 53fwf
NULL NULL thbd4
3 123 NULL
NULL NULL yngtr
4 6744 NULL
NULL NULL mmdgh
I want replace NULLs in 1 and 2 column like that:
COL1 COL2 COL3
1 643 NULL
1 643 varchar1
1 643 abcdef2
2 5453 NULL
2 5453 agsdg
2 5453 53fwf
2 5453 thbd4
3 123 NULL
3 123 yngtr
4 6744 NULL
4 6744 mmdgh
You see that I replaced in cols first and second value in row previous to the next to last with value. I need it for sort for cols1 or 2 or 3 - and I understand that I must replace these NULLs with values.
I tried use one Formula Field:
stringVar x1 := {Command.COL1};
if ({Command.COL1} <> '') then
x1 := {Command.COL1}
else
x1 := Previous({Command.COL1});
x1
But unfortunatelly it replace only first row with value previous row. How can I do that it replace for all rows until to row with next value?
Of course I set Report Options that "Convert Database NULL Values to Default" and "Convert Other NULL Values to Default".
It is possible to achieve this effect? I searched in archive and FAQ but no effect
PS. I'm using CR2008
Best regards
SilesianEu
I have problem with NULL values in report. There is query taken from stored procedure and I cannot change source. For understand, I put sample data:
COL1 COL2 COL3
1 643 NULL
NULL NULL varchar1
NULL NULL abcdef2
2 5453 NULL
NULL NULL agsdg
NULL NULL 53fwf
NULL NULL thbd4
3 123 NULL
NULL NULL yngtr
4 6744 NULL
NULL NULL mmdgh
I want replace NULLs in 1 and 2 column like that:
COL1 COL2 COL3
1 643 NULL
1 643 varchar1
1 643 abcdef2
2 5453 NULL
2 5453 agsdg
2 5453 53fwf
2 5453 thbd4
3 123 NULL
3 123 yngtr
4 6744 NULL
4 6744 mmdgh
You see that I replaced in cols first and second value in row previous to the next to last with value. I need it for sort for cols1 or 2 or 3 - and I understand that I must replace these NULLs with values.
I tried use one Formula Field:
stringVar x1 := {Command.COL1};
if ({Command.COL1} <> '') then
x1 := {Command.COL1}
else
x1 := Previous({Command.COL1});
x1
But unfortunatelly it replace only first row with value previous row. How can I do that it replace for all rows until to row with next value?
Of course I set Report Options that "Convert Database NULL Values to Default" and "Convert Other NULL Values to Default".
It is possible to achieve this effect? I searched in archive and FAQ but no effect
PS. I'm using CR2008
Best regards
SilesianEu