how to connect database in vugen script.

394 views
Skip to first unread message

B Ram

unread,
Jun 14, 2011, 8:43:02 AM6/14/11
to lr-loa...@googlegroups.com
Hi All,
 
In My Application I need to connect database in vugen script , I need to execute one or more oracle 11g queries in vugen script and After Executing that queries, i need to save that values as a parameter values in my Script.
 
I tried with Data Wizard in parameter list, But It doesn't saving the connection string and Oracle query,is there anyway to save that two things in My Script,Else every time we need to Give Manually That query and connection string.
 
I used the Connection string as Driver={Microsoft ODBC for Oracle};CONNECTSTRING=(DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=11.120.36.12)(PORT=1521))(CONNECT_DATA=(SERVICE_NAME=wmsdev01)));Uid=wmqa;Pwd=wmqa1; in data Wizard.
 
Can We Call parameter file Automatically in Script at the time of execution, With out Giving   paramater  file path in parameter list.
 
Can Anyone Help me How to resolve this issues.
 
1).How to connect database in vugen.(for oracle 11g).
2).After  executing query in vugen,  How to Save that values as a parameter values.
3).can we call parameter file automatically in vugen script.
4).Can we save Connection string and query in Data wizard.
 
 
 
Thanks In Advance,
 
thanks &Regards,
 
Ram.
 
 
 

James Pulley

unread,
Jun 14, 2011, 9:36:28 AM6/14/11
to LoadRunner
There are a number of process and tool challenges inherent in your
questions
(1) If you query for parameters during the test you will be adding
load which is not present in the actual application. These queries
will likely not have been subject to the same level of scrutiny and
tuning as the rest of the system and you can quite easily distort the
entire performance envelope of the application under test with this
activity
(2) Data files are loaded into memory before the execution of the
vuser_init(). So, even if you were to download a data file in the
init section the values would be totally ignored for the duration of
the test. This loading into memory is to minimize the disk access by
the virtual users during the test as disk access can/does distort the
performance of a system under the load of larger numbers of virtual
users. In essence the disk subsystem becomes the bottleneck for the
test. Can you image tens.hundreds of virtual users all with
different file pointers in action requesting the read activity off of
the disk in close proximity of one another. Disk thrash of death can
result! You can also use this guidance as an admonition against
higher log levels during a test execution

Can you do this? Yes. You could need a combined database and "other"
virtual user script type, where other is your vuser type for your
application under test. You would need support for this type of
virtual user in the controller as well. Likely you would be
building the two scripts are primitives and then combining them. You
would need to write your own parameter file handler to connect to your
created file and use the data as you would be unable to use the built
in parametrization engine because of the aforementioned load into
memory and not from disk during the test. Should you do engage in
this. I would recommend against it. Just stage your data in data
files prior to the test.

James Pulley, http://www.loadrunnerbythehour.com/PricingMatrix
Budgets constrained? Come see how much more cost effective trained
personnel can be in your testing efforts.


On Jun 14, 8:43 am, B Ram <ramb...@gmail.com> wrote:
> Hi All,
>
> In My Application I need to connect database in vugen script , I need to
> execute one or more oracle 11g queries in vugen script and After Executing
> that queries, i need to save that values as a parameter values in my Script.
>
> I tried with *Data Wizard* in *parameter list*, But It doesn't saving the
> connection string and Oracle query,is there anyway to save that two things
> in My Script,Else every time we need to Give Manually That query and
> connection string.
>
> I used the Connection string as Driver={Microsoft ODBC for
> Oracle};CONNECTSTRING=(DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=11.120.36.12)(PORT=1521))(CONNECT_DATA=(SERVICE_NAME=wmsdev01)));Uid=wmqa;Pwd=wmqa1;
> in data Wizard.
>
>  Can We Call parameter file Automatically in Script at the time of
> execution, With out Giving   paramater  file path in parameter list.
>
> *Can Anyone Help me How to resolve this issues.*
Reply all
Reply to author
Forward
0 new messages