IT Community - Software Programming, Web Development and Technical Support

Hiding first number of characters.

This is a discussion on Hiding first number of characters. within the Database Support forums, part of the Web Development category; Hi all, I want to hide the first number of character in a string. For ex, If the string is ...


Go Back   IT Community - Software Programming, Web Development and Technical Support > Web Development > Database Support

Register FAQ Members List Calendar Mark Forums Read
  #1  
Old 09-25-2007, 09:59 PM
S.Vinothkumar S.Vinothkumar is offline
D-Web Genius
 
Join Date: May 2007
Posts: 905
S.Vinothkumar is on a distinguished road
Question Hiding first number of characters.

Hi all,

I want to hide the first number of character in a string.

For ex,

If the string is i_%dvinoth, suppose I want's to get vinoth only from that string,how could from SQL server?
__________________
S.VinothkumaR
Behind me is infinite power,
Before me is Endless Possibility,
Around me is Boundless Opportunity,
Why should I fear!
Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #2  
Old 09-27-2007, 12:08 AM
leoraja8 leoraja8 is offline
D-Web Sr.Programmer
 
Join Date: May 2007
Posts: 190
leoraja8 is on a distinguished road
Wink Re: Hiding first number of characters.

Hey Vino!

Use my coding...

Code:
SELECT REPLACE('i_%dvinoth', LEFT('i_%dvinoth',4),'')
Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #3  
Old 09-27-2007, 12:23 AM
leoraja8 leoraja8 is offline
D-Web Sr.Programmer
 
Join Date: May 2007
Posts: 190
leoraja8 is on a distinguished road
Smile Re: Hiding first number of characters.

Vinoth,

You can use the another way as following,

Code:
SELECT stuff('i_%dvinoth',1,4,'')
Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #4  
Old 09-27-2007, 02:18 AM
Murali Murali is offline
D-Web Master
 
Join Date: Feb 2007
Location: India-Chennai.
Posts: 385
Murali is on a distinguished road
Send a message via AIM to Murali
Default Re: Hiding first number of characters.

Hi,

May be this ... a common one to be used in ORACLE, MYSQL and SQL SERVER.

Code:
SELECT SUBSTR('i_%dvinoth',5);
__________________
-Murali..
Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #5  
Old 09-28-2007, 06:37 AM
S.Vinothkumar S.Vinothkumar is offline
D-Web Genius
 
Join Date: May 2007
Posts: 905
S.Vinothkumar is on a distinguished road
Default Re: Hiding first number of characters.

Hi there,

Thank you all....
__________________
S.VinothkumaR
Behind me is infinite power,
Before me is Endless Possibility,
Around me is Boundless Opportunity,
Why should I fear!
Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Showing n Hiding DIV LAYER through JAVSCRIPT? laksh_khamesra Web Design Help 1 09-09-2008 08:10 PM
Substituting Characters using different databases srikumar_l Database Support 1 12-05-2007 06:33 AM
Substituting Characters using different databases srikumar_l Database Support 1 12-04-2007 12:56 AM
How to Get the Right Characters of a string in sql server? kingmaker Database Support 3 08-01-2007 08:07 AM
What's the easiest way to remove characters from the end of a string in php? oxygen PHP Programming 1 07-26-2007 01:53 AM


All times are GMT -7. The time now is 10:14 AM.


Copyright ©2004 - 2007, DiscussWeb. All Rights Reserved.
Our Partners
One Way Moving Companies | Stamford Dentist | Euro Millions Lottery | Home Loans| Furniture

SEO by vBSEO 3.0.0