SPONSORS:






User Tag List

Results 1 to 4 of 4
  1. #1
    Junior Member
    Join Date
    Dec 2002
    Posts
    17
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    BaseState for Database?

    Hi,
    I have a database testing to do for which Iam using the DBTester feature of SilkTest tool. Now my query is whether its possible to have a base state for the database which can be restored after each test.Whether SilkTest provides this option of restoring base state. If it does not, then what other options could be used.

    Regards
    Poornima

    ------------------

  2. #2
    Senior Member
    Join Date
    Jan 2002
    Location
    Des Moines, Iowa
    Posts
    289
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: BaseState for Database?

    There are lots of options. Depends on what you have in mind. One way that I have done it was to have a SQL Script run by Silk that will first drop then build the database.

    I used stored procedures to do this and then called them from Silk. You could also automate the Query tool (Query Analyzer ect...) to do this as well. This option might be easier to do unless you start to run into complex custom object problems with the editor.

    This would all depend on the complexity of what you are trying to do and the time frame that you have to work with.

    I have also in the past placed data in an Access Database so that once I got a clean build of a database under test (DUT) I could put data into it to quickly get it to a point that my tests could start. Word of caution here, to do this you really need to understand the database that you are working with so that you don't end up creating artificial bugs by having bad data in the tables.

    I have found that I were just testing to see that stored procedures or jobs perform as expected I would use the native SQL language to build something that verifies the data is correct. That way you can use the Commit features to accept or not accept the changes. The SQL or PLSQL languages are very robust and can do good comparision checks.

    If I was testing that the application was behaving well with the database I would use Silktest's DBTester to perform these checks because the checks need to be timed and compared with the gui interactions.

    I hope I have not confused you. If you have something specific in mind let me know and I might possible be able to tailor an answer for you.

    ------------------

  3. #3
    Junior Member
    Join Date
    Dec 2002
    Posts
    17
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: BaseState for Database?

    Hi blacst,

    To be precise about my Database testing, let me tell u I have the datamigration module to be verified.Here initially DUT is in its pure state without any data in it.So I would like to maintain this state each time after the test is executed.Can I do this erasing of the record once the test is completed by executing the SQl query delete.Can I consider this as one of the option of getting back the DUT to its pure state.

    From ur reply, certain doubts have popped up.
    1>Query Analyzer.......can u throw some light on it or atleast guide me with some doc.....Hearing this for the first time.
    2>How are u using the SQl script with Silk....do u mean the usage of SQl script with the DBTester function.If not, can u explain how ur using the SQL script with silk.
    3>Also, is it possible to use PLSql procedures with the DBTester function or its just the basic SQL commands it supports.

    Thanks & Regards
    Poornima

    ------------------


    [This message has been edited by Poornima (edited 03-02-2003).]

  4. #4
    Senior Member
    Join Date
    Jan 2002
    Location
    Des Moines, Iowa
    Posts
    289
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: BaseState for Database?

    Good morning Poornima,

    <BLOCKQUOTE><font size="1" face="Verdana, Arial, Helvetica">quote:</font><HR>Originally posted by Poornima:

    Query Analyzer.......can u throw some light on it or at least guide me with some doc.....Hearing this for the first time.
    <HR></BLOCKQUOTE>

    Query Analyzer,

    Is a sql tool developed by Microsoft and used in conjunction with SQL Server databases. This tool can be used to create SQL statements, Stored Procedures ect ..... and then executes them. You would only use this tool with SQL Server. This is the database I am most familiar with right now. I have used Oracle, but it was on a Unix system and I wasn't working with silk at the time. You could automate SQL Analyzer (Or its counter part in Oracle) to get it to perform various tasks for you instead of using the DB commands. This would be most benificial when you want to run Sql scripts saved as ".Qry" files and executed from the SQL editor.

    <BLOCKQUOTE><font size="1" face="Verdana, Arial, Helvetica">quote:</font><HR>Originally posted by Poornima:

    How are u using the SQl script with Silk....do u mean the usage of SQl script with the DBTester function.If not, can u explain how ur using the SQL script with silk.
    <HR></BLOCKQUOTE>

    With SQL Server, and you will have to ask someone currently using Oracle and silk right now, You can use the DB_ExecuteSql command and provide it a Stored Procedure as the sql statement. For example:

    This call will execute the named stored procedure and feed it the parmeters that are listed. I haven't had much luck being able to view return records from procedures. Someone else might have the answer to that. If I need data back I just run true sql query.

    If you were wanting to open a query file ".qry" with an editor and run it you will most likely have to automate the editor to accomplish this task. I have had a lot of luck turning my most used update or restore queries in to stored procedures so that I could call them instead of going to the effort of automating the Sql editor.

    <BLOCKQUOTE><font size="1" face="Verdana, Arial, Helvetica">quote:</font><HR>Originally posted by Poornima:

    Also, is it possible to use PLSql procedures with the DBTester function or its just the basic SQL commands it supports.
    <HR></BLOCKQUOTE>

    I believe that it is possible to use PLSql procedures. It is certainly easy to do with SQL Server. At this point we will have to ask for someone who is working with PLSql right now for the definitive answer.

    Atleast that person will be able to tell you what works and what does not work.



    ------------------

 

 

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  

vBulletin Optimisation provided by vB Optimise v2.6.0 Beta 4 (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
User Alert System provided by Advanced User Tagging v3.0.9 (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
Questions / Answers Form provided by vBAnswers (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
vBNominatevBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
Feedback Buttons provided by Advanced Post Thanks / Like (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
Username Changing provided by Username Change (Free) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
BetaSoft Inc.
Digital Point modules: Sphinx-based search
All times are GMT -8. The time now is 10:57 AM.

Copyright BetaSoft Inc.