View previous topic :: View next topic
|
Author |
Message |
winchaat
New User
Joined: 23 Mar 2005 Posts: 14
|
|
|
|
input dataset:
> CLMk Regnum Payment xval
> 1 ab 0 5
> 1 a 23 5
> 1 abc 23 5
> 1 aa 23 5
> 2 as 0 6
> 2 sds 0 6
> 2 sds 12 6
> 2 sd 122 6
>
>
>
> Guys, I need to popluate the xval value only the first
> payment(non zero) in each clmk...
>
>
> CLMK Is Character...
>
>
> here is the expected output.
>
>
>
> CLMk Regnum Payment xval
> 1 ab 0 0
> 1 a 23 5
> 1 abc 23 0
> 1 aa 23 0
> 2 as 0 0
> 2 sds 0 0
> 2 sds 12 6
> 2 sd 122 0
>
>
>
> Could you please give some code for me?
> >
>
> ------->RAG |
|
Back to top |
|
|
muffirulz
New User
Joined: 14 Sep 2005 Posts: 74 Location: Atlanta, (USA)
|
|
|
|
hi winchaat,
i am not able to understand your question. Please could you elaborate it.
thanks.
regards |
|
Back to top |
|
|
winchaat
New User
Joined: 23 Mar 2005 Posts: 14
|
|
|
|
all,
pls refer attached text file.
----->RAG |
|
Back to top |
|
|
winchaat
New User
Joined: 23 Mar 2005 Posts: 14
|
|
|
|
pls save the above file and open |
|
Back to top |
|
|
priyesh.agrawal
Senior Member
Joined: 28 Mar 2005 Posts: 1448 Location: Chicago, IL
|
|
|
|
winchaat,
I tried hard to understand your requirement...Do you mean below...?
There can be more than one row for CLMK field. And you want to update each row GROUP BY CLMK & SET XVAL=0.
If this is what you were looking for then why in your expected output second row contains XVAL=5.
Regards,
Priyesh. |
|
Back to top |
|
|
|