Write a query to count a particular character in a string. e.g Return the number of times 'N' appears in string 'NITININ'. The result shoudl be 3.
Solution:
select length('NITININ') - length(replace('NITININ','N','')) from dual
return code before grep
-
my 2009 solution return code before grep ( ( ( mycmd echo $? >&3 ) |grep
mytext >&4 ) 3>&1 |(read x;exit $x) )4>&1 my 2025 solution mycmd > >(grep
mytext)
1 week ago
No comments:
Post a Comment