How to convert negative values into positive
Moderators: chulett, rschirm, roy
How to convert negative values into positive
Hi Experts,
i have few negative values and positive values in few columns, i need to convert them into positive.
i.e
-75555123 this need to be 75555123
555124 should be 555124
is there any function. i was tried with Abs() but i didn't get any conversions.
Thanks
Vemisr
i have few negative values and positive values in few columns, i need to convert them into positive.
i.e
-75555123 this need to be 75555123
555124 should be 555124
is there any function. i was tried with Abs() but i didn't get any conversions.
Thanks
Vemisr
-
- Participant
- Posts: 14
- Joined: Wed Nov 11, 2009 4:52 am
- Location: New York
-
- Participant
- Posts: 3337
- Joined: Mon Jan 17, 2005 4:49 am
- Location: United Kingdom
Or write one yourself as
Code: Select all
If yourField < 0 Then yourField * (-1) Else yourField
or use field function to convert all negative sign to positve and then load into targetSainath.Srinivasan wrote:Or write one yourself as...Code: Select all
If yourField < 0 Then yourField * (-1) Else yourField
Mayura
-
- Participant
- Posts: 3337
- Joined: Mon Jan 17, 2005 4:49 am
- Location: United Kingdom
Don't take me wrong...what does a field function go to do here ?mayura wrote:or use field function to convert all negative sign to positve and then load into targetSainath.Srinivasan wrote:Or write one yourself as...Code: Select all
If yourField < 0 Then yourField * (-1) Else yourField
-
- Premium Member
- Posts: 892
- Joined: Thu Oct 16, 2003 5:18 am
Also known as an invalid solution unless they can explain it.
Never mind the fact that the simple and proper solution has already been posted, there's no need for some kind of an 'Alternate Solution Contest' here and no prize for the goofiest... sorry.
Never mind the fact that the simple and proper solution has already been posted, there's no need for some kind of an 'Alternate Solution Contest' here and no prize for the goofiest... sorry.
-craig
"You can never have too many knives" -- Logan Nine Fingers
"You can never have too many knives" -- Logan Nine Fingers
Some people are slowly changing the DSXchange to a "knowledge(?) expo" from a "knowledge base" with their over-excitement. In a recent post, I asked a very simple question and got only 2 solutions and around 10 other useless comments. Please think neotically before throwing some garbage.
It doesn't even help anybody's learning process also. Just shows the false-ego, earned with a little knowledge.
We have technology's best people here. So let us show some respect to them with sensible environment.
I know my comments are a bit rude. Sorry for that.
It doesn't even help anybody's learning process also. Just shows the false-ego, earned with a little knowledge.
We have technology's best people here. So let us show some respect to them with sensible environment.
I know my comments are a bit rude. Sorry for that.
-
- Participant
- Posts: 54607
- Joined: Wed Oct 23, 2002 10:52 pm
- Location: Sydney, Australia
- Contact: