<?xml version='1.0' encoding='UTF-8'?><?xml-stylesheet href="http://www.blogger.com/styles/atom.css" type="text/css"?><feed xmlns='http://www.w3.org/2005/Atom' xmlns:openSearch='http://a9.com/-/spec/opensearchrss/1.0/' xmlns:blogger='http://schemas.google.com/blogger/2008' xmlns:georss='http://www.georss.org/georss' xmlns:gd="http://schemas.google.com/g/2005" xmlns:thr='http://purl.org/syndication/thread/1.0'><id>tag:blogger.com,1999:blog-5626494138934609795</id><updated>2026-01-16T00:16:58.675-08:00</updated><category term="Vb script"/><category term="scripting"/><category term="scripting language"/><category term="functions"/><category term="vb functions"/><category term="vb scripting"/><category term="variables"/><category term="variables declaration"/><category term="Visual Basic Scripting"/><category term="branching statements"/><category term="vb script basics"/><category term="visual basic"/><category term="VBScript Reference"/><category term="VBScript operators"/><category term="Switch Case"/><category term="VB Constants"/><category term="DCL in sql"/><category term="DML"/><category term="SQL Commands"/><category term="TCL"/><category term="data manipulation language"/><category term="sql command list"/><category term="sql commands DDL"/><category term="sql commands reference"/><category term="transaction control language"/><category term="VB Script operators"/><category term="data control language"/><category term="data definiton language"/><category term="if else"/><category term="for loop"/><category term="software development life cycle"/><category term="testing"/><category term="Software Testing"/><category term="Testing in sdlc"/><category term="Testing in software development"/><category term="database testing"/><category term="sotware testing"/><category term="BRD"/><category term="Execution phase"/><category term="FRD"/><category term="Fibonacci series"/><category term="Fibonacci series in vb"/><category term="Fibonacci series in vb script"/><category term="QA"/><category term="Requirement Analysis"/><category term="Software process"/><category term="Testing Phase"/><category term="Testing articles"/><category term="UI Designers"/><category term="Usability Features"/><category term="andhra pradesh"/><category term="andhra spider"/><category term="arthemetic operators"/><category term="bugs"/><category term="coding"/><category term="database interview questions"/><category term="database queries"/><category term="db testing"/><category term="extend trail version"/><category term="good test case"/><category term="info on andhra pradesh"/><category term="multiplication through vb script"/><category term="operators in vb script"/><category term="phases"/><category term="phases in sdlc"/><category term="process"/><category term="process followed in software development"/><category term="quality"/><category term="quality standards"/><category term="queries"/><category term="sdlc"/><category term="search"/><category term="search engine"/><category term="software"/><category term="software errors"/><category term="sql"/><category term="sql queries"/><category term="test case"/><category term="testing interview qestions"/><category term="testing methodologies"/><category term="testing methods"/><category term="testing model"/><category term="testing questions"/><category term="trail version"/><category term="waterfall model"/><title type='text'>A Tester&#39;s Blog</title><subtitle type='html'>This is for all those who want to learn and contribute to software Testing</subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://kiranqa.blogspot.com/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5626494138934609795/posts/default?redirect=false'/><link rel='alternate' type='text/html' href='http://kiranqa.blogspot.com/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><link rel='next' type='application/atom+xml' href='http://www.blogger.com/feeds/5626494138934609795/posts/default?start-index=26&amp;max-results=25&amp;redirect=false'/><author><name>Kanikaram Kiranpaul</name><uri>http://www.blogger.com/profile/06778345340371108991</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><generator version='7.00' uri='http://www.blogger.com'>Blogger</generator><openSearch:totalResults>82</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>25</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-5626494138934609795.post-1886656053964593933</id><published>2013-02-26T02:21:00.000-08:00</published><updated>2013-02-26T02:21:09.761-08:00</updated><title type='text'></title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;
&lt;h2 class=&quot;myclass&quot;&gt;
&lt;div style=&quot;text-align: justify;&quot;&gt;
Write a Script to print the phone list in VB Script using Arrays.&lt;/div&gt;
&lt;br /&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;
Here we are using a static array because we are giving the lowerbound and upperbound of the array. Also we are giving the array values. The script in VB looks like this. You can copy the script and paste it in a notepad and save as a .vbs file and execute it. You have to remember that the column and Row count in VB using Arrays start by default with zero and hence for 3 columns we are giving 2 because 0 to 2 makes it 3 columns and like wise for rows.&lt;/div&gt;
&lt;/h2&gt;
&lt;br /&gt;
&lt;h5 style=&quot;color: #660000; font-weight: normal;&quot;&gt;
&lt;span style=&quot;font-size: 100%;&quot;&gt;&#39;Initializing an array with 3 columns and 4 rows&lt;br /&gt;&lt;br /&gt;Dim arrphonelist(2,3)&lt;br /&gt;&lt;br /&gt;&#39;Giving all the values of different columns for the 4 rows.&lt;br /&gt;Arrphonelist(0,0) = &quot;John&quot;&lt;br /&gt;Arrphonelist(1,0) = &quot;Abharam&quot;&lt;br /&gt;Arrphonelist(2,0) = &quot;9854685623&quot;&lt;br /&gt;&lt;br /&gt;Arrphonelist(0,1) = &quot;Mark&quot;&lt;br /&gt;Arrphonelist(1,1) = &quot;Robin&quot;&lt;br /&gt;Arrphonelist(2,1) = &quot;9955662233&quot;&lt;br /&gt;&lt;br /&gt;Arrphonelist(0,2) = &quot;Peter&quot;&lt;br /&gt;Arrphonelist(1,2) = &quot;Marshal&quot;&lt;br /&gt;Arrphonelist(2,2) = &quot;8080454525&quot;&lt;br /&gt;&lt;br /&gt;Arrphonelist(0,3) = &quot;Alex&quot;&lt;br /&gt;Arrphonelist(1,3) = &quot;Blackston&quot;&lt;br /&gt;Arrphonelist(2,3) = &quot;9865653526&quot;&lt;br /&gt;&lt;br /&gt;&#39;Initializing the upperbound of the array for checking the no of rows&lt;br /&gt;&#39;for this we have entered 2 which represents the 2nd dimension&lt;br /&gt;arrubound = ubound(arrphonelist,2)&lt;br /&gt;&lt;br /&gt;For i = 0 to arrubound&lt;br /&gt;&lt;span style=&quot;color: lightgoldenrodyellow;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;str = str&amp;amp;arrphonelist(0,i)&amp;amp;&quot; &quot;&lt;br /&gt;&lt;span style=&quot;color: lightgoldenrodyellow;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;str = str&amp;amp;arrphonelist(1,i)&amp;amp;&quot; &quot;&lt;br /&gt;&lt;span style=&quot;color: lightgoldenrodyellow;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;str = str&amp;amp;arrphonelist(2,i)&amp;amp;vbnewline&lt;br /&gt;Next&lt;br /&gt;&lt;br /&gt;&lt;span style=&quot;color: lightgoldenrodyellow;&quot;&gt;aaa&lt;/span&gt;Msgbox &quot;The Phone List is &quot;&amp;amp;vbnewline&amp;amp;str&lt;/span&gt;&lt;/h5&gt;
&lt;/div&gt;
</content><link rel='replies' type='application/atom+xml' href='http://kiranqa.blogspot.com/feeds/1886656053964593933/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kiranqa.blogspot.com/2013/02/write-script-to-print-phone-list-in-vb.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5626494138934609795/posts/default/1886656053964593933'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5626494138934609795/posts/default/1886656053964593933'/><link rel='alternate' type='text/html' href='http://kiranqa.blogspot.com/2013/02/write-script-to-print-phone-list-in-vb.html' title=''/><author><name>Kanikaram Kiranpaul</name><uri>http://www.blogger.com/profile/06778345340371108991</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5626494138934609795.post-8210750289974532767</id><published>2012-08-01T02:07:00.000-07:00</published><updated>2012-08-01T02:07:39.458-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="arthemetic operators"/><category scheme="http://www.blogger.com/atom/ns#" term="multiplication through vb script"/><category scheme="http://www.blogger.com/atom/ns#" term="operators in vb script"/><category scheme="http://www.blogger.com/atom/ns#" term="VB Script operators"/><title type='text'>Arthemetic Operators in VB Script</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;
Following are the different kind of arthemetic operators used in VB Script coding (+, -, *, /, mod, ^, \). They are used in the script to acheive different results on numeric values.&lt;br /&gt;
&lt;br /&gt;
Instead of hardcoding the values in the script the user can either get the input from the user executing the vb script by using inputbox method or can be driven from an excel sheet.&lt;br /&gt;
&lt;br /&gt;
The input of values is again based on the requirement. It gives flexibility for the user if the values are coming from an external source.&lt;br /&gt;
&lt;br /&gt;
&lt;strong&gt;a) Addition (+)&lt;/strong&gt;&lt;br /&gt;
&lt;br /&gt;
Hard Coded Values in the script.&lt;br /&gt;
&lt;br /&gt;
&lt;h5 style=&quot;color: #660000; font-weight: normal;&quot;&gt;
&lt;div style=&quot;text-align: justify;&quot;&gt;
dim x, y&lt;br /&gt;
X=1&lt;br /&gt;
Y=2&lt;br /&gt;
z=x+y&lt;br /&gt;
msgbox z&lt;/div&gt;
&lt;/h5&gt;
The output would be 3 &lt;br /&gt;
It should be noted that vb scripting is not case sensitive so the script does not throw error if X or x is used in the script.&lt;br /&gt;
&lt;br /&gt;
Input values from the user for the above script.&lt;br /&gt;
&lt;br /&gt;
&lt;h5 style=&quot;color: #660000; font-weight: normal;&quot;&gt;
&lt;div style=&quot;text-align: justify;&quot;&gt;
dim x, y&lt;br /&gt;
X=cint(inputbox(&quot;Enter the First Value: &quot;))&lt;br /&gt;
y=cint(inputbox(&quot;Enter the Second Value to be added with the first value: &quot;))&lt;br /&gt;
z=x+y&lt;br /&gt;
msgbox &quot;The total of first and second value is: &quot;&amp;amp;z&lt;/div&gt;
&lt;/h5&gt;
&lt;strong&gt;b) Subtraction (-)&lt;/strong&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;h5 style=&quot;color: #660000; font-weight: normal;&quot;&gt;
&lt;div style=&quot;text-align: justify;&quot;&gt;
dim x, y&lt;br /&gt;
X=cint(inputbox(&quot;Enter the First Value: &quot;))&lt;br /&gt;
y=cint(inputbox(&quot;Enter the Second Value to be subtracted from the first value: &quot;))&lt;br /&gt;
z=x-y&lt;br /&gt;
msgbox &quot;The final value after subtraction is: &quot;&amp;amp;z&lt;/div&gt;
&lt;/h5&gt;
&lt;strong&gt;c) Multiplication (*)&lt;/strong&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;h5 style=&quot;color: #660000; font-weight: normal;&quot;&gt;
&lt;div style=&quot;text-align: justify;&quot;&gt;
dim x, y&lt;br /&gt;
X=cint(inputbox(&quot;Enter the First Value: &quot;))&lt;br /&gt;
y=cint(inputbox(&quot;Enter the Second Value to be multiplied with the first value: &quot;))&lt;br /&gt;
z=x*y&lt;br /&gt;
msgbox &quot;The final value after multiplication is: &quot;&lt;/div&gt;
&lt;/h5&gt;
More on Arthemetic operators will be posted in the nex blog.&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kiranqa.blogspot.com/feeds/8210750289974532767/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kiranqa.blogspot.com/2012/08/arthemetic-operators-in-vb-script.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5626494138934609795/posts/default/8210750289974532767'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5626494138934609795/posts/default/8210750289974532767'/><link rel='alternate' type='text/html' href='http://kiranqa.blogspot.com/2012/08/arthemetic-operators-in-vb-script.html' title='Arthemetic Operators in VB Script'/><author><name>Kanikaram Kiranpaul</name><uri>http://www.blogger.com/profile/06778345340371108991</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5626494138934609795.post-6705965254990223431</id><published>2012-07-27T01:41:00.003-07:00</published><updated>2012-07-27T01:41:41.124-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="Fibonacci series"/><category scheme="http://www.blogger.com/atom/ns#" term="Fibonacci series in vb"/><category scheme="http://www.blogger.com/atom/ns#" term="Fibonacci series in vb script"/><title type='text'>How to script for Fibonacci Series in VB Script</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;
Below is the VB Script for generating Fibonacci Series.&lt;br /&gt;
&lt;h5 style=&quot;color: #660000; font-weight: normal;&quot;&gt;

