matching pattern over multiple lines



Hi ,
I have a java program which has many SQL statements in it. I want to
write a script to extract all the lines that start with "select" , then
keep matching subsequent lines till I find a ";"

something like :
"Select a "+
"FROM b" +
"Where c=d";


Best
Sandeep

.



Relevant Pages

  • Re: sort files by exif date
    ... >> and the filenames in a list, sort, then extract the filenames again. ... >> Probably a few lines of shell script. ... That string will be a line of text. ...
    (comp.unix.questions)
  • Re: HTML - Extract Specific Text
    ... etc.) that can be used in any calculation. ... imported text is standardised you can easily extract whatever you want. ... a VBA script. ... and then takes the 11 characters starting with the fourth ...
    (comp.databases.filemaker)
  • Strange IO Error when extracting zips to a network location
    ... I've written a script to run on windows to extract all zips under a given directory path to another directory path as such: ... python extractzips.py ... The purpose of this script is to retrieve backup files which are individually zipped under a backup directory tree on a backup server. ... When I extract the same tree to my local drive it works fine without error. ...
    (comp.lang.python)
  • Re: Strange IO Error when extracting zips to a network location
    ... given directory path to another directory path as such: ... python extractzips.py <put all extracted ... The purpose of this script is to retrieve backup files which are ... When I extract the same tree to my local ...
    (comp.lang.python)
  • Re: Fast extraction of fraction part from float.
    ... > I need to extract the fraction part from floats for a script I ... It would really help us if you told us what floating point format ...
    (alt.lang.asm)