[Last Call] Learn how to a build a cloud-first strategyRegister Now

x
?
Solved

whats are equivalent functions of sybase replace ,to_number of oracle

Posted on 2001-07-10
5
Medium Priority
?
3,239 Views
Last Modified: 2010-08-05
whats are the equivalent functions in sybase for replace and to_number in oracle..,

Sridhar.
0
Comment
Question by:sriven3
4 Comments
 
LVL 3

Accepted Solution

by:
mathavra earned 400 total points
ID: 6270319
You can use convert function for to_number as below:

select convert(int, "12345")


You may be able to use "stuff" function for replace:


It Returns the string formed by deleting a specified number of characters from one string and replacing them with another string.

Syntax
stuff(char_expr1, start, length, char_expr2)

Arguments
char_expr1 - is a character-type column name, variable, or constant expression of char, varchar, nchar or nvarchar type.

start - specifies the character position at which to begin deleting characters.

length - specifies the number of characters to delete.

char_expr2 - is another character-type column name, variable, or constant expression of char, varchar, nchar or nvarchar type.

Examples
select stuff("abc", 2, 3, "xyz")
go
----
axyz

select stuff("abcdef", 2, 3, null)
go
---
aef

select stuff("abcdef", 2, 3, "")
go
----
a ef

0
 
LVL 5

Expert Comment

by:amitpagarwal
ID: 6273039
seen a very similar question earlier .. maybe search in PAQ's
0
 
LVL 6

Expert Comment

by:ChrisKing
ID: 9882571
No comment has been added lately, so it's time to clean up this TA.
I will leave the following recommendation for this question in the Cleanup topic area:

Accept: mathavra

Please leave any comments here within the next seven days.
PLEASE DO NOT ACCEPT THIS COMMENT AS AN ANSWER!

ChrisKing
EE Cleanup Volunteer
0
 

Expert Comment

by:dougsur
ID: 22723533
0

Featured Post

Free Tool: Path Explorer

An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Moore’s Law has proven itself time and time again since it was first introduced. So what’s next? Will Moore’s law continue to remain relevant, or will new technology take over and bring us the next big advancement in computing?
Exchange administrators are always vigilant about Exchange crashes and disasters that are possible any time. It is quite essential to identify the symptoms of a possible Exchange issue and be prepared with a proper recovery plan. There are multiple…
Is your OST file inaccessible, Need to transfer OST file from one computer to another? Want to convert OST file to PST? If the answer to any of the above question is yes, then look no further. With the help of Stellar OST to PST Converter, you can e…
As many of you are aware about Scanpst.exe utility which is owned by Microsoft itself to repair inaccessible or damaged PST files, but the question is do you really think Scanpst.exe is capable to repair all sorts of PST related corruption issues?
Suggested Courses
Course of the Month18 days, 1 hour left to enroll

831 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question