Jump to content

Recommended Posts

Posted

Nenu system mundu Lenu phone lo rough ga type chesa.. Will do late night PST.. 
^[\s\S]+$ selects all the text from beginning to end.. Aa question mark greedy ani daani tarvatha unnadi encounter avagaane aagipothadi.. Prasthuthaniki inthe good luck  :) .//

 

 

^[\s\S]+$ is selecting everything

 

ah question mark daggarey edho mistake undhi bhaiya...  ok ok No prob.. i will wait for ur reply

  • Replies 43
  • Created
  • Last Reply

Top Posters In This Topic

  • tejak123

    15

  • ChampakDas

    7

  • puli_keka

    6

  • mukunda1

    4

Top Posters In This Topic

Posted

dheeniki regular expression endhuku .... all u need to remove all words after  ",;"  anthy kadhaaa ....use string tokenizer man

 

package test;
 
import java.util.StringTokenizer;
 
public class TestClass {
 
public static void main(String[] args) {
 
StringTokenizer  stringTokenizer= new StringTokenizer(";w;y;i,;result_set;l", ",") ;
 
 
String results = stringTokenizer.nextToken();
System.out.println(results);
 
}
 
}
 

 

 

saturday night job gurinchi question enti anodhu bhaiya.. eddho job kosam poraaduthunna.

 

i need a regex to get following output

 

input:
 
;x;y;z
;w;y;i,;result_set;l
;w;b;e
;a;e;i,;result_set;4
 
 
output
 
;x;y;z
;w;y;i
;w;b;e
;a;e;i

 

regex should be like We have to select anything that comes  before    ,;result_set   when ,;result_set   occurs zero or more times... 

 

Posted

Udf raayakunda cheyyali bhayya.. i deal with big data.. they want to do in simpler way which can be done through regex... 

Posted

logical way to approach...is

get the occurence of the word Result set..

then replace it with blank..

Posted

logical way to approach...is

get the occurence of the word Result set..

then replace it with blank....// 

 

ya but.. i i dont want data after result_set and data after result_set is not consistent .. my manager said it is simple regex...

Posted
thammudu .... gidhee last programm ... inka emina antee thagindhi dhigi poyelaa undi ....
 
package test;
 
import java.util.regex.Pattern;
 
public class TestClass {
 
public static void main(String[] args) {
 
String input = ";a;e;i,;result_set;4";
 
Pattern pattern = Pattern.compile("(,;)");
String[] stringRegEx  = pattern.split(input);
 
for (String string2 : stringRegEx) {
 
System.out.println(string2);
      }
 
String result = stringRegEx[0];
 
}
 
}
 

 

logical way to approach...is

get the occurence of the word Result set..

then replace it with blank....// 

 

ya but.. i i dont want data after result_set and data after result_set is not consistent .. my manager said it is simple regex...

 

 

Posted

dheeniki regular expression endhuku .... all u need to remove all words after  ",;"  anthy kadhaaa ....use string tokenizer man

 

package test;
 
import java.util.StringTokenizer;
 
public class TestClass {
 
public static void main(String[] args) {
 
StringTokenizer  stringTokenizer= new StringTokenizer(";w;y;i,;result_set;l", ",") ;
 
 
String results = stringTokenizer.nextToken();
System.out.println(results);
 
}
 
}
.//
 
 
thanks for your time annay... i will try for regex till monday morning,, naa valla kaakapothey ee program theesukellli ah bombai gaadi mokham meedha kodatha
Posted

pina regex programm kuda icha chudu 

 

Pattern pattern = Pattern.compile("(,; )");

 

a red color code  regex pattern match chesthundi .....

 

String[] stringRegEx  = pattern.split(input); -- results isthindi .. indhulo ;w;y;i  first string lo ki vosthundi  

 

 

dheeniki regular expression endhuku .... all u need to remove all words after  ",;"  anthy kadhaaa ....use string tokenizer man

 

package test;
 
import java.util.StringTokenizer;
 
public class TestClass {
 
public static void main(String[] args) {
 
StringTokenizer  stringTokenizer= new StringTokenizer(";w;y;i,;result_set;l", ",") ;
 
 
String results = stringTokenizer.nextToken();
System.out.println(results);
 
}
 
}
.//
 
 
thanks for your time annay... i will try for regex till monday morning,, naa valla kaakapothey ee program theesukellli ah bombai gaadi mokham meedha kodatha

 

 

Posted

moodu peg lu pad ak antha maska maska

 

TS edi use chey i  ^.*(?=(\result_set))

arey ninne raa pilstunnadu...help chey...nuvve HELP antey inkaa...T.gif

 

×
×
  • Create New...