473,386 Members | 1,702 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,386 software developers and data experts.

result coming twice , no conversion

2
Hi,
I have tried to convert upper to lower and lower to upper in single string it's coming but not with same.

select upper(substr('maN',0,3))||lower(substr('maN',3)) from dual;
Result:

UPPER(
------
MANn

but it should come like 'MAn'
Feb 1 '14 #1

✓ answered by Rabbit

If you're trying to flip the cases, then you can't do it with just upper and lower. You'll need to create a function to loop through each character.

3 1112
Rabbit
12,516 Expert Mod 8TB
That's because your first substring is returning 3 characters.
Feb 1 '14 #2
Mans
2
Rabbit, i am trying to get my result like convert upper to lower and lower to upper in same string
example : select 'AbcDEfgH' from dual;
and i am expecting result as
output: aBCdeFGh
all lower convert to upper and upper convert to lower.
Feb 2 '14 #3
Rabbit
12,516 Expert Mod 8TB
If you're trying to flip the cases, then you can't do it with just upper and lower. You'll need to create a function to loop through each character.
Feb 2 '14 #4

Sign in to post your reply or Sign up for a free account.

Similar topics

3
by: Alexander Stippler | last post by:
Given the following code snippet we get some unexpected behaviour: //-------------------------------------------------------------------- #include <iostream> using namespace std; struct A {...
0
by: Newbillian | last post by:
After converting Access 97 databases to 2003, databases that worked perfectly now malfunction. In particular there seems to be some type of subform bug where data is not saved to the main form when...
16
by: TTroy | last post by:
Hello, I'm relatively new to C and have gone through more than 4 books on it. None mentioned anything about integral promotion, arithmetic conversion, value preserving and unsigned preserving. ...
14
by: junky_fellow | last post by:
Can anybody please explain this: When a value with integer type is converted to another integer type other than _Bool, if the new type is unsigned, the value is converted by repeatedly...
22
by: junky_fellow | last post by:
Consider a function: void *test_func(void) { return ((void *)-1); } While returning, the integer -1 is converted to void *. Is this portable ?
4
by: Vikram | last post by:
i am using following code in button click... of asp.net code behind page Response.Clear() 'clears the current output content from the buffer Response.AppendHeader("Content-Disposition", _ ...
11
by: jyck91 | last post by:
// Base Conversion // Aim: This program is to convert an inputted number // from base M into base N. Display the converted // number in base N. #include <stdio.h> #include <stdlib.h>...
2
by: Ciaran | last post by:
Hi is there a way of duplicating the same mysql_query resource result or is there a way to stop it from being cleared once it is no longer needed? I need to run a ......
6
by: Peter Lee | last post by:
what's the correct behaver about the following code ? ( C++ standard ) I got a very strange result.... class MyClass { public: MyClass(const char* p) { printf("ctor p=%s\n", p);
9
by: =?Utf-8?B?RmxhdmVsbGUgQmFsbGVt?= | last post by:
Apparently the Java Conversion tool that used to be in Visual Studio 2005 is no longer supported in Visual Studio 2008. Anyone have any suggestions on how to convert a Java program to C# in Visual...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.