&lt;div style=&quot;text-align: justify;&quot;&gt;
Dim i,j&lt;br /&gt;
n=cint(inputbox(&quot;Enter Series Value&quot;))&lt;br /&gt;
j=0&lt;br /&gt;
k=1&lt;br /&gt;
for i=1 to n&lt;br /&gt;
L=J+K&lt;br /&gt;
m=m&amp;amp;L&amp;amp;&quot;, &quot;&lt;br /&gt;
j=k&lt;br /&gt;
k=L&lt;br /&gt;
next&lt;br /&gt;
msgbox m&lt;/div&gt;
&lt;/h5&gt;
&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kiranqa.blogspot.com/feeds/6705965254990223431/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kiranqa.blogspot.com/2012/07/how-to-script-for-fibonacci-series-in.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5626494138934609795/posts/default/6705965254990223431'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5626494138934609795/posts/default/6705965254990223431'/><link rel='alternate' type='text/html' href='http://kiranqa.blogspot.com/2012/07/how-to-script-for-fibonacci-series-in.html' title='How to script for Fibonacci Series in VB Script'/><author><name>Kanikaram Kiranpaul</name><uri>http://www.blogger.com/profile/06778345340371108991</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5626494138934609795.post-8399020811281531990</id><published>2012-07-26T00:26:00.001-07:00</published><updated>2012-07-26T00:26:37.116-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="process"/><category scheme="http://www.blogger.com/atom/ns#" term="process followed in software development"/><category scheme="http://www.blogger.com/atom/ns#" term="software"/><category scheme="http://www.blogger.com/atom/ns#" term="Software process"/><category scheme="http://www.blogger.com/atom/ns#" term="Software Testing"/><title type='text'>Software Process</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;
Based on the experience gained over the past few years in Software Testing have put down some points to be followed to have effective testing. This can be set as a process if there is no defined process.&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;1. Systematic Requirement Analysis.&lt;/b&gt;&lt;br /&gt;
&lt;ul style=&quot;text-align: left;&quot;&gt;
&lt;li&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Prioritize the requirements.&lt;/li&gt;
&lt;li&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; List the function requirements.&lt;/li&gt;
&lt;li&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; List the non-functional requirements.&lt;/li&gt;
&lt;li&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Prepare a requirement traceability metrics.&lt;/li&gt;
&lt;/ul&gt;
&lt;b&gt;2. Use Cases.&lt;/b&gt;&lt;br /&gt;&lt;div style=&quot;text-align: left;&quot;&gt;
&lt;ul&gt;
&lt;li&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Identify the different users.&lt;/li&gt;
&lt;li&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Create a user profile for each category of user, including all the relevant roles the user play.&lt;/li&gt;
&lt;li&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Create a use case for each goal, following the use case template. Maintain the same level of&amp;nbsp; abstraction throughout the use case.&lt;/li&gt;
&lt;li&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Review &amp;amp; validate the use cases. (*Review should be done by someone other than the author* ) &lt;/li&gt;
&lt;/ul&gt;
&lt;b&gt;3. Prototype.&lt;/b&gt;&lt;br /&gt;
&lt;ul style=&quot;text-align: left;&quot;&gt;
&lt;li&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Identify the basic requirements.&lt;/li&gt;
&lt;li&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Develop initial prototype.&lt;/li&gt;
&lt;li&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Review. (Get customer’s feedback)&lt;/li&gt;
&lt;li&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Revise &amp;amp; enhance the prototype. (*Review should be done by someone other than the author* )&lt;/li&gt;
&lt;/ul&gt;
&lt;div style=&quot;text-align: left;&quot;&gt;
&lt;b&gt;4. Test Plan.&lt;/b&gt;&lt;/div&gt;
&lt;ul style=&quot;text-align: left;&quot;&gt;
&lt;li&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; All the testing activities should be mentioned in a test plan.&lt;/li&gt;
&lt;li&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; It should define what is to be tested &amp;amp; what is to be overlooked.&lt;/li&gt;
&lt;li&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; It should contain only the necessary information &amp;amp; nothing more.&lt;/li&gt;
&lt;li&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Use the standard test plan template.&lt;/li&gt;
&lt;li&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Review the test plan.&lt;/li&gt;
&lt;li&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Revise &amp;amp; enhance the test plan. (*Review should be done by someone other than the author*)&amp;nbsp; &lt;/li&gt;
&lt;/ul&gt;
&lt;div style=&quot;text-align: left;&quot;&gt;
* All the reviews should be done formally. The documents of comments or feedback by the reviewer should be maintained always. Revision history chart should also be maintained, so that we can trace the change made.&lt;br /&gt;&lt;br /&gt;&lt;b&gt;5. Test Cases.&lt;/b&gt;&lt;/div&gt;
&lt;ul style=&quot;text-align: left;&quot;&gt;
&lt;li&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Good test cases should expose a maximum numbers of defects.&lt;/li&gt;
&lt;li&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; It should cover all the functionalities of an application.&lt;/li&gt;
&lt;li&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; A tool or a template can be used for time saving.&lt;/li&gt;
&lt;li&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Review the test cases.&lt;/li&gt;
&lt;li&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Revise &amp;amp; enhance the test cases. (*Review should be done by someone other than the author *)&lt;/li&gt;
&lt;/ul&gt;
&lt;div style=&quot;text-align: left;&quot;&gt;
&lt;b&gt;6. Code Review. &lt;/b&gt;&lt;/div&gt;
&lt;ul style=&quot;text-align: left;&quot;&gt;
&lt;li&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Follow the coding standards.&lt;/li&gt;
&lt;li&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Revise &amp;amp; enhance the code developed. (*Review should be done by someone other developer*)&lt;/li&gt;
&lt;/ul&gt;
&lt;div style=&quot;text-align: left;&quot;&gt;
&amp;nbsp;&lt;b&gt;7. Informal Testing.&lt;/b&gt;&lt;/div&gt;
&lt;ul style=&quot;text-align: left;&quot;&gt;
&lt;li&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; There can be an informal round of testing, before the module is released for actual testing.&lt;/li&gt;
&lt;li&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; This testing is also done by testers.&lt;/li&gt;
&lt;li&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; This should be an informal discussion between developers &amp;amp; testers.&lt;/li&gt;
&lt;li&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; This avoids more bugs to occur.&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/li&gt;
&lt;/ul&gt;
&lt;div style=&quot;text-align: left;&quot;&gt;
&lt;b&gt;8. Cycle 1 Testing.&amp;nbsp; &lt;/b&gt;&lt;/div&gt;
&lt;ul style=&quot;text-align: left;&quot;&gt;
&lt;li&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Don’t waste time in testing the wrong things. Test what matters.&lt;/li&gt;
&lt;li&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Perform the dynamic testing in the test server.&lt;/li&gt;
&lt;li&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Communicate the bugs or defects.&lt;/li&gt;
&lt;li&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Try to get most of the bugs fixed in this version only.&lt;/li&gt;
&lt;/ul&gt;
&lt;div style=&quot;text-align: left;&quot;&gt;
&lt;b&gt;9. Cycle 2 Testing.&lt;/b&gt;&lt;/div&gt;
&lt;ul style=&quot;text-align: left;&quot;&gt;
&lt;li&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Spend more time for testing in this phase.&lt;/li&gt;
&lt;li&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Perform the dynamic testing in the online server.&lt;/li&gt;
&lt;li&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Communicate the bugs.&lt;/li&gt;
&lt;li&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Get all the found bugs fixed.&lt;/li&gt;
&lt;li&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Review the process before internal release.&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/li&gt;
&lt;/ul&gt;
&lt;div style=&quot;text-align: left;&quot;&gt;
&lt;b&gt;10. Internal Release.&lt;/b&gt;&lt;/div&gt;
&lt;ul style=&quot;text-align: left;&quot;&gt;
&lt;li&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Internal releases builds up the confidence for quality.&lt;/li&gt;
&lt;li&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Communicate the found bugs &amp;amp; get it fixed immediately.&lt;/li&gt;
&lt;li&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Review the process before UAT.&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/li&gt;
&lt;/ul&gt;
&lt;div style=&quot;text-align: left;&quot;&gt;
&lt;b&gt;11.&amp;nbsp; User Acceptance Testing.&lt;/b&gt;&lt;/div&gt;
&lt;ul style=&quot;text-align: left;&quot;&gt;
&lt;li&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Get the feedback from the client.&lt;/li&gt;
&lt;li&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Communicate the found bugs &amp;amp; get it fixed immediately.&lt;/li&gt;
&lt;li&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Review the process before the release of the application.&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/li&gt;
&lt;/ul&gt;
&lt;div style=&quot;text-align: left;&quot;&gt;
&lt;b&gt;12. Release&lt;/b&gt;.&lt;br /&gt;&lt;br /&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kiranqa.blogspot.com/feeds/8399020811281531990/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kiranqa.blogspot.com/2012/07/software-process.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5626494138934609795/posts/default/8399020811281531990'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5626494138934609795/posts/default/8399020811281531990'/><link rel='alternate' type='text/html' href='http://kiranqa.blogspot.com/2012/07/software-process.html' title='Software Process'/><author><name>Kanikaram Kiranpaul</name><uri>http://www.blogger.com/profile/06778345340371108991</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5626494138934609795.post-5260000090351577266</id><published>2012-07-23T02:14:00.001-07:00</published><updated>2012-07-23T02:17:50.530-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="coding"/><category scheme="http://www.blogger.com/atom/ns#" term="phases"/><category scheme="http://www.blogger.com/atom/ns#" term="phases in sdlc"/><category scheme="http://www.blogger.com/atom/ns#" term="quality"/><category scheme="http://www.blogger.com/atom/ns#" term="quality standards"/><category scheme="http://www.blogger.com/atom/ns#" term="sdlc"/><category scheme="http://www.blogger.com/atom/ns#" term="software development life cycle"/><category scheme="http://www.blogger.com/atom/ns#" term="testing"/><title type='text'>Common Quality Standards in SDLC</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;
&lt;br /&gt;
&lt;div style=&quot;text-align: justify;&quot;&gt;
If Common Quality Standards for an Software application is followed or practiced in the Quality Process then a lot of bugs and cost can be avoided.
&lt;br /&gt;
It has been some time working with a software firm in the Quality Assurance Team and over the period of time could notice that there were some known bugs while delivering the product to the client and one of the reason being communication gap, since we were a small team then could not realize them but when we started growing we had all these problems cropping up.&lt;/div&gt;
&lt;br /&gt;
&lt;div style=&quot;text-align: justify;&quot;&gt;
So we took up the challenge to create a process which involves quality from the beginning of the SDLC which yielded results and would like to share with all of you and this is not a generalized one i.e all the process are dependent on the company so feel fee to change them where ever you want and us it.&lt;/div&gt;
&lt;br /&gt;
&lt;div style=&quot;text-align: justify;&quot;&gt;
We all know that in a Software Development Life Cycle we have different phases and also different models or methodologies being followed like water fall, iterative, Rapid, Agile and V Model to name a few. In any methodology if we do not ensure some method of quality in each phase than we end up creating more bug than which ought to have if any.&lt;/div&gt;
&lt;br /&gt;
&lt;div style=&quot;text-align: justify;&quot;&gt;
Below are the different phases of development and what all should be there in each phase from a QA perspective&lt;/div&gt;
&lt;br /&gt;
&lt;b&gt;Requirements gathering Phase&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;div style=&quot;text-align: justify;&quot;&gt;
During this phase the gathered requirements should be verified to see that they are true and meet the user/client needs.&lt;/div&gt;
&lt;br /&gt;
&lt;div style=&quot;text-align: justify;&quot;&gt;
The requirements captured are to be Complete, Correct, Precise, Unambiguous and clear, Consistent,  Relevant, Testable.&lt;/div&gt;
&lt;br /&gt;
&lt;b&gt; Analysis Phase &lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;div style=&quot;text-align: justify;&quot;&gt;
It is always better at this stage to suggest any changes or add a new feature which will help improve the application (without affecting the estimates and cost of the project). This will help a lot in reducing many of the bug’s the QC/Client’s reports later. To do this, the Team’s should be well knowledgeable in the project and requires thorough analysis of the project.&lt;/div&gt;
&lt;br /&gt;
&lt;b&gt;Design Phase&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;div style=&quot;text-align: justify;&quot;&gt;
During this phase the design/prototype should be verified to see that the design achieves the objectives of the requirements as well as the design being effective and efficient by design walk throughs, design inspections. &lt;/div&gt;
&lt;br /&gt;
&lt;div style=&quot;text-align: justify;&quot;&gt;
The QA team should come up with the Test Plan mentioning all that will be carried out in testing&lt;/div&gt;
&lt;br /&gt;
&lt;b&gt;Coding Phase&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;div style=&quot;text-align: justify;&quot;&gt;
During this phase all the laid down coding standards should be followed strictly, following of UI standards, naming conventions to be accurate. &lt;/div&gt;
&lt;br /&gt;
&lt;div style=&quot;text-align: justify;&quot;&gt;
The QA should come up with test cases using the requirements and also following what is been said in the test Plan&lt;/div&gt;
&lt;br /&gt;
&lt;b&gt;Testing Phase &lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;div style=&quot;text-align: justify;&quot;&gt;
All the Test Cases should be executed for carrying out functional/integration/regression testing primarily and mark in the Test cases whether “Passed” or “Failed”.&lt;/div&gt;
&lt;br /&gt;
&lt;b&gt;Conclusion&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;div style=&quot;text-align: justify;&quot;&gt;
If the two groups work closely together, the high level of risk at a project’s inception will decrease to an acceptable level by the project’s conclusion.&lt;/div&gt;
&lt;br /&gt;
&lt;b&gt;For further more detailed information on this topic look up&lt;/b&gt;&lt;br /&gt;
&lt;a href=&quot;http://www.indiastudychannel.com/resources/80723-Quality-Standard-for-Software-Project.aspx&quot; style=&quot;color: #660000;&quot;&gt;&lt;b&gt;Quality Standard for a Software Project&lt;/b&gt;&lt;/a&gt;&lt;br /&gt;
&lt;a href=&quot;http://www.indiastudychannel.com/&quot;&gt;&lt;b&gt;&lt;br /&gt;&lt;/b&gt;&lt;/a&gt;&lt;/div&gt;
</content><link rel='replies' type='application/atom+xml' href='http://kiranqa.blogspot.com/feeds/5260000090351577266/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kiranqa.blogspot.com/2012/07/common-quality-standards-in-sdlc.html#comment-form' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5626494138934609795/posts/default/5260000090351577266'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5626494138934609795/posts/default/5260000090351577266'/><link rel='alternate' type='text/html' href='http://kiranqa.blogspot.com/2012/07/common-quality-standards-in-sdlc.html' title='Common Quality Standards in SDLC'/><author><name>Kanikaram Kiranpaul</name><uri>http://www.blogger.com/profile/06778345340371108991</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5626494138934609795.post-6809344143456787904</id><published>2012-07-18T03:10:00.000-07:00</published><updated>2012-07-18T03:18:40.075-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="testing methodologies"/><category scheme="http://www.blogger.com/atom/ns#" term="testing methods"/><category scheme="http://www.blogger.com/atom/ns#" term="testing model"/><category scheme="http://www.blogger.com/atom/ns#" term="waterfall model"/><title type='text'>Testing Methodologies - Waterfall Model</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;
Waterfall model is a &#39;top down&#39; method or approach for Software Testing or Development. Following are the steps in waterfall model&lt;br /&gt;
&lt;br /&gt;
&lt;h5 style=&quot;color: #660000; font-weight: normal;&quot;&gt;
&lt;div style=&quot;text-align: justify;&quot;&gt;
1. Requirement Analysis. &lt;br /&gt;
2. Test Scenario Design. &lt;br /&gt;
3. Test Case Design. &lt;br /&gt;
4. Test Case Execution and Defect Reporting &lt;br /&gt;
5. Defect Retesting &lt;br /&gt;
6. Deployment and Maintenance&lt;/div&gt;
&lt;/h5&gt;
&lt;br /&gt;
Once you finish the first step you can move to the next step. There is no way you can bypass any step. Also once you complete a step there is no way you can move back to the previous step. &lt;br /&gt;
&lt;br /&gt;
There is no way that a given point of time two steps can be done in parallel. The waterfall model follows a non-iterative approach. This model is followed because it is simple, systematic and orthodox approach. &lt;br /&gt;
&lt;br /&gt;
The shortcomings are that the defects in the code is not discovered in an early phase but only during the Testing or execution phase which becomes cumbersome and a lot of time, money and resource wastage happens. &lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kiranqa.blogspot.com/feeds/6809344143456787904/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kiranqa.blogspot.com/2012/07/testing-methodologies-waterfall-model.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5626494138934609795/posts/default/6809344143456787904'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5626494138934609795/posts/default/6809344143456787904'/><link rel='alternate' type='text/html' href='http://kiranqa.blogspot.com/2012/07/testing-methodologies-waterfall-model.html' title='Testing Methodologies - Waterfall Model'/><author><name>Kanikaram Kiranpaul</name><uri>http://www.blogger.com/profile/06778345340371108991</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5626494138934609795.post-7708918988928534938</id><published>2012-07-13T03:02:00.001-07:00</published><updated>2012-07-13T03:04:57.713-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="BRD"/><category scheme="http://www.blogger.com/atom/ns#" term="Execution phase"/><category scheme="http://www.blogger.com/atom/ns#" term="FRD"/><category scheme="http://www.blogger.com/atom/ns#" term="Requirement Analysis"/><category scheme="http://www.blogger.com/atom/ns#" term="Software Testing"/><category scheme="http://www.blogger.com/atom/ns#" term="testing"/><category scheme="http://www.blogger.com/atom/ns#" term="Testing articles"/><category scheme="http://www.blogger.com/atom/ns#" term="Testing Phase"/><title type='text'>How to address the issue of changing requirements during Testing Phase?</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;
&lt;h2 class=&quot;myclass&quot;&gt;


