Search Results

Search: Posts Made By: manasa_vs
3,840
Posted By manasa_vs
thanks its worked :)
thanks its worked :):b:
3,840
Posted By manasa_vs
print only the first occurrence of a pattern
Hi,
I have a file as below

select or create proc
/*comments*/
/*comments*/
/*comments*/
/*comments*/
( variables4 datatypes1,
variables1 datatypes2,
variables2 datatypes3,
variables3...
2,977
Posted By manasa_vs
the file has other lines also other than lines...
the file has other lines also other than lines having only / like
/*+ some text */
/*+ some text */
/* Remove rows from a table of survey results. */
/* Add a survey respondent's name and...
2,977
Posted By manasa_vs
:confused:... its not working.. it is giving...
:confused:...
its not working..
it is giving me all the lines in my file and even lines with /*.
2,977
Posted By manasa_vs
sorry i missed to mention. the statements may...
sorry i missed to mention.
the statements may or may not have spaces in between.
so this dosen't work when statements do not have space before or after /
2,977
Posted By manasa_vs
search for a pattern using grep
Hi
I am facing the below problem.

I have set of lines in which i have to search for only the line which matches with the pattren "/" only.

input:-
/*+ some text */
/*+ some text */
/*...
3,965
Posted By manasa_vs
Yes :D Thanks.
Yes :D
Thanks.
3,965
Posted By manasa_vs
its working...but one more additation
Can we print only the false statements than printing all the other statements and true statements?
3,965
Posted By manasa_vs
it still has problem select some text (select...
it still has problem
select some text
(select some text(select some text)
where some condition)
where condition;-->false;
select cl,c2,c3,c4,fn(),c5-->false;
select c1,c2,c3-->true;

for the...
3,965
Posted By manasa_vs
yes it wil end with ; sorry for confusion,for...
yes it wil end with ;
sorry for confusion,for your case it should say true.
3,965
Posted By manasa_vs
Thanks both the code is working fine.. but...
Thanks both the code is working fine..

but for the statements like below though function call is not there it is showing as false the below cases also shoulf be true.

select some text...
3,965
Posted By manasa_vs
search for a pattern using awk between two words
Hi,
how can we search for a pattren between two words? below are the examples

input
1)select from table_name c1,c2,c3,c4,fn(),fn2(),c5;-->false
2)select from table_name c1,c2,c3,c4;--True...
1,921
Posted By manasa_vs
the above code is not working. but i see it is...
the above code is not working.
but i see it is as expected in you out put can you pleas ehelp me?

below is the output from my file
insert into table_name values(1,2,3) --> false
insert into...
6,954
Posted By manasa_vs
It works!!
Thanks :)
it worked.
i changes your code to
awk '{for(i=1;i<NF;i++){if(tolower($i)~/^function$/){print $(i+1)}}}' testsql
to make the search case insensitive

How to use code tags...
6,954
Posted By manasa_vs
How ti Grep for a word and print the next word
Hi
can we grep for a word and print the next word of the greped word?

ex:- create or replace function function_name
create function function_name

we should search for word "function"...
2,760
Posted By manasa_vs
Hi, I have the sql file of 250 to 300 lines in...
Hi,
I have the sql file of 250 to 300 lines in that some 10 or 20 statements wil ve select/update or delete. so i don't want to show the rest of the lines which is not select/update/delete on my...
2,760
Posted By manasa_vs
sorry for the late reply.. i am in a session. i...
sorry for the late reply.. i am in a session. i wil test the code and post the result.

---------- Post updated at 05:43 PM ---------- Previous update was at 04:16 PM ----------

Kamraj,
the...
2,760
Posted By manasa_vs
jay The input content vary from one text file...
jay
The input content vary from one text file to other text file.
but the seniors remains same as i have explained in the first post.

out of complete text file, which may contain function or...
2,760
Posted By manasa_vs
Thanks raj and jay. It is working now. but...
Thanks raj and jay.
It is working now.
but this is not the desired result. please let me know if you want more examples of input and output

the script is checking each and every line and...
2,760
Posted By manasa_vs
Thanks, jay... i will try out the code and post...
Thanks,
jay... i will try out the code and post the result.

---------- Post updated 01-10-12 at 12:23 PM ---------- Previous update was 01-09-12 at 08:04 PM ----------

Hi jay,
nawk is not...
2,760
Posted By manasa_vs
ksh program
Hi,
I have a text file with multiple sql statements in which I have pick only the below select update and delete statements and do print as given below.
All the select,update,delete statements will...
1,822
Posted By manasa_vs
Thank you... i wil test the code and post the...
Thank you...
i wil test the code and post the result.
1,822
Posted By manasa_vs
Thanks both of you.. insteard of passing the...
Thanks both of you..
insteard of passing the string in a variable/hardcoding. can i use the same for searching in a file for the world procedure and get the previous words?
1,822
Posted By manasa_vs
Hi, I am writing the rest of the program in...
Hi,
I am writing the rest of the program in ksh.
can please interprit the above command in ksh?
1,822
Posted By manasa_vs
Get the previous word from the search pattren
Hi,
How do i find the previous worlds from the searched pattrens?

Input:-

Create or replace procedure some tesx.

search work is procedure(case insencitive).

output:- Create or...
Showing results 1 to 25 of 31

 
All times are GMT -4. The time now is 08:33 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy