SQL Server Help   Independent houses near kukatpally | Apartments in Pragathi Nagar | AndhraVaani.com | Log Out | Topics | Search
Register | Edit Profile

Bewarse TalkArchives - 2007Cine Talk - Reviews, Gossips, Insider Info etc.Archive through November 27, 2007SQL Server Help Previous Next

Author Message
Top of pagePrevious messageNext messageBottom of pageLink to this message

Prasanth
Bewarse Legend
Username: Prasanth

Post Number: 27847
Registered: 03-2004
Posted From: 203.200.218.2

Rating:N/A
Votes: 0(Vote!)

Posted on Friday, November 23, 2007 - 7:43 am:Edit PostDelete PostView Post/Check IP


~@~
Top of pagePrevious messageNext messageBottom of pageLink to this message

Maanas
Mudiripoyina Bewarse
Username: Maanas

Post Number: 8752
Registered: 08-2006
Posted From: 203.91.207.30

Rating:N/A
Votes: 0(Vote!)

Posted on Thursday, November 22, 2007 - 12:37 am:Edit PostDelete PostView Post/Check IP


Adavi Naade Veta Naade
Top of pagePrevious messageNext messageBottom of pageLink to this message

Bumperless_toyota
Pilla Bewarse
Username: Bumperless_toyota

Post Number: 185
Registered: 10-2007
Posted From: 85.144.112.59

Rating:N/A
Votes: 0(Vote!)

Posted on Thursday, November 22, 2007 - 12:32 am:Edit PostDelete PostView Post/Check IP

ayooooo neekoo C# telavaaadaa ..
em peKKaali ikkaDa?
Top of pagePrevious messageNext messageBottom of pageLink to this message

Bumperless_toyota
Pilla Bewarse
Username: Bumperless_toyota

Post Number: 183
Registered: 10-2007
Posted From: 85.144.112.59

Rating:N/A
Votes: 0(Vote!)

Posted on Thursday, November 22, 2007 - 12:29 am:Edit PostDelete PostView Post/Check IP

<<alphabets and symbols ni space tho replace cheste, digits madyalo space vastaadi kada >>

try my egg sample .. it aslo replaces spaces and limited characters
em peKKaali ikkaDa?
Top of pagePrevious messageNext messageBottom of pageLink to this message

Maanas
Mudiripoyina Bewarse
Username: Maanas

Post Number: 8751
Registered: 08-2006
Posted From: 203.91.207.30

Rating:N/A
Votes: 0(Vote!)

Posted on Thursday, November 22, 2007 - 12:26 am:Edit PostDelete PostView Post/Check IP

ante C# maaku telvadani kindling sethunnava
Adavi Naade Veta Naade
Top of pagePrevious messageNext messageBottom of pageLink to this message

Bumperless_toyota
Pilla Bewarse
Username: Bumperless_toyota

Post Number: 182
Registered: 10-2007
Posted From: 85.144.112.59

Rating:N/A
Votes: 0(Vote!)

Posted on Thursday, November 22, 2007 - 12:22 am:Edit PostDelete PostView Post/Check IP

<<more importantly SQL SERVER lo regexp's support ledu, oracle lone vundi ee feature anukunta>>

Explicitly its not available, but write a 10 lines code in C# to expose regex
em peKKaali ikkaDa?
Top of pagePrevious messageNext messageBottom of pageLink to this message

Maanas
Mudiripoyina Bewarse
Username: Maanas

Post Number: 8750
Registered: 08-2006
Posted From: 203.91.207.30

Rating:N/A
Votes: 0(Vote!)

Posted on Thursday, November 22, 2007 - 12:05 am:Edit PostDelete PostView Post/Check IP

420 mayya corest
baa seppav, kaani inka chaala vunnay special characters vunnay kada like $,(,),!,~, ila inka vunnayi.

and if the source string is jumbled one in alphanumeric say a1b2c3?d45fg, alphabets and symbols ni space tho replace cheste, digits madyalo space vastaadi kada

more importantly SQL SERVER lo regexp's support ledu, oracle lone vundi ee feature anukunta
Adavi Naade Veta Naade
Top of pagePrevious messageNext messageBottom of pageLink to this message

Aggi_pidugu
Celebrity Bewarse
Username: Aggi_pidugu

Post Number: 18806
Registered: 05-2006
Posted From: 209.208.140.244

Rating:N/A
Votes: 0(Vote!)

Posted on Wednesday, November 21, 2007 - 1:24 pm:Edit PostDelete PostView Post/Check IP


hasta la victoria siempre
Top of pagePrevious messageNext messageBottom of pageLink to this message

420
Yavvanam Kaatesina Bewarse
Username: 420

Post Number: 2970
Registered: 12-2006
Posted From: 85.144.112.59

Rating:N/A
Votes: 0(Vote!)

Posted on Wednesday, November 21, 2007 - 1:18 pm:Edit PostDelete PostView Post/Check IP

example selfdabaa leevoyeee ...
Top of pagePrevious messageNext messageBottom of pageLink to this message

Aggi_pidugu
Celebrity Bewarse
Username: Aggi_pidugu

Post Number: 18799
Registered: 05-2006
Posted From: 209.208.140.244

