Sunday, 8 September 2013

Is there any way to change word to another word depends on the condition inside the word?

Is there any way to change word to another word depends on the condition
inside the word?

I want to change my word to another word, depends on the conditions. What
is the best way to do it.
Original word-with MINUS value
CREATE SEQUENCE "MY_TEST_SEQUENCE" MINVALUE 8 MAXVALUE 999 INCREMENT BY 1
START WITH 11 CACHE 20 NOORDER NOCYCLE
Result-1
CREATE SEQUENCE "MY_TEST_SEQUENCE" MINVALUE 8 MAXVALUE 999 INCREMENT BY 1
START WITH 8 CACHE 20 NOORDER NOCYCLE
original word-with PLUS value
CREATE SEQUENCE "MY_TEST_SEQUENCE" MINVALUE 8 MAXVALUE 999 INCREMENT BY 1
START WITH 11 CACHE 20 NOORDER NOCYCLE
result-2
CREATE SEQUENCE "MY_TEST_SEQUENCE" MINVALUE -8 MAXVALUE 999 INCREMENT BY 1
START WITH 999 CACHE 20 NOORDER NOCYCLE
Conditions: In above example has two result and two original words...
Conditions are;
if MINVALUE has plus value (8) than make start with value same as MINVALUE
(8)...
if MINVALUE has minus (-8) value than make start with value same as
MAXVALUE (999) MINVALUE...

No comments:

Post a Comment