&lt;div style=&quot;text-align: justify;&quot;&gt;
I have noticed that a lot of times there are changes to the FRD/BRD even after planning phase. This really is not a very good approach if the FRD is updated and sent to the QA team. There would be a lot of rework in the Test Scenarios and Test Cases and a lot of time is involved in this process. This may seem fine as long these changes are taking place in the Planning phase but imagine if the requirements keep on changing.&lt;br /&gt;
&lt;br /&gt;
During the execution phase then there are many chances that the requirements may not be fully tested and a lot of UAT defects may arise. To avoid all these there are some measures given below which have been successfully implemented and saw the result which resulted in the UAT defects being decreased.&lt;br /&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;/h2&gt;
&lt;h5 style=&quot;color: #660000; font-weight: normal;&quot;&gt;

1. The QA team needs to make sure that the FRD received is the final approved version from the Business/Development team.&lt;br /&gt;
2. Any cosmetic changes can be accommodated during the planning phase.&lt;br /&gt;
3. Any functional changes should come as Change Request and should be taken care by during planning phase.&lt;br /&gt;
4. It should be communicated to the business or Development team that the FRDs should not be just updated for functional changes if this is the process then it should be intimated to the QA team&lt;br /&gt;
5. During execution phase any type of changes should come as Change Request. These changes can be by business to enhance any requirements or because of the defects raised by the QA team some functionality needs to be changed. This should not be changed in the FRD and the defect should not be cancelled.&lt;br /&gt;
6. Instead all the changes should come as Change Request and QA should estimate the&amp;nbsp; effort for planning and execution and should be taken care after the execution phase. The process may defer from company to company.&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Conclusion:&lt;/b&gt; Any type of changes in the requirements should not hamper the work of the QA but should come in the forms of CRs so that QA team can analyze and have additional time to test.&lt;/h5&gt;
&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://kiranqa.blogspot.com/feeds/7708918988928534938/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kiranqa.blogspot.com/2012/07/how-to-address-issue-of-changing.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5626494138934609795/posts/default/7708918988928534938'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5626494138934609795/posts/default/7708918988928534938'/><link rel='alternate' type='text/html' href='http://kiranqa.blogspot.com/2012/07/how-to-address-issue-of-changing.html' title='How to address the issue of changing requirements during Testing Phase?'/><author><name>Kanikaram Kiranpaul</name><uri>http://www.blogger.com/profile/06778345340371108991</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5626494138934609795.post-148297409975099060</id><published>2010-06-15T05:12:00.000-07:00</published><updated>2010-06-15T05:16:28.822-07:00</updated><title type='text'>Database Testing - SQL - Sub-Query Operators: (ALL,ANY,SOME,EXISTS)</title><content type='html'>&lt;span style=&quot;font-weight: bold;&quot;&gt;Sub-Query operators: (ALL,ANY,SOME,EXISTS)&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;43. List out the employees who earn more than every employee in department 30.&lt;/span&gt;&lt;br /&gt;&lt;/div&gt;&lt;br /&gt;&lt;h5 style=&quot;font-weight: normal; color: rgb(153, 0, 0); text-align: justify;&quot; class=&quot;myclass&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;Select * from employee where salary &gt; (Select Max(salary) from employee where department_id=30)&lt;/span&gt;&lt;/h5&gt;&lt;br /&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;44. List out the employees who earn more than the lowest salary in department 30.&lt;/span&gt;&lt;br /&gt;&lt;/div&gt;&lt;br /&gt;&lt;h5 style=&quot;font-weight: normal; text-align: justify; color: rgb(153, 0, 0);&quot; class=&quot;myclass&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;Select * from employee where salary &gt; (Select min(salary) from employee where department_id=30)&lt;/span&gt;&lt;/h5&gt;&lt;br /&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;45. Find out whose department has no employees.&lt;/span&gt;&lt;br /&gt;&lt;/div&gt;&lt;br /&gt;&lt;h5 style=&quot;font-weight: normal; color: rgb(153, 0, 0); text-align: justify;&quot; class=&quot;myclass&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;Select * from department d where not exists (Select department_id from employee e where d.department_id=e.department_id)&lt;/span&gt;&lt;/h5&gt;&lt;br /&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;By Using Joins&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;h5 style=&quot;color: rgb(153, 0, 0); text-align: justify; font-weight: normal;&quot; class=&quot;myclass&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;select employee_id, d.department_id, Name, Location_id from employee e  right join department d on d.department_id=e.department_id where e.employee_id is null and  d.department_id is not null&lt;/span&gt;&lt;/h5&gt;&lt;br /&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;46. Find out which department does not have any employees.&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;h5 style=&quot;font-weight: normal; color: rgb(153, 0, 0); text-align: justify;&quot; class=&quot;myclass&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;Select * from department d where not exists (Select department_id from employee e where d.department_id=e.department_id)&lt;/span&gt;&lt;/h5&gt;&lt;br /&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;Co-Related Sub Queries:&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;47. Find out the employees who earn greater than the average salary for their department.&lt;/span&gt;&lt;br /&gt;&lt;/div&gt;&lt;br /&gt;&lt;h5 style=&quot;font-weight: normal; color: rgb(153, 0, 0); text-align: justify;&quot; class=&quot;myclass&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;Select employee_id, last_name, salary, department_id from employee e where salary &gt; (select avg(salary) from employee where department_id=e.department_id)&lt;/span&gt;&lt;/h5&gt;</content><link rel='replies' type='application/atom+xml' href='http://kiranqa.blogspot.com/feeds/148297409975099060/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kiranqa.blogspot.com/2010/06/database-testing-sql-sub-query.html#comment-form' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5626494138934609795/posts/default/148297409975099060'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5626494138934609795/posts/default/148297409975099060'/><link rel='alternate' type='text/html' href='http://kiranqa.blogspot.com/2010/06/database-testing-sql-sub-query.html' title='Database Testing - SQL - Sub-Query Operators: (ALL,ANY,SOME,EXISTS)'/><author><name>Kanikaram Kiranpaul</name><uri>http://www.blogger.com/profile/06778345340371108991</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5626494138934609795.post-4149649910498679716</id><published>2010-06-15T04:39:00.000-07:00</published><updated>2010-06-15T04:46:41.505-07:00</updated><title type='text'>Database Testing - SQL - Sub Queries Examples</title><content type='html'>&lt;span style=&quot;font-weight: bold;&quot;&gt;Sub-Queries&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;34. Display the employee who got the maximum salary.&lt;/span&gt;&lt;br /&gt;&lt;/div&gt;&lt;br /&gt;&lt;h5 style=&quot;font-weight: normal; color: rgb(153, 0, 0); text-align: justify;&quot; class=&quot;myclass&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;Select * from employee where salary=(select max(salary) from employee)&lt;/span&gt;&lt;/h5&gt;&lt;br /&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;35. Display the employees who are working in Sales department&lt;/span&gt;&lt;br /&gt;&lt;/div&gt;&lt;br /&gt;&lt;h5 style=&quot;font-weight: normal; color: rgb(153, 0, 0); text-align: justify;&quot; class=&quot;myclass&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;Select * from employee where department_id = (select department_id from department where name=&#39;SALES&#39;)&lt;/span&gt;&lt;/h5&gt;&lt;br /&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;36. Display the employees who are working as &quot;Clerk&quot;.&lt;/span&gt;&lt;br /&gt;&lt;/div&gt;&lt;br /&gt;&lt;h5 style=&quot;text-align: justify; font-weight: normal; color: rgb(153, 0, 0);&quot; class=&quot;myclass&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;Select * from employee where job_id in (select job_id from job where function1=&#39;CLERK&#39;)&lt;/span&gt;&lt;/h5&gt;&lt;br /&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;37. Display the employees who are working in &quot;Boston&quot;&lt;/span&gt;&lt;br /&gt;&lt;/div&gt;&lt;br /&gt;&lt;h5 style=&quot;text-align: justify; color: rgb(153, 0, 0); font-weight: normal;&quot; class=&quot;myclass&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;Select * from employee where department_id=(select department_id from department where location_id=(select location_id from location where regional_group=&#39;Boston&#39;))&lt;/span&gt;&lt;/h5&gt;&lt;br /&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;38. Find out no.of employees working in &#39;Sales&quot; department.&lt;/span&gt;&lt;br /&gt;&lt;/div&gt;&lt;br /&gt;&lt;h5 style=&quot;font-weight: normal; color: rgb(153, 0, 0);&quot; class=&quot;myclass&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;Select * from employee where department_id=(select department_id from department where name=&#39;SALES&#39; group by department_id)&lt;/span&gt;&lt;/h5&gt;&lt;br /&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;39. Update the employees salaries, who are working as Clerk on the basis of 10%.&lt;/span&gt;&lt;br /&gt;&lt;/div&gt;&lt;br /&gt;&lt;h5 style=&quot;font-weight: normal; color: rgb(153, 0, 0); text-align: justify;&quot; class=&quot;myclass&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;Update employee set salary=(salary*10/100) where job_id=(select job_id from job where function1=&#39;CLERK&#39;)&lt;/span&gt;&lt;/h5&gt;&lt;br /&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;40. Delete the employees who are working in accounting department.&lt;/span&gt;&lt;br /&gt;&lt;/div&gt;&lt;br /&gt;&lt;h5 style=&quot;font-weight: normal; color: rgb(153, 0, 0); text-align: justify;&quot; class=&quot;myclass&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;delete from employee where department_id=(select department_id from department where name=&#39;ACCOUNTING&#39;)&lt;/span&gt;&lt;/h5&gt;&lt;br /&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;41. Display the second highest salary drawing employee details.&lt;/span&gt;&lt;br /&gt;&lt;/div&gt;&lt;br /&gt;&lt;h5 style=&quot;font-weight: normal; color: rgb(153, 0, 0); text-align: justify;&quot; class=&quot;myclass&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;Select * from employee where salary=(select max(salary) from employee where salary &lt;(select max(salary) from employee))&lt;/span&gt;&lt;/h5&gt;&lt;br /&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;42. Display the 3rd highest salary drawing employee details&lt;/span&gt;&lt;br /&gt;&lt;/div&gt;&lt;br /&gt;&lt;h5 style=&quot;font-weight: normal; color: rgb(153, 0, 0); text-align: justify;&quot; class=&quot;myclass&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;Select * from employee a where 3 = (select COUNT(distinct(salary)) from employee b where b.salary &gt;=a.salary)&lt;/span&gt;&lt;/h5&gt;</content><link rel='replies' type='application/atom+xml' href='http://kiranqa.blogspot.com/feeds/4149649910498679716/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kiranqa.blogspot.com/2010/06/database-testing-sql-sub-queries.html#comment-form' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5626494138934609795/posts/default/4149649910498679716'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5626494138934609795/posts/default/4149649910498679716'/><link rel='alternate' type='text/html' href='http://kiranqa.blogspot.com/2010/06/database-testing-sql-sub-queries.html' title='Database Testing - SQL - Sub Queries Examples'/><author><name>Kanikaram Kiranpaul</name><uri>http://www.blogger.com/profile/06778345340371108991</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5626494138934609795.post-4888256694257294833</id><published>2010-06-15T04:12:00.000-07:00</published><updated>2010-06-15T04:29:32.674-07:00</updated><title type='text'>Database Testing - SQL - Group By &amp; Having Clause Examples</title><content type='html'>&lt;span style=&quot;font-weight: bold;&quot;&gt;Group By &amp;amp; Having Clause:&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;22. How many employees who are working in different departments wise in the organization&lt;/span&gt;&lt;br /&gt;&lt;/div&gt;&lt;br /&gt;&lt;h5 style=&quot;font-weight: normal; color: rgb(153, 0, 0); text-align: justify;&quot; class=&quot;myclass&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;Select department_id, count(*), from employee group by department_id&lt;/span&gt;&lt;/h5&gt;&lt;br /&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;23. List out the department wise maximum salary, minimum salary, average salary of the employees&lt;/span&gt;&lt;br /&gt;&lt;/div&gt;&lt;br /&gt;&lt;h5 style=&quot;font-weight: normal; color: rgb(153, 0, 0); text-align: justify;&quot; class=&quot;myclass&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;Select department_id, count(*), max(salary), min(salary), avg(salary) from employee group by department_id&lt;/span&gt;&lt;/h5&gt;&lt;br /&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;24. List out the job wise maximum salary, minimum salary, average salaries of the employees.&lt;/span&gt;&lt;br /&gt;&lt;/div&gt;&lt;br /&gt;&lt;h5 style=&quot;font-weight: normal; color: rgb(153, 0, 0);&quot; class=&quot;myclass&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;Select job_id, count(*), max(salary), min(salary), avg(salary) from employee group by job_id&lt;/span&gt;&lt;/h5&gt;&lt;br /&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;25. List out no. of employees joined in every month in ascending order&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;h5 style=&quot;font-weight: normal; color: rgb(153, 0, 0);&quot; class=&quot;myclass&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;Select datepart(month, hiredate) &#39;Month&#39; , count(*) &#39;No of Employees&#39; from employee group by datepart(month, hiredate) order by datepart(month, hiredate)&lt;/span&gt;&lt;/h5&gt;&lt;br /&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;26. List out the no.of employees for each month and year, in the ascending order based on the year, month.&lt;/span&gt;&lt;br /&gt;&lt;/div&gt;&lt;br /&gt;&lt;h5 style=&quot;font-weight: normal; color: rgb(153, 0, 0); text-align: justify;&quot; class=&quot;myclass&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;Select datepart(Year, hiredate) &#39;Year&#39;, datepart(month, hiredate) &#39;month&#39;, count(*) &#39;No of employees&#39; from employee group by datepart(year, hiredate), datepart(month, hiredate)&lt;/span&gt;&lt;/h5&gt;&lt;br /&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;27. List out the department id having atleast four employees.&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;h5 style=&quot;font-weight: normal; color: rgb(153, 0, 0); text-align: justify;&quot; class=&quot;myclass&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;Select department_id, count(*) &#39;no of employees&#39; from employee group by department_id having count(*)&gt;=4&lt;/span&gt;&lt;/h5&gt;&lt;br /&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;28. How many employees in January month.&lt;/span&gt;&lt;br /&gt;&lt;/div&gt;&lt;br /&gt;&lt;h5 style=&quot;font-weight: normal; color: rgb(153, 0, 0);&quot; class=&quot;myclass&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;Select datepart(month, hiredate) &#39;month&#39;, count(*) &#39;no of employees&#39; from employee group by datepart(month, hiredate) having datepart(month, hiredate)=1 --here 1 refers to January &lt;/span&gt;&lt;/h5&gt;&lt;br /&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;29. How many employees who are joined in February or August month.&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;h5 style=&quot;font-weight: normal; color: rgb(153, 0, 0); text-align: justify;&quot; class=&quot;myclass&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;Select datepart(month, hiredate) &#39;month&#39;, count(*) &#39;No of Employees&#39; from employee group by datepart(month, hiredate) having datepart(month, hiredate) in (2,8)&lt;/span&gt;&lt;/h5&gt;&lt;br /&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;30. How many employees who are joined in 1985.&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;h5 style=&quot;font-weight: normal; color: rgb(153, 0, 0);&quot; class=&quot;myclass&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;Select datepart(Year, hiredate) &#39;Year&#39;, count(*) &#39;No of Employees&#39; from employee group by datepart(Year, hiredate)having datepart(Year, hiredate) =1985&lt;/span&gt;&lt;/h5&gt;&lt;br /&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;31. How many employees joined each month in 1985.&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;h5 style=&quot;font-weight: normal; color: rgb(153, 0, 0); text-align: justify;&quot; class=&quot;myclass&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;Select datepart(year,hiredate )&#39;Year&#39;, datepart(month, hiredate) &#39;Month&#39;, count(*) &#39;No of employees&#39; from employee where datepart(year, hiredate)=1985 group by datepart(year, hiredate),datepart(month, hiredate)&lt;/span&gt;&lt;/h5&gt;&lt;br /&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;32. How many employees who are joined in May 1985.&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;h5 style=&quot;color: rgb(153, 0, 0); font-weight: normal; text-align: justify;&quot; class=&quot;myclass&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;Select datepart(Year, hiredate) &#39;Year&#39;, datepart(Month, hiredate) &#39;Month&#39;, count(*) &#39;No of employees&#39; from employee where datepart(Year, hiredate)=1985 and datepart(month, hiredate)=5 group by datepart(Year, hiredate),datepart(Month, hiredate)&lt;/span&gt;&lt;/h5&gt;&lt;br /&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;33. Which is the department id, having less than or equal to 3 employees joined in April 1985.&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;h5 style=&quot;font-weight: normal; color: rgb(153, 0, 0);&quot; class=&quot;myclass&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;Select department_id, count(*) &#39;No. of employees&#39; from employee where datepart(Year, hiredate)=1985 and datepart(Month, hiredate) = 4 group by datepart(Year, hiredate), datepart(Month, hiredate), department_id having count(*)&lt;=3&lt;/span&gt;&lt;/h5&gt;</content><link rel='replies' type='application/atom+xml' href='http://kiranqa.blogspot.com/feeds/4888256694257294833/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kiranqa.blogspot.com/2010/06/database-testing-sql-group-by-having.html#comment-form' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5626494138934609795/posts/default/4888256694257294833'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5626494138934609795/posts/default/4888256694257294833'/><link rel='alternate' type='text/html' href='http://kiranqa.blogspot.com/2010/06/database-testing-sql-group-by-having.html' title='Database Testing - SQL - Group By &amp; Having Clause Examples'/><author><name>Kanikaram Kiranpaul</name><uri>http://www.blogger.com/profile/06778345340371108991</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5626494138934609795.post-978428219350793301</id><published>2010-06-15T03:41:00.000-07:00</published><updated>2010-06-15T03:43:48.644-07:00</updated><title type='text'>Database Testing - SQL - Order by clause</title><content type='html'>&lt;span style=&quot;font-weight: bold;&quot;&gt;Order By Clause:&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;18. List out the employee id, last name in ascending order based on the employee id.&lt;/span&gt;&lt;br /&gt;&lt;/div&gt;&lt;br /&gt;&lt;h5 style=&quot;font-weight: normal; color: rgb(153, 0, 0);&quot; class=&quot;myclass&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;Select employee_id, last_name from employee order by employee_id&lt;/span&gt;&lt;/h5&gt;&lt;br /&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;19. List out the employee id, name in descending order based on salary column&lt;/span&gt;&lt;br /&gt;&lt;/div&gt;&lt;br /&gt;&lt;h5 style=&quot;font-weight: normal; color: rgb(153, 0, 0);&quot; class=&quot;myclass&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;Select employee_id, last_name, salary from employee order by salary desc&lt;/span&gt;&lt;/h5&gt;&lt;br /&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;20. list out the employee details according to their last_name in ascending order and salaries in descending order&lt;/span&gt;&lt;br /&gt;&lt;/div&gt;&lt;br /&gt;&lt;h5 style=&quot;color: rgb(153, 0, 0); font-weight: normal; text-align: justify;&quot; class=&quot;myclass&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;Select employee_id, last_name, salary from employee order by last_name, salary desc&lt;/span&gt;&lt;/h5&gt;&lt;br /&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;21. list out the employee details according to their last_name in ascending order and then on department_id in descending order.&lt;/span&gt;&lt;br /&gt;&lt;/div&gt;&lt;br /&gt;&lt;h5 style=&quot;text-align: justify; color: rgb(153, 0, 0); font-weight: normal;&quot; class=&quot;myclass&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;Select employee_id, last_name, salary from employee order by last_name, department_id desc&lt;/span&gt;&lt;/h5&gt;</content><link rel='replies' type='application/atom+xml' href='http://kiranqa.blogspot.com/feeds/978428219350793301/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kiranqa.blogspot.com/2010/06/database-testing-sql-order-by-clause.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5626494138934609795/posts/default/978428219350793301'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5626494138934609795/posts/default/978428219350793301'/><link rel='alternate' type='text/html' href='http://kiranqa.blogspot.com/2010/06/database-testing-sql-order-by-clause.html' title='Database Testing - SQL - Order by clause'/><author><name>Kanikaram Kiranpaul</name><uri>http://www.blogger.com/profile/06778345340371108991</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5626494138934609795.post-2862652283650079791</id><published>2010-06-15T03:29:00.000-07:00</published><updated>2010-06-15T03:38:53.427-07:00</updated><title type='text'>Database Testing - SQL- Where Condition Examples</title><content type='html'>&lt;span style=&quot;font-weight: bold;&quot;&gt;Where Conditions:&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;8. List the details about &quot;SMITH&quot;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;h5 style=&quot;font-weight: normal; color: rgb(102, 0, 0);&quot; class=&quot;myclass&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;Select * from employee where last_name=&#39;SMITH&#39;;&lt;/span&gt;&lt;/h5&gt;&lt;br /&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;9. List out the employees who are working in department 20&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;h5 style=&quot;color: rgb(102, 0, 0); font-weight: normal;&quot; class=&quot;myclass&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;Select * from employee where department_id=20&lt;/span&gt;&lt;/h5&gt;&lt;br /&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;10. List out the employees who are earning salary between 3000 and 4500&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;h5 style=&quot;font-weight: normal; color: rgb(102, 0, 0);&quot; class=&quot;myclass&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;Select * from employee where salary between 3000 and 4500&lt;/span&gt;&lt;/h5&gt;&lt;br /&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;11. List out the employees who are working in department 10 or 20&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;h5 style=&quot;font-weight: normal; color: rgb(102, 0, 0);&quot; class=&quot;myclass&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;Select * from employee where department_id in (10,20)&lt;/span&gt;&lt;/h5&gt;&lt;br /&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;12. Find out the employees who are not working in department 10 or 30&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;h5 style=&quot;font-weight: normal; color: rgb(102, 0, 0);&quot; class=&quot;myclass&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;Select last_name, salary, commission, department_id from employee where department_id not in (10,30)&lt;/span&gt;&lt;/h5&gt;&lt;br /&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;13. List out the employees whose name starts with &quot;S&quot;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;h5 style=&quot;font-weight: normal; color: rgb(102, 0, 0);&quot; class=&quot;myclass&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;Select * from employee where last_name like &#39;S%&#39;&lt;/span&gt;&lt;/h5&gt;&lt;br /&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;14. List out the employees whose name start with &quot;S&quot; and end with &quot;H&quot;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;h5 style=&quot;font-weight: normal; color: rgb(102, 0, 0);&quot; class=&quot;myclass&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;Select * from employee where last_name like &#39;S%H&#39;&lt;/span&gt;&lt;/h5&gt;&lt;br /&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;15. List out the employees whose name length is 4 and start with &quot;S&quot;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;h5 style=&quot;font-weight: normal; color: rgb(102, 0, 0);&quot; class=&quot;myclass&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;Select * from employee where last_name like &#39;S___&#39;&lt;/span&gt;&lt;/h5&gt;&lt;br /&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;16. List out the employees who are working in department 10 and draw the salaries more than 3500&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;h5 style=&quot;font-weight: normal; color: rgb(102, 0, 0);&quot; class=&quot;myclass&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;Select * from employee where department_id=10 and salary&gt;3500&lt;/span&gt;&lt;/h5&gt;&lt;br /&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;17. list out the employees who are not receiving commission.&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;h5 style=&quot;font-weight: normal; color: rgb(102, 0, 0);&quot; class=&quot;myclass&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;Select * from employee where commission is Null&lt;/span&gt;&lt;/h5&gt;</content><link rel='replies' type='application/atom+xml' href='http://kiranqa.blogspot.com/feeds/2862652283650079791/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kiranqa.blogspot.com/2010/06/database-testing-sql-where-condition.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5626494138934609795/posts/default/2862652283650079791'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5626494138934609795/posts/default/2862652283650079791'/><link rel='alternate' type='text/html' href='http://kiranqa.blogspot.com/2010/06/database-testing-sql-where-condition.html' title='Database Testing - SQL- Where Condition Examples'/><author><name>Kanikaram Kiranpaul</name><uri>http://www.blogger.com/profile/06778345340371108991</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5626494138934609795.post-7653026672738346763</id><published>2010-06-15T03:24:00.000-07:00</published><updated>2010-06-15T03:29:40.373-07:00</updated><title type='text'>Database Testing - SQL - Simple Queries Examples</title><content type='html'>&lt;span style=&quot;font-weight: bold;&quot;&gt;Simple Queries:&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;1. List all the employee details&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;h5 style=&quot;font-weight: normal; color: rgb(102, 0, 0);&quot; class=&quot;myclass&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;Select * from employee;&lt;/span&gt;&lt;/h5&gt;&lt;br /&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;2. List all the department details&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;h5 style=&quot;font-weight: normal; color: rgb(102, 0, 0);&quot; class=&quot;myclass&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;Select * from department;&lt;/span&gt;&lt;/h5&gt;&lt;br /&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;3. List all job details&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;h5 style=&quot;font-weight: normal; color: rgb(102, 0, 0);&quot; class=&quot;myclass&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;Select * from job;&lt;/span&gt;&lt;/h5&gt;&lt;br /&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;4. List all the locations&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;h5 style=&quot;font-weight: normal; color: rgb(102, 0, 0);&quot; class=&quot;myclass&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;Select * from location;&lt;/span&gt;&lt;/h5&gt;&lt;br /&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;5. List out first name,last name,salary, commission for all employees&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;h5 style=&quot;font-weight: normal; color: rgb(102, 0, 0);&quot; class=&quot;myclass&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;Select first_name, last_name, salary, commission from employee;&lt;/span&gt;&lt;/h5&gt;&lt;br /&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;6. List out employee_id,last name,department id for all  employees and rename employee id as &quot;ID  of the employee&quot;, last name as &quot;Name of the employee&quot;, department id as  &quot;department  ID&quot;&lt;/span&gt;&lt;br /&gt;&lt;/div&gt;&lt;br /&gt;&lt;h5 style=&quot;font-weight: normal; color: rgb(102, 0, 0);&quot; class=&quot;myclass&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;Select employee_id &quot; of the employee&quot;, last_name &quot;name&quot;, department id as &quot;department id&quot; from employee;&lt;/span&gt;&lt;/h5&gt;&lt;br /&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;7. List out the employees annual salary with their names only.&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;h5 style=&quot;font-weight: normal; color: rgb(102, 0, 0);&quot; class=&quot;myclass&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;Select last_name, salary*12 &quot;annual salary&quot; from employee&lt;/span&gt;&lt;/h5&gt;</content><link rel='replies' type='application/atom+xml' href='http://kiranqa.blogspot.com/feeds/7653026672738346763/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kiranqa.blogspot.com/2010/06/database-testing-sql-simple-queries.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5626494138934609795/posts/default/7653026672738346763'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5626494138934609795/posts/default/7653026672738346763'/><link rel='alternate' type='text/html' href='http://kiranqa.blogspot.com/2010/06/database-testing-sql-simple-queries.html' title='Database Testing - SQL - Simple Queries Examples'/><author><name>Kanikaram Kiranpaul</name><uri>http://www.blogger.com/profile/06778345340371108991</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5626494138934609795.post-1530929556503574575</id><published>2010-06-15T03:08:00.000-07:00</published><updated>2010-06-15T03:24:05.925-07:00</updated><title type='text'>Database Testing - SQL - Insertion of Values in the Tables</title><content type='html'>&lt;h1 style=&quot;text-align: justify;&quot;&gt;To insert values in to these tables we use Data Manipulation Language Command called INSERT which allows us to insert values in to the columns of the table. Any string inserted should be enclosed within &#39;&#39;&lt;/h1&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;Syntax:&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;h5 style=&quot;font-weight: normal; color: rgb(102, 0, 0);&quot; class=&quot;myclass&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;Insert [tablename] value (col1, col2, coln)&lt;/span&gt;&lt;/h5&gt;&lt;br /&gt;To insert values in the Location table&lt;br /&gt;&lt;br /&gt;&lt;h5 style=&quot;font-weight: normal; color: rgb(102, 0, 0);&quot; class=&quot;myclass&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;Insert location&lt;br /&gt;values (122, &#39;New York&#39;),&lt;br /&gt;(123, &#39;Dallas&#39;),&lt;br /&gt;(124, &#39;Chicago&#39;),&lt;br /&gt;(167, &#39;Boston&#39;)&lt;/span&gt;&lt;/h5&gt;&lt;br /&gt;To insert values in the department table&lt;br /&gt;&lt;br /&gt;&lt;h5 style=&quot;font-weight: normal; color: rgb(102, 0, 0);&quot; class=&quot;myclass&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;Insert department&lt;br /&gt;values (10, &#39;Accounts&#39;, 122),&lt;br /&gt;(20, &#39;Research&#39;, 124),&lt;br /&gt;(30, &#39;Sales&#39;, 123),&lt;br /&gt;(40, &#39;Operations&#39;, 167)&lt;/span&gt;&lt;/h5&gt;&lt;br /&gt;To insert values in the job table&lt;br /&gt;&lt;br /&gt;&lt;h5 style=&quot;font-weight: normal; color: rgb(102, 0, 0);&quot; class=&quot;myclass&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;Insert job&lt;br /&gt;values (667, &#39;Clerk&#39;),&lt;br /&gt;(668, &#39;staff&#39;),&lt;br /&gt;(669, &#39;analyst&#39;),&lt;br /&gt;(670, &#39;salesperson&#39;),&lt;br /&gt;(671, &#39;manager&#39;),&lt;br /&gt;(672, &#39;president&#39;)&lt;/span&gt;&lt;/h5&gt;&lt;br /&gt;To insert values in the employee table&lt;br /&gt;&lt;br /&gt;&lt;h5 style=&quot;font-weight: normal; color: rgb(102, 0, 0);&quot; class=&quot;myclass&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;insert employee&lt;br /&gt;values (7369,&#39;Smith&#39;, &#39;John&#39;, &#39;Q&#39;, 667,7902,&#39;17-Dec-84&#39;, 800,&#39;Null&#39; , 20)&lt;br /&gt;&lt;br /&gt;insert employee&lt;br /&gt;values (7499,&#39;Allen&#39;, &#39;Kevin&#39;, &#39;J&#39;, 670,7698,&#39;20-Feb-85&#39;, 1600, 300, 30)&lt;br /&gt;&lt;br /&gt;insert employee&lt;br /&gt;values (7505,&#39;Doyle&#39;, &#39;Jean&#39;, &#39;K&#39;, 671,7839,&#39;04-Apr-85&#39;, 2850, &#39;Null&#39;, 30)&lt;br /&gt;&lt;br /&gt;insert employee&lt;br /&gt;values (7506,&#39;Dennis&#39;, &#39;Lynn&#39;, &#39;S&#39;, 671,7839,&#39;15-May-85&#39;, 2750, &#39;Null&#39;, 30)&lt;br /&gt;&lt;br /&gt;insert employee&lt;br /&gt;values (7507,&#39;Baker&#39;, &#39;Leslie&#39;, &#39;D&#39;, 671,7839,&#39;10-Jun-85&#39;, 2200, &#39;Null&#39;, 40)&lt;br /&gt;&lt;br /&gt;insert employee&lt;br /&gt;values (7521,&#39;Wark&#39;, &#39;Cynthia&#39;, &#39;D&#39;, 670,7698,&#39;22-Feb-85&#39;, 1250, 500, 30)&lt;/span&gt;&lt;/h5&gt;</content><link rel='replies' type='application/atom+xml' href='http://kiranqa.blogspot.com/feeds/1530929556503574575/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kiranqa.blogspot.com/2010/06/database-testing-sql-insertion-of.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5626494138934609795/posts/default/1530929556503574575'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5626494138934609795/posts/default/1530929556503574575'/><link rel='alternate' type='text/html' href='http://kiranqa.blogspot.com/2010/06/database-testing-sql-insertion-of.html' title='Database Testing - SQL - Insertion of Values in the Tables'/><author><name>Kanikaram Kiranpaul</name><uri>http://www.blogger.com/profile/06778345340371108991</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5626494138934609795.post-8544743033710329291</id><published>2010-06-15T02:45:00.000-07:00</published><updated>2010-06-15T03:24:15.006-07:00</updated><title type='text'>Database testing - SQL - Creation of Database and Tables for practice</title><content type='html'>&lt;h1 style=&quot;text-align: justify;&quot;&gt;First of all let us create a database with tables so that we can use all the examples given in the next posts for practice and this will help us to have a hold on SQL.&lt;/h1&gt;&lt;br /&gt;&lt;br /&gt;To create a database we use the Data Definition Language Command called CREATE&lt;br /&gt;&lt;br /&gt;&lt;b&gt;Syntax:&lt;/b&gt;&lt;br /&gt;&lt;h5 style=&quot;font-weight: normal; color: rgb(102, 0, 0);&quot; class=&quot;myclass&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;Create database [Name of the database]&lt;/span&gt;&lt;/h5&gt;&lt;br /&gt;&lt;b&gt;Example:&lt;/b&gt;&lt;br /&gt;&lt;br /&gt;&lt;h5 style=&quot;font-weight: normal; color: rgb(102, 0, 0);&quot; class=&quot;myclass&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;create database Practice&lt;/span&gt;&lt;/h5&gt;&lt;br /&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;To create different tables we use the DDL command Create and for tables we need to use the keyword table. We also need to specify the column names and the data type the column holds&lt;br /&gt;&lt;/div&gt;&lt;br /&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;Syntax: &lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;h5 style=&quot;font-weight: normal; color: rgb(102, 0, 0);&quot; class=&quot;myclass&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;Create table [Name of the table]&lt;br /&gt;(&lt;br /&gt;Column 1 Datatype,&lt;br /&gt;Column 2 Datatype,&lt;br /&gt;Column n Datatype&lt;br /&gt;)&lt;/span&gt;&lt;/h5&gt;&lt;br /&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;Example:&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;To create a location table for our Practice Database&lt;br /&gt;&lt;br /&gt;&lt;h5 style=&quot;font-weight: normal; color: rgb(102, 0, 0);&quot; class=&quot;myclass&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;Create table location&lt;br /&gt;(&lt;br /&gt;location_id int,&lt;br /&gt;regional_group varchar(100)&lt;br /&gt;)&lt;/span&gt;&lt;/h5&gt;&lt;br /&gt;To create a department table for our Practice Database&lt;br /&gt;&lt;br /&gt;&lt;h5 style=&quot;font-weight: normal; color: rgb(102, 0, 0);&quot; class=&quot;myclass&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;Create table department&lt;br /&gt;(&lt;br /&gt;department_id int,&lt;br /&gt;Name varchar(100),&lt;br /&gt;location_id int&lt;br /&gt;)&lt;/span&gt;&lt;/h5&gt;&lt;br /&gt;To create a job table for our Practice Database&lt;br /&gt;&lt;br /&gt;&lt;h5 style=&quot;font-weight: normal; color: rgb(102, 0, 0);&quot; class=&quot;myclass&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;Create table job&lt;br /&gt;(job_id int,&lt;br /&gt;function1 varchar(50)&lt;br /&gt;)&lt;/span&gt;&lt;/h5&gt;&lt;br /&gt;To create a employee table for our Practice Database&lt;br /&gt;&lt;br /&gt;&lt;h5 style=&quot;font-weight: normal; color: rgb(102, 0, 0);&quot; class=&quot;myclass&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;Create table employee&lt;br /&gt;(&lt;br /&gt;employee_id int,&lt;br /&gt;Last_name varchar(100),&lt;br /&gt;First_name varchar(100),&lt;br /&gt;Middle_name varchar(100),&lt;br /&gt;Job_id int,&lt;br /&gt;manager_id int,&lt;br /&gt;hiredate datetime,&lt;br /&gt;salary int,&lt;br /&gt;comm varchar(100) ,&lt;br /&gt;department_id int&lt;br /&gt;)&lt;/span&gt;&lt;/h5&gt;</content><link rel='replies' type='application/atom+xml' href='http://kiranqa.blogspot.com/feeds/8544743033710329291/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kiranqa.blogspot.com/2010/06/database-testing-sql-creation-of.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5626494138934609795/posts/default/8544743033710329291'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5626494138934609795/posts/default/8544743033710329291'/><link rel='alternate' type='text/html' href='http://kiranqa.blogspot.com/2010/06/database-testing-sql-creation-of.html' title='Database testing - SQL - Creation of Database and Tables for practice'/><author><name>Kanikaram Kiranpaul</name><uri>http://www.blogger.com/profile/06778345340371108991</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5626494138934609795.post-2181679425103570778</id><published>2010-04-30T04:56:00.000-07:00</published><updated>2010-04-30T05:11:29.204-07:00</updated><title type='text'>VB Script Examples for Begineers</title><content type='html'>&lt;h2 style=&quot;text-align: justify;&quot; class=&quot;myclass&quot;&gt;Here you will find many VB Script Examples for easy understanding and also when you are perfect in this then you can use the skill to create scripts for QTP 9.2. Vb script on prime numbers, VB script on Functions etc are found here.&lt;/h2&gt;&lt;br /&gt;&lt;h2 class=&quot;myclass&quot;&gt;1. Click on &lt;a href=&quot;http://kiranqa.blogspot.com/2010/04/answers-to-assignments-for-if-else.html&quot; target=&quot;_blank&quot;&gt;&lt;b&gt;Script to Print the Greatest of Three Integers&lt;/b&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;2. Click on &lt;a href=&quot;http://kiranqa.blogspot.com/2010/04/answers-to-assignment-on-for-looping.html&quot; target=&quot;_blank&quot;&gt;&lt;b&gt;Script to Print different Arithmetic Operations using Select Statement&lt;/b&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;3. Click on &lt;a href=&quot;http://kiranqa.blogspot.com/2010/04/script-to-print-prime-numbers.html&quot; target=&quot;&#39;_blank&#39;&quot;&gt;&lt;b&gt;Script to Print Prime Numbers&lt;/b&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;4. Click on &lt;a href=&quot;http://kiranqa.blogspot.com/2010/04/fibonacci-series-code.html&quot; target=&quot;&#39;_blank&#39;&quot;&gt;&lt;b&gt;Script to Generate a Fibonacci Series&lt;/b&gt;&lt;br /&gt;&lt;/a&gt;&lt;/h2&gt;</content><link rel='replies' type='application/atom+xml' href='http://kiranqa.blogspot.com/feeds/2181679425103570778/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kiranqa.blogspot.com/2010/04/vb-script-examples.html#comment-form' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5626494138934609795/posts/default/2181679425103570778'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5626494138934609795/posts/default/2181679425103570778'/><link rel='alternate' type='text/html' href='http://kiranqa.blogspot.com/2010/04/vb-script-examples.html' title='VB Script Examples for Begineers'/><author><name>Kanikaram Kiranpaul</name><uri>http://www.blogger.com/profile/06778345340371108991</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5626494138934609795.post-6211045684372842349</id><published>2010-04-28T02:21:00.000-07:00</published><updated>2010-04-28T02:42:00.970-07:00</updated><title type='text'>Write a VB Script to check whether a given number is prime or not?</title><content type='html'>&lt;h2 class=&quot;myclass&quot;&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;We can use a For Next Loop or Do While Loop to check whether a number given is a prime number or not in VB Script. The challenge lies in writing a VB script without using any built in functions of VB Script.&lt;/div&gt;&lt;/h2&gt;&lt;br /&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;Method 1&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;h5 style=&quot;font-weight: normal; color: rgb(102, 0, 0);&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;a = cint(Inputbox(&quot;Enter a number to check whether it is a prime number or not&quot;))&lt;br /&gt;count = 0&lt;br /&gt;b = 1&lt;br /&gt;Do while b&lt;=a&lt;br /&gt;&lt;span style=&quot;color: rgb(250, 250, 210);&quot;&gt;aaa&lt;/span&gt;if a mod b = 0 Then&lt;br /&gt;&lt;span style=&quot;color: rgb(250, 250, 210);&quot;&gt;aaaaaa&lt;/span&gt;count = count +1&lt;br /&gt;&lt;span style=&quot;color: rgb(250, 250, 210);&quot;&gt;aaa&lt;/span&gt;End If &lt;br /&gt;b=b+1&lt;br /&gt;Loop&lt;br /&gt;If count = 2 Then&lt;br /&gt;&lt;span style=&quot;color: rgb(250, 250, 210);&quot;&gt;aaa&lt;/span&gt;msgbox &quot;The number &quot;&amp;amp;a&amp;amp; &quot; is a prime number&quot;  &lt;br /&gt;Else  &lt;br /&gt;&lt;span style=&quot;color: rgb(250, 250, 210);&quot;&gt;aaa&lt;/span&gt;msgbox &quot;The number &quot;&amp;amp;a&amp;amp; &quot; is not a prime number&quot;&lt;br /&gt;End if&lt;/span&gt;&lt;/h5&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;Method 2&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;h5 style=&quot;font-weight: normal; color: rgb(102, 0, 0);&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;val=Inputbox(&quot;Please enter any number&quot;)&lt;br /&gt;valprime = 0&lt;br /&gt;For i=2 to Int(val/2)&lt;br /&gt;&lt;span style=&quot;color: rgb(250, 250, 210);&quot;&gt;aaa&lt;/span&gt;If val mod I = 0 Then&lt;br /&gt;&lt;span style=&quot;color: rgb(250, 250, 210);&quot;&gt;aaa&lt;/span&gt;msgbox &quot;The number&quot;&amp;amp;val&amp;amp;&quot; is not a prime number&quot;&lt;br /&gt;&lt;span style=&quot;color: rgb(250, 250, 210);&quot;&gt;aaa&lt;/span&gt;valprime=1&lt;br /&gt;&lt;span style=&quot;color: rgb(250, 250, 210);&quot;&gt;aaa&lt;/span&gt;Exit for&lt;br /&gt;End If&lt;br /&gt;Next&lt;br /&gt;If valprime=0 Then&lt;br /&gt;&lt;span style=&quot;color: rgb(250, 250, 210);&quot;&gt;aaa&lt;/span&gt;msgbox &quot;The number&quot;&amp;amp;val&amp;amp;&quot; is a prime number&quot;&lt;br /&gt;End If&lt;/span&gt;&lt;/h5&gt;</content><link rel='replies' type='application/atom+xml' href='http://kiranqa.blogspot.com/feeds/6211045684372842349/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kiranqa.blogspot.com/2010/04/write-vb-script-to-check-whether-given.html#comment-form' title='6 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5626494138934609795/posts/default/6211045684372842349'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5626494138934609795/posts/default/6211045684372842349'/><link rel='alternate' type='text/html' href='http://kiranqa.blogspot.com/2010/04/write-vb-script-to-check-whether-given.html' title='Write a VB Script to check whether a given number is prime or not?'/><author><name>Kanikaram Kiranpaul</name><uri>http://www.blogger.com/profile/06778345340371108991</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>6</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5626494138934609795.post-6210455065381853491</id><published>2010-04-28T02:18:00.000-07:00</published><updated>2010-04-28T02:20:59.598-07:00</updated><title type='text'>Write a Script in VB to reverse a string given by the user</title><content type='html'>&lt;h2 class=&quot;myclass&quot;&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;This VB Script demonstrates how we can reverse a string or a number given by the user and print it in a reverse order. Here we use Len and Mid methods of VB Script library. In the method one we will find the length of the string and store in y variable and then use a for loop in a descending order and give step as -1.&lt;/div&gt;&lt;/h2&gt;&lt;br /&gt;&lt;br /&gt;&lt;b&gt;Method 1&lt;/b&gt;&lt;br /&gt;&lt;br /&gt;&lt;h5 style=&quot;font-weight: normal; color: rgb(102, 0, 0);&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;MyStr = InputBox(“Enter a string to be reversed”)&lt;br /&gt;y = Len(MyStr)&lt;br /&gt;For x = y To 1 Step -1&lt;br /&gt;&lt;span style=&quot;color: rgb(250, 250, 210);&quot;&gt;aaa&lt;/span&gt;char = Mid(MyStr,x,1)&lt;br /&gt;&lt;span style=&quot;color: rgb(250, 250, 210);&quot;&gt;aaa&lt;/span&gt;NewStr = NewStr &amp;amp; char&lt;br /&gt;Next&lt;br /&gt;&lt;span style=&quot;color: rgb(250, 250, 210);&quot;&gt;aaa&lt;/span&gt;msgbox newstr&lt;/span&gt;&lt;/h5&gt;&lt;br /&gt;&lt;br /&gt;&lt;b&gt;Method 2 using the StrReverse Method.&lt;/b&gt;&lt;br /&gt;&lt;br /&gt;&lt;h5 style=&quot;color: rgb(102, 0, 0); font-weight: normal;&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;val=Inputbox(&quot;Please enter any number or a string&quot;)&lt;br /&gt;a = strReverse(val)&lt;br /&gt;msgbox &quot;The reverse of &quot;&amp;amp;val&amp;amp; &quot; is: &quot;&amp;amp;a&lt;/span&gt;&lt;/h5&gt;</content><link rel='replies' type='application/atom+xml' href='http://kiranqa.blogspot.com/feeds/6210455065381853491/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kiranqa.blogspot.com/2010/04/write-script-in-vb-to-reverse-string.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5626494138934609795/posts/default/6210455065381853491'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5626494138934609795/posts/default/6210455065381853491'/><link rel='alternate' type='text/html' href='http://kiranqa.blogspot.com/2010/04/write-script-in-vb-to-reverse-string.html' title='Write a Script in VB to reverse a string given by the user'/><author><name>Kanikaram Kiranpaul</name><uri>http://www.blogger.com/profile/06778345340371108991</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5626494138934609795.post-1942921071423340569</id><published>2010-04-28T01:52:00.000-07:00</published><updated>2010-04-28T02:09:19.672-07:00</updated><title type='text'>Write a VB script to print a Text File in reverse way i.e from the Last line to first line</title><content type='html'>&lt;h2 class=&quot;myclass&quot;&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;This VB scripts demonstrates on using the FileSystemObject to read a text file and display the lines in the text file in a reverse order i.e the lines begins with the last line in the text file and ends with the first line as the last line.&lt;/div&gt;&lt;/h2&gt;&lt;br /&gt;&lt;h5 style=&quot;font-weight: normal; color: rgb(102, 0, 0);&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;Dim arrLines()&lt;br /&gt;i = 0&lt;br /&gt;&lt;br /&gt;Set FSO = CreateObject(&quot;Scripting.FileSystemObject&quot;)&lt;br /&gt;Set Fil = FSO.OpenTextFile(&quot;F:\TestFolder\Text1.txt&quot;, 1)&lt;br /&gt;&lt;br /&gt;Do Until Fil.AtEndOfStream&lt;br /&gt;  &lt;span style=&quot;color: rgb(250, 250, 210);&quot;&gt;aaa&lt;/span&gt;Redim Preserve arrLines(i)&lt;br /&gt;  &lt;span style=&quot;color: rgb(250, 250, 210);&quot;&gt;aaa&lt;/span&gt;arrLines(i) = Fil.ReadLine&lt;br /&gt;  &lt;span style=&quot;color: rgb(250, 250, 210);&quot;&gt;aaa&lt;/span&gt;i = i + 1&lt;br /&gt;Loop&lt;br /&gt;&lt;br /&gt;Fil.Close&lt;br /&gt;&lt;br /&gt;For l = Ubound(arrLines) to LBound(arrLines) Step -1&lt;br /&gt; &lt;span style=&quot;color: rgb(250, 250, 210);&quot;&gt;aaa&lt;/span&gt;str = str&amp;amp;arrLines(l)&amp;amp;vbnewline&lt;br /&gt;Next&lt;br /&gt;&lt;br /&gt;msgbox str&lt;/span&gt;&lt;/h5&gt;</content><link rel='replies' type='application/atom+xml' href='http://kiranqa.blogspot.com/feeds/1942921071423340569/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kiranqa.blogspot.com/2010/04/write-vb-script-to-print-text-file-in.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5626494138934609795/posts/default/1942921071423340569'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5626494138934609795/posts/default/1942921071423340569'/><link rel='alternate' type='text/html' href='http://kiranqa.blogspot.com/2010/04/write-vb-script-to-print-text-file-in.html' title='Write a VB script to print a Text File in reverse way i.e from the Last line to first line'/><author><name>Kanikaram Kiranpaul</name><uri>http://www.blogger.com/profile/06778345340371108991</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5626494138934609795.post-4716120943498144467</id><published>2010-04-27T23:43:00.000-07:00</published><updated>2010-04-28T01:38:48.595-07:00</updated><title type='text'>Write a Script to print the phone list in VB Script using Arrays dynamically</title><content type='html'>&lt;h2 class=&quot;myclass&quot;&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;Write a Script to print the phone list in VB Script using Arrays dynamically.&lt;br /&gt;&lt;/div&gt;&lt;br /&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;&lt;span style=&quot;font-weight: normal;&quot;&gt;Here we are using a Dynamic array because we do not know the lower and upper bound of the array and the user enters the column and row count for the array. Also we are asking the user to give input the field values for the array. The script in VB looks like this. You can copy the script and paste it in a notepad and save as a .vbs file and execute it.&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;/div&gt;&lt;/h2&gt;&lt;br /&gt;&lt;h3&gt;Method 1 for writing the script&lt;/h3&gt;&lt;br /&gt;&lt;h5 style=&quot;font-weight: normal; color: rgb(102, 0, 0);&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;col = InputBox(&quot;Enter the number of Columns&quot;)&lt;br /&gt;row = InputBox(&quot;Enter the number of Rows&quot;)&lt;br /&gt;Dim arrphonelist()&lt;br /&gt;&lt;br /&gt;ReDim arrphonelist(col,row)&lt;br /&gt;&lt;br /&gt;For i = 0 to row&lt;br /&gt;&lt;span style=&quot;color: rgb(250, 250, 210);&quot;&gt;aaa&lt;/span&gt;For j = 0 to col&lt;br /&gt;&lt;br /&gt;&lt;span style=&quot;color: rgb(250, 250, 210);&quot;&gt;aaaaaa&lt;/span&gt;Arrphonelist(j,i) = InputBox(&quot;Enter the First name&quot;)&lt;br /&gt;&lt;span style=&quot;color: rgb(250, 250, 210);&quot;&gt;aaaaaaaaa&lt;/span&gt;j=j+1&lt;br /&gt;&lt;span style=&quot;color: rgb(250, 250, 210);&quot;&gt;aaaaaa&lt;/span&gt;Arrphonelist(j,i) = InputBox(&quot;Enter the Last name&quot;)&lt;br /&gt;&lt;span style=&quot;color: rgb(250, 250, 210);&quot;&gt;aaaaaaaaa&lt;/span&gt;j=j+1&lt;br /&gt;&lt;span style=&quot;color: rgb(250, 250, 210);&quot;&gt;aaaaaa&lt;/span&gt;Arrphonelist(j,i) = InputBox(&quot;Enter the Phone Number&quot;)&lt;br /&gt;&lt;span style=&quot;color: rgb(250, 250, 210);&quot;&gt;aaa&lt;/span&gt;Next&lt;br /&gt;Next&lt;br /&gt;&lt;br /&gt;arrubound = ubound(arrphonelist,2)&lt;br /&gt;&lt;br /&gt;For k = 0 to arrubound&lt;br /&gt;&lt;span style=&quot;color: rgb(250, 250, 210);&quot;&gt;aaa&lt;/span&gt;str = str&amp;amp;arrphonelist(0,k)&amp;amp;&quot; &quot;&lt;br /&gt;&lt;span style=&quot;color: rgb(250, 250, 210);&quot;&gt;aaa&lt;/span&gt;str = str&amp;amp;arrphonelist(1,k)&amp;amp;&quot; &quot;&lt;br /&gt;&lt;span style=&quot;color: rgb(250, 250, 210);&quot;&gt;aaa&lt;/span&gt;str = str&amp;amp;arrphonelist(2,k)&amp;amp;vbnewline&lt;br /&gt;Next&lt;br /&gt;&lt;br /&gt;&lt;span style=&quot;color: rgb(250, 250, 210);&quot;&gt;aaa&lt;/span&gt;Msgbox &quot;The Phone List is &quot;&amp;amp;vbnewline&amp;amp;str&lt;/span&gt;&lt;/h5&gt;&lt;br /&gt;&lt;br /&gt;&lt;h3&gt;Method 2 where we only ask the number of rows and keep the columns fixed to 3&lt;/h3&gt;&lt;br /&gt;&lt;h5 style=&quot;font-weight: normal; color: rgb(102, 0, 0);&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;row = InputBox(&quot;Enter the number of Rows&quot;)&lt;br /&gt;&lt;br /&gt;Dim arrphonelist()&lt;br /&gt;ReDim arrphonelist(2,row)&lt;br /&gt;&lt;br /&gt;For i = 0 to row -1&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;color: rgb(250, 250, 210);font-size:100%;&quot; &gt;aaa&lt;/span&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;For j = 0 to 2&lt;br /&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;color: rgb(250, 250, 210);font-size:100%;&quot; &gt;aaaaaa&lt;/span&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;Arrphonelist(0,i) = InputBox(&quot;Enter the First name&quot;)&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;color: rgb(250, 250, 210);font-size:100%;&quot; &gt;aaaaaaaaa&lt;/span&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;j=j+1&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;color: rgb(250, 250, 210);font-size:100%;&quot; &gt;aaaaaa&lt;/span&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;Arrphonelist(1,i) = InputBox(&quot;Enter the Last name&quot;)&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;color: rgb(250, 250, 210);font-size:100%;&quot; &gt;aaaaaaaaa&lt;/span&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;j=j+1&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;color: rgb(250, 250, 210);font-size:100%;&quot; &gt;aaaaaa&lt;/span&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;Arrphonelist(2,i) = InputBox(&quot;Enter the Phone Number&quot;)&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;color: rgb(250, 250, 210);font-size:100%;&quot; &gt;aaa&lt;/span&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;Next&lt;br /&gt;Next&lt;br /&gt;&lt;br /&gt;arrubound = ubound(arrphonelist,2)&lt;br /&gt;&lt;br /&gt;For k = 0 to arrubound&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;color: rgb(250, 250, 210);font-size:100%;&quot; &gt;aaa&lt;/span&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;str = str&amp;amp;arrphonelist(0,k)&amp;amp;&quot; &quot;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;color: rgb(250, 250, 210);font-size:100%;&quot; &gt;aaa&lt;/span&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;str = str&amp;amp;arrphonelist(1,k)&amp;amp;&quot; &quot;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;color: rgb(250, 250, 210);font-size:100%;&quot; &gt;aaa&lt;/span&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;str = str&amp;amp;arrphonelist(2,k)&amp;amp;vbnewline&lt;br /&gt;Next&lt;br /&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;color: rgb(250, 250, 210);font-size:100%;&quot; &gt;aaa&lt;/span&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;Msgbox &quot;The Phone List is &quot;&amp;amp;vbnewline&amp;amp;str&lt;/span&gt;&lt;/h5&gt;</content><link rel='replies' type='application/atom+xml' href='http://kiranqa.blogspot.com/feeds/4716120943498144467/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kiranqa.blogspot.com/2010/04/script-to-print-phone-list-in-vb-script.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5626494138934609795/posts/default/4716120943498144467'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5626494138934609795/posts/default/4716120943498144467'/><link rel='alternate' type='text/html' href='http://kiranqa.blogspot.com/2010/04/script-to-print-phone-list-in-vb-script.html' title='Write a Script to print the phone list in VB Script using Arrays dynamically'/><author><name>Kanikaram Kiranpaul</name><uri>http://www.blogger.com/profile/06778345340371108991</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5626494138934609795.post-8251440627815270326</id><published>2010-04-27T23:33:00.000-07:00</published><updated>2010-04-28T01:41:36.619-07:00</updated><title type='text'>Write a Script to print a Phone List in VB using Arrays</title><content type='html'>&lt;h2 class=&quot;myclass&quot;&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;Write a Script to print the phone list in VB Script using Arrays.&lt;br /&gt;&lt;/div&gt;&lt;br /&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;Here we are using a static array because we are giving the lowerbound and upperbound of the array. Also we are giving the array values. The script in VB looks like this. You can copy the script and paste it in a notepad and save as a .vbs file and execute it. You have to remember that the column and Row count in VB using Arrays start by default with zero and hence for 3 columns we are giving 2 because 0 to 2 makes it 3 columns and like wise for rows.&lt;br /&gt;&lt;/div&gt;&lt;/h2&gt;&lt;br /&gt;&lt;h5 style=&quot;font-weight: normal; color: rgb(102, 0, 0);&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;&#39;Initializing an array with 3 columns and 4 rows&lt;br /&gt;&lt;br /&gt;Dim arrphonelist(2,3)&lt;br /&gt;&lt;br /&gt;&#39;Giving all the values of different columns for the 4 rows.&lt;br /&gt;Arrphonelist(0,0) = &quot;John&quot;&lt;br /&gt;Arrphonelist(1,0) = &quot;Abharam&quot;&lt;br /&gt;Arrphonelist(2,0) = &quot;9854685623&quot;&lt;br /&gt;&lt;br /&gt;Arrphonelist(0,1) = &quot;Mark&quot;&lt;br /&gt;Arrphonelist(1,1) = &quot;Robin&quot;&lt;br /&gt;Arrphonelist(2,1) = &quot;9955662233&quot;&lt;br /&gt;&lt;br /&gt;Arrphonelist(0,2) = &quot;Peter&quot;&lt;br /&gt;Arrphonelist(1,2) = &quot;Marshal&quot;&lt;br /&gt;Arrphonelist(2,2) = &quot;8080454525&quot;&lt;br /&gt;&lt;br /&gt;Arrphonelist(0,3) = &quot;Alex&quot;&lt;br /&gt;Arrphonelist(1,3) = &quot;Blackston&quot;&lt;br /&gt;Arrphonelist(2,3) = &quot;9865653526&quot;&lt;br /&gt;&lt;br /&gt;&#39;Initializing the upperbound of the array for checking the no of rows&lt;br /&gt;&#39;for this we have entered 2 which represents the 2nd dimension&lt;br /&gt;arrubound = ubound(arrphonelist,2)&lt;br /&gt;&lt;br /&gt;For i = 0 to arrubound&lt;br /&gt;&lt;span style=&quot;color: rgb(250, 250, 210);&quot;&gt;aaa&lt;/span&gt;str = str&amp;amp;arrphonelist(0,i)&amp;amp;&quot; &quot;&lt;br /&gt;&lt;span style=&quot;color: rgb(250, 250, 210);&quot;&gt;aaa&lt;/span&gt;str = str&amp;amp;arrphonelist(1,i)&amp;amp;&quot; &quot;&lt;br /&gt;&lt;span style=&quot;color: rgb(250, 250, 210);&quot;&gt;aaa&lt;/span&gt;str = str&amp;amp;arrphonelist(2,i)&amp;amp;vbnewline&lt;br /&gt;Next&lt;br /&gt;&lt;br /&gt;&lt;span style=&quot;color: rgb(250, 250, 210);&quot;&gt;aaa&lt;/span&gt;Msgbox &quot;The Phone List is &quot;&amp;amp;vbnewline&amp;amp;str&lt;/span&gt;&lt;/h5&gt;</content><link rel='replies' type='application/atom+xml' href='http://kiranqa.blogspot.com/feeds/8251440627815270326/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kiranqa.blogspot.com/2010/04/script-to-print-phone-list-in-vb-using.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5626494138934609795/posts/default/8251440627815270326'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5626494138934609795/posts/default/8251440627815270326'/><link rel='alternate' type='text/html' href='http://kiranqa.blogspot.com/2010/04/script-to-print-phone-list-in-vb-using.html' title='Write a Script to print a Phone List in VB using Arrays'/><author><name>Kanikaram Kiranpaul</name><uri>http://www.blogger.com/profile/06778345340371108991</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5626494138934609795.post-6819479083037819774</id><published>2010-04-27T23:29:00.000-07:00</published><updated>2010-04-28T01:43:52.155-07:00</updated><title type='text'>Write a Sample VB script using Arrays</title><content type='html'>&lt;h2 class=&quot;myclass&quot;&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;Write a VB script using Array to print different color Names.&lt;br /&gt;&lt;/div&gt;&lt;br /&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;Here we declared an Array and indexed it to 6 columns even though we gave the index as 5. we need to remember that in VB the index starts from zero. When we declared the array and assigned the values we are now assigning the array upperbound to a variable so that using that variable we can use a for loop to print all the values.&lt;br /&gt;&lt;/div&gt;&lt;/h2&gt;&lt;br /&gt;&lt;h5 style=&quot;font-weight: normal; color: rgb(102, 0, 0);&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;Dim arrcolors(5)&lt;br /&gt;&lt;span style=&quot;color: rgb(250, 250, 210);&quot;&gt;aaa&lt;/span&gt;arrcolors(0) = &quot;Blue&quot;&lt;br /&gt;&lt;span style=&quot;color: rgb(250, 250, 210);&quot;&gt;aaa&lt;/span&gt;arrcolors(1) = &quot;Green&quot;&lt;br /&gt;&lt;span style=&quot;color: rgb(250, 250, 210);&quot;&gt;aaa&lt;/span&gt;arrcolors(2) = &quot;Red&quot;&lt;br /&gt;&lt;span style=&quot;color: rgb(250, 250, 210);&quot;&gt;aaa&lt;/span&gt;arrcolors(3) = &quot;White&quot;&lt;br /&gt;&lt;span style=&quot;color: rgb(250, 250, 210);&quot;&gt;aaa&lt;/span&gt;arrcolors(4) = &quot;Black&quot;&lt;br /&gt;&lt;span style=&quot;color: rgb(250, 250, 210);&quot;&gt;aaa&lt;/span&gt;arrcolors(5) = &quot;Yellow&quot;&lt;br /&gt;&lt;br /&gt;arrubound = ubound(arrcolors)&lt;br /&gt;&lt;span style=&quot;color: rgb(250, 250, 210);&quot;&gt;aaa&lt;/span&gt;msgbox arrubound&lt;br /&gt;&lt;span style=&quot;color: rgb(250, 250, 210);&quot;&gt;aaaaaa&lt;/span&gt;For i = 0 to arrubound&lt;br /&gt;&lt;span style=&quot;color: rgb(250, 250, 210);&quot;&gt;aaaaaaaaa&lt;/span&gt;msgbox arrcolors(i)&lt;br /&gt;&lt;span style=&quot;color: rgb(250, 250, 210);&quot;&gt;aaaaaa&lt;/span&gt;Next&lt;br /&gt;&lt;br /&gt;&lt;span style=&quot;color: rgb(250, 250, 210);&quot;&gt;aaaaaa&lt;/span&gt;For each element in arrcolors&lt;br /&gt;&lt;span style=&quot;color: rgb(250, 250, 210);&quot;&gt;aaaaaaaaa&lt;/span&gt;msgbox element&lt;br /&gt;&lt;span style=&quot;color: rgb(250, 250, 210);&quot;&gt;aaaaaa&lt;/span&gt;Next&lt;/span&gt;&lt;/h5&gt;</content><link rel='replies' type='application/atom+xml' href='http://kiranqa.blogspot.com/feeds/6819479083037819774/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kiranqa.blogspot.com/2010/04/sample-vb-script-using-arrays.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5626494138934609795/posts/default/6819479083037819774'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5626494138934609795/posts/default/6819479083037819774'/><link rel='alternate' type='text/html' href='http://kiranqa.blogspot.com/2010/04/sample-vb-script-using-arrays.html' title='Write a Sample VB script using Arrays'/><author><name>Kanikaram Kiranpaul</name><uri>http://www.blogger.com/profile/06778345340371108991</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5626494138934609795.post-3225717084573999718</id><published>2010-04-26T06:27:00.000-07:00</published><updated>2010-04-28T01:45:05.272-07:00</updated><title type='text'>What is Array in VB scripting</title><content type='html'>&lt;h2 class=&quot;myclass&quot;&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;First of all let us understand what is an array in VB Scripting. How are arrays used in VB Scripting. What is the purpose of array in VB Script. Is there any difference between an array and a variable since both store values? What does an array do and how does an array store values.&lt;br /&gt;&lt;/div&gt;&lt;/h2&gt;&lt;br /&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;Array is a matrix of data. The difference between a variable and an array is that a variable holds a single value while an array holds multiple values. Array can be Static and Dynamic.&lt;br /&gt;&lt;/div&gt;&lt;br /&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;An array is said to be static if the upper limit of the array is known or defined. If the upper limit is not defined and the value is fetched from some other place or a user input it is known as Dynamic array.&lt;br /&gt;&lt;/div&gt;&lt;br /&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;Arrays should always be declared with a Dim Statement. In VB script a Dynamic array is classified as &lt;span style=&quot;font-weight: bold;&quot;&gt;Homogenous&lt;/span&gt; and  &lt;span style=&quot;font-weight: bold;&quot;&gt;Heterogeneous&lt;/span&gt;. A Homogenous array hold the same type of data while an heterogeneous array is a mix of different data types.&lt;br /&gt;&lt;/div&gt;&lt;br /&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;Generally an array in VB Script can be of 60 dimensions.&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;Syntax of a Single Dimensional Array&lt;br /&gt;&lt;br /&gt;&lt;h5 style=&quot;font-weight: normal; color: rgb(102, 0, 0);&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;Dim [Array name] (index)&lt;/span&gt;&lt;/h5&gt;&lt;br /&gt;It is to be noted that in an array the index begins with zero.&lt;br /&gt;&lt;br /&gt;Syntax of a two dimensional array&lt;br /&gt;&lt;br /&gt;&lt;h5 style=&quot;font-weight: normal; color: rgb(102, 0, 0);&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;Dim [Array name] (column id, row id)&lt;/span&gt;&lt;/h5&gt;&lt;br /&gt;Example of a two dimensional array&lt;br /&gt;&lt;br /&gt;&lt;h5 style=&quot;font-weight: normal; color: rgb(102, 0, 0);&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;Dim arrphonelist (2,3)&lt;/span&gt;&lt;/h5&gt;&lt;br /&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;Arrphonelist is the name of the array while 2 is the column id and is also known as 1st dimension and 3 is the row id and is also known as 2nd dimension.&lt;br /&gt;&lt;/div&gt;&lt;br /&gt;To get the row count of an array we write like this&lt;br /&gt;&lt;br /&gt;&lt;h5 style=&quot;font-weight: normal; color: rgb(102, 0, 0);&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;Row_count = ubound(arrphonelist, 2)&lt;/span&gt;&lt;/h5&gt;&lt;br /&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;For column count it is like this even though we predefine the number of rows as a best practice but still to have an idea we write like this&lt;br /&gt;&lt;/div&gt;&lt;br /&gt;&lt;h5 style=&quot;font-weight: normal; color: rgb(102, 0, 0);&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;column_count = ubound(arrphonelist, 1)&lt;/span&gt;&lt;/h5&gt;&lt;br /&gt;In an array always the columns are fixed and only rows are manipulated.</content><link rel='replies' type='application/atom+xml' href='http://kiranqa.blogspot.com/feeds/3225717084573999718/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kiranqa.blogspot.com/2010/04/arrays-in-vb-scripting.html#comment-form' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5626494138934609795/posts/default/3225717084573999718'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5626494138934609795/posts/default/3225717084573999718'/><link rel='alternate' type='text/html' href='http://kiranqa.blogspot.com/2010/04/arrays-in-vb-scripting.html' title='What is Array in VB scripting'/><author><name>Kanikaram Kiranpaul</name><uri>http://www.blogger.com/profile/06778345340371108991</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5626494138934609795.post-4278748733344318160</id><published>2010-04-26T05:05:00.000-07:00</published><updated>2010-04-28T01:50:26.939-07:00</updated><title type='text'>IN Built VB Script Functions</title><content type='html'>&lt;h2 class=&quot;myclass&quot;&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;As far as VB Scripting for QTP is concerned we will look at the four types of In Built Functions of VB scripting since we use them very often in QTP while writing scripts. The four inbuilt functions are&lt;br /&gt;&lt;/div&gt;&lt;br /&gt;1. Data &amp;amp; Time Function&lt;br /&gt;2. String Function&lt;br /&gt;3. Conversion function&lt;br /&gt;4. Array Function&lt;/h2&gt; &lt;br /&gt;&lt;h3&gt;Date &amp;amp; time Function&lt;/h3&gt;CDate: Converts a valid date and time expression to the variant of subtype Date&lt;br /&gt;Date: Returns the current system date&lt;br /&gt;DateAdd: Returns a date to which a specified time interval has been added&lt;br /&gt;DateDiff : Returns the number of intervals between two dates&lt;br /&gt;&lt;br /&gt;Example of DateDiff is&lt;br /&gt;&lt;br /&gt;&lt;h5 style=&quot;font-weight: normal; color: rgb(102, 0, 0);&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;Msgbox datediff(&quot;d&quot;, #mm/dd/yyyy#, Now)&lt;/span&gt;&lt;/h5&gt;&lt;br /&gt;Here d refers Day. This will print the difference in no of days.&lt;br /&gt;&lt;br /&gt;&lt;h3&gt;String Function&lt;/h3&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;With a String function we can scan the entire string and also get a count of the no of characters in the string. If needed we can use the Left and Right method to get a particular no of characters either from the left or right side of the string. You can also replace the string with a new value.&lt;br /&gt;&lt;/div&gt;&lt;br /&gt;&lt;h5 style=&quot;font-weight: normal; color: rgb(102, 0, 0);&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;Str = “This is Friday”&lt;br /&gt;Str = Right (str, 20)&lt;br /&gt;Str = Left (str, 8)&lt;/span&gt;&lt;/h5&gt;&lt;br /&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;The Left and Right Methods scan the string from Left/Right and prints the specified no of characters.&lt;br /&gt;&lt;/div&gt;&lt;br /&gt;&lt;h5&gt;&lt;span style=&quot;color: rgb(102, 0, 0);font-size:100%;&quot; &gt;&lt;span style=&quot;font-weight: normal;&quot;&gt;Str = “Hello World”&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-weight: normal;&quot;&gt;Arr = split(str, &quot;o&quot;)&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-weight: normal;&quot;&gt;Msgbox arr(0)&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-weight: normal;&quot;&gt;Msgbox arr(1)&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-weight: normal;&quot;&gt;Msgbox arr(2)&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;/h5&gt;&lt;br /&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;In the first message box it will print &#39;Hell&#39;, In the Second Message box it will print &#39;W&#39;, in the third message box it will print &#39;rld&#39;.&lt;br /&gt;&lt;/div&gt;&lt;br /&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;If you want to check whether a text file is there in a Folder then you need to use the split method to get the text file. After getting the folder using Get Folder and pointing to the files in the folder we need to write these lines of code in the For Next Loop.&lt;br /&gt;&lt;/div&gt;&lt;br /&gt;&lt;h5 style=&quot;font-weight: normal; color: rgb(102, 0, 0);&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;For each f in fil&lt;br /&gt;str = f.name&lt;br /&gt;arr = split(str, &quot;.&quot;)&lt;br /&gt;If arr(1) = &quot;txt&quot; then&lt;br /&gt;var = var&amp;amp;Vbnewline&amp;amp;f.name&lt;br /&gt;End If&lt;br /&gt;Next&lt;/span&gt;&lt;/h5&gt;&lt;br /&gt;Please look at the complete script for printing all the text files in a folder at&lt;br /&gt;&lt;br /&gt;&lt;a href=&quot;http://kiranqa.blogspot.com/2010/04/how-to-display-all-text-files-in-folder.html&quot; target=&quot;_ blank &quot;&gt;&lt;b&gt; How to display all the Text Files in a Folder&lt;/b&gt;&lt;/a&gt;</content><link rel='replies' type='application/atom+xml' href='http://kiranqa.blogspot.com/feeds/4278748733344318160/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kiranqa.blogspot.com/2010/04/in-built-vb-script-functions.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5626494138934609795/posts/default/4278748733344318160'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5626494138934609795/posts/default/4278748733344318160'/><link rel='alternate' type='text/html' href='http://kiranqa.blogspot.com/2010/04/in-built-vb-script-functions.html' title='IN Built VB Script Functions'/><author><name>Kanikaram Kiranpaul</name><uri>http://www.blogger.com/profile/06778345340371108991</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5626494138934609795.post-5914013416501241164</id><published>2010-04-26T02:23:00.000-07:00</published><updated>2010-04-28T01:51:24.437-07:00</updated><title type='text'>How to print all the Lines of a Text File in Excel sheet using VB Script</title><content type='html'>&lt;h2 class=&quot;myclass&quot;&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;Write a script in VB to write all the lines of a Text File into an excel spreadsheet using FileSystemObject&lt;br /&gt;&lt;/div&gt;&lt;br /&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;VB Script to write all the lines of a text file in to a Excel spread sheet. There are two ways to write all the lines by opening an existing Text File and the second one to create a Text File and write some lines and then writing them in the Excel Sheet.&lt;br /&gt;&lt;/div&gt;&lt;/h2&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;Method 1&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;h5 style=&quot;font-weight: normal; color: rgb(102, 0, 0);&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;Set objExcel = CreateObject(&quot;Excel.Application&quot;)&lt;br /&gt;objExcel.Visible=True&lt;br /&gt;&lt;br /&gt;objExcel.workbooks.Add()&lt;br /&gt;&lt;br /&gt;Const ForReading =1&lt;br /&gt;&lt;br /&gt;Set FSO = CreateObject(&quot;Scripting.FileSystemObject&quot;)&lt;br /&gt;Set file = FSO.OpenTextFile(&quot;F:\TestFolder\Text1.txt&quot;, 1)&lt;br /&gt;&lt;br /&gt;x=1&lt;br /&gt;&lt;br /&gt;Do Until File.AtEndOfStream&lt;br /&gt;Line = File.ReadLine&lt;br /&gt;objExcel.Cells(x,1) = Line&lt;br /&gt;&lt;br /&gt;x=x+1&lt;br /&gt;Loop&lt;br /&gt;&lt;br /&gt;objFile.Close&lt;/span&gt;&lt;/h5&gt;&lt;br /&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;Method 2&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;h5 style=&quot;font-weight: normal; color: rgb(102, 0, 0);&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;&#39;Script to create and write few lines in a Text file&lt;br /&gt;&#39;and write them in the excel sheet&lt;br /&gt;&lt;br /&gt;&#39;Create an object variable to interact with the File System Object&lt;br /&gt;Set Fso = CreateObject(&quot;Scripting.FileSystemObject&quot;)&lt;br /&gt;Set xlapp = CreateObject(&quot;Excel.Application&quot;)&lt;br /&gt;&lt;br /&gt;&#39;Create a text files using CreateTextFile method&lt;br /&gt;Set fil = Fso.CreateTextFile(&quot;F:\TestFolder\Text1.txt&quot;)&lt;br /&gt;Set wbook = xlapp.Workbooks.Add&lt;br /&gt;set wsheet = xlapp.worksheets(1)&lt;br /&gt;&lt;br /&gt;&#39;Write few lines into the first text file&lt;br /&gt;For i = 1 to 100&lt;br /&gt;fil.WriteLine(&quot;This is Line &quot;&amp;amp;i)&lt;br /&gt;Next&lt;br /&gt;&lt;br /&gt;Set fil = nothing&lt;br /&gt;&lt;br /&gt;&#39;Open first text file in read mode and write in excel sheet&lt;br /&gt;Set fil1 = fso.OpenTextFile(&quot;F:\TestFolder\Text1.txt&quot;,1, False)&lt;br /&gt;&lt;br /&gt;X=1&lt;br /&gt;Do Until fil1.AtEndOfStream&lt;br /&gt;strLine = fil1.ReadLine&lt;br /&gt;xlapp.Cells(x,1) = strLine&lt;br /&gt;X=x+1&lt;br /&gt;Loop&lt;br /&gt;&lt;br /&gt;wbook.SaveAs &quot;F:\TestFolder\Test.xls&quot;&lt;br /&gt;&lt;br /&gt;set wbook=nothing&lt;br /&gt;xlapp.quit&lt;br /&gt;set wsheet = nothing&lt;br /&gt;Set fil = nothing&lt;br /&gt;Set fil1=Nothing&lt;br /&gt;Set fil2 = nothing&lt;/span&gt;&lt;/h5&gt;</content><link rel='replies' type='application/atom+xml' href='http://kiranqa.blogspot.com/feeds/5914013416501241164/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://kiranqa.blogspot.com/2010/04/how-to-print-all-lines-of-text-file-in.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5626494138934609795/posts/default/5914013416501241164'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5626494138934609795/posts/default/5914013416501241164'/><link rel='alternate' type='text/html' href='http://kiranqa.blogspot.com/2010/04/how-to-print-all-lines-of-text-file-in.html' title='How to print all the Lines of a Text File in Excel sheet using VB Script'/><author><name>Kanikaram Kiranpaul</name><uri>http://www.blogger.com/profile/06778345340371108991</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry></feed>