Rating:N/A
Votes: 0(Vote!)

Posted on Wednesday, November 21, 2007 - 1:15 pm:Edit PostDelete PostView Post/Check IP

'ABDZ-420+mamma is a kaaathi'<<< wats this ??
hasta la victoria siempre
Top of pagePrevious messageNext messageBottom of pageLink to this message

420
Yavvanam Kaatesina Bewarse
Username: 420

Post Number: 2969
Registered: 12-2006
Posted From: 85.144.112.59

Rating:N/A
Votes: 0(Vote!)

Posted on Wednesday, November 21, 2007 - 1:13 pm:Edit PostDelete PostView Post/Check IP

'[-?_*^+ /\#@[:alpha:]]'

this is the pattern u are looking for
Top of pagePrevious messageNext messageBottom of pageLink to this message

420
Yavvanam Kaatesina Bewarse
Username: 420

Post Number: 2968
Registered: 12-2006
Posted From: 85.144.112.59

Rating:N/A
Votes: 0(Vote!)

Posted on Wednesday, November 21, 2007 - 1:10 pm:Edit PostDelete PostView Post/Check IP

well mama you need to use regular expression in Sqlserver .. ask ur admin if u can use regular expression on ur db , if yes then use

'[-?_*^+ [:alpha:]]' this pattern for a return value which is a number
Top of pagePrevious messageNext messageBottom of pageLink to this message

Sam
Yavvanam Kaatesina Bewarse
Username: Sam

Post Number: 3311
Registered: 03-2004
Posted From: 65.114.90.194

Rating:N/A
Votes: 0(Vote!)

Posted on Wednesday, November 21, 2007 - 1:01 pm:Edit PostDelete PostView Post/Check IP

sql server maamaa.... prasthutham memu use chesthunna stmt.

Deenni choosinappudalla naaku vallu mandi pothundhi.. edanna short version possible aa ani try chesthunnaaaa

REPLACE(REPLACE(REPLACE(REPLACE(REPLACE(REPLACE(RE PLACE(REPLACE(REPLACE(REPLACE(REPLACE(REPLACE(REPL ACE(REPLACE(REPLACE(REPLACE(REPLACE(REPLACE(REPLAC E(REPLACE(REPLACE(REPLACE(REPLACE(REPLACE(REPLACE( REPLACE(REPLACE(REPLACE(REPLACE(REPLACE(REPLACE(RE PLACE(REPLACE(REPLACE(LTRIM(RTRIM(UPPER(a.invoicen umber))),'-',''),'/',''),' ',''),'A',''),'B',''),'C',''),'D',''),'E',''),'F', ''),'G',''),'H',''),'I',''),'J',''),'K',''),'L','' ),'M',''),'N',''),'O',''),'P',''),'Q',''),'R',''), 'S',''),'T',''),'U',''),'V',''),'W',''),'X',''),'Y ',''),'Z',''),'#',''),'LOAD',''),'DET',''),'\','') ,'_','') AS InvNbr_formatted
Top of pagePrevious messageNext messageBottom of pageLink to this message

420
Yavvanam Kaatesina Bewarse
Username: 420

Post Number: 2967
Registered: 12-2006
Posted From: 85.144.112.59

Rating:N/A
Votes: 0(Vote!)

Posted on Wednesday, November 21, 2007 - 12:59 pm:Edit PostDelete PostView Post/Check IP

MAANASEEE what say
Top of pagePrevious messageNext messageBottom of pageLink to this message

420
Yavvanam Kaatesina Bewarse
Username: 420

Post Number: 2966
Registered: 12-2006
Posted From: 85.144.112.59

Rating:N/A
Votes: 0(Vote!)

Posted on Wednesday, November 21, 2007 - 12:58 pm:Edit PostDelete PostView Post/Check IP

Sam mama.. if you are using oracle then try this

select REGEXP_REPLACE('ABDZ-420+mamma is a kaaathi','[-?_*^+ [:alpha:]]','') from dual ;

this will replace all special characters ,alphabets and only numbers will comeout as result
Top of pagePrevious messageNext messageBottom of pageLink to this message

Maanas
Mudiripoyina Bewarse
Username: Maanas

Post Number: 8747
Registered: 08-2006
Posted From: 203.91.207.30

Rating:N/A
Votes: 0(Vote!)

Posted on Wednesday, November 21, 2007 - 11:11 am:Edit PostDelete PostView Post/Check IP

select regexp_substr('ABDZ-123456', '[[:digit:]]{6}') from <table name>;

this will only work if length of the numeric substring is known

'6' ni length tho replace chesukovali!!
Adavi Naade Veta Naade
Top of pagePrevious messageNext messageBottom of pageLink to this message

Sam
Yavvanam Kaatesina Bewarse
Username: Sam

Post Number: 3310
Registered: 03-2004
Posted From: 65.114.90.194

Rating:N/A
Votes: 0(Vote!)

Posted on Wednesday, November 21, 2007 - 9:10 am:Edit PostDelete PostView Post/Check IP

I want to replace a-z and special characters in field:

For example:

Actual values in a field is: ABDZ-123456

I want to get it as: 123456

Any simple logic to achieve this?

We are now using Replace for each character.