51Testing软件测试论坛

 找回密码
 (注-册)加入51Testing

QQ登录

只需一步,快速开始

微信登录,快人一步

手机号码,快捷登录

查看: 2405|回复: 6
打印 上一主题 下一主题

[原创] 使用loadrunner8.1关联后,回放和后台都没有报错但是没有执行新增插入语句

[复制链接]

该用户从未签到

跳转到指定楼层
1#
发表于 2010-11-2 10:48:19 | 只看该作者 回帖奖励 |倒序浏览 |阅读模式
loadrunner版本:8.1;
操作:点击“添加”》录入数据后》执行“上报”操作。
代码:
web_reg_save_param("ZID",
  "LB=input id=\"form:spb_id\" type=\"hidden\" name=\"form:spb_id\" value=\"",
  "RB=\"",
  "Ord=1",
  "Search=All",
  LAST);
  lr_output_message(lr_eval_string("{ZID}"));//能够成功取到关联的id号码
web_url("dbrw_lcrw_gcqzd_add.jsf",
   "URL=http://192.168.20.61:8080/jbpmjsp/dbrw/dbrw_lcrw_gcqzd_add.jsf?id_=7061&name_=gcqzd",
   "TargetFrame=",
   "Resource=0",
   "RecContentType=text/html",
   "Referer=http://192.168.20.61:8080/jbpmjsp/jbpmlcdbrw/dbrw_fqlc_frame.jsp?thisywdmid=oab",
   "Snapshot=t6.inf",
   "Mode=HTML",
   LAST);
    lr_output_message( lr_eval_string("{ZID}"));
  lr_start_transaction("发起流程");
  web_submit_data("dbrw_lcrw_gcqzd_add.jsf",
   "Action=http://192.168.20.61:8080/jbpmjsp/dbrw/dbrw_lcrw_gcqzd_add.jsf",
   "Method=POST",
   "TargetFrame=",
   "RecContentType=text/html",
   "Referer=http://192.168.20.61:8080/jbpmjsp/dbrw/dbrw_lcrw_gcqzd_add.jsf?id_=7061&name_=gcqzd",
   "Snapshot=t11.inf",
   "Mode=HTML",
   ITEMDATA,
   "Name=where", "Value=", ENDITEM,
   "Name=newwhere", "Value=", ENDITEM,
   "Name=sorttype", "Value=", ENDITEM,
   "Name=sortfield", "Value=", ENDITEM,
   "Name=itemPerPage", "Value=", ENDITEM,
   "Name=page", "Value=", ENDITEM,
   "Name=userid_", "Value=101", ENDITEM,
   "Name=id_", "Value=7061", ENDITEM,
   "Name=name_", "Value=gcqzd", ENDITEM,
   "Name=form:initAdd", "Value=", ENDITEM,
   "Name=form:spb_id", "Value={ZID}", ENDITEM,
   "Name=form:fsudt", "Value=2010-11-01 14:36:56", ENDITEM,
   "Name=form:fsuid", "Value=101", ENDITEM,
   "Name=form:xmmc", "Value=文昌迈号220千伏输变电新建工程>变电站>三通一平工程", ENDITEM,
   "Name=form:jldw", "Value=", ENDITEM,
   "Name=form:sgdw", "Value=", ENDITEM,
   "Name=form:gcxm_id", "Value=128886", ENDITEM,
   "Name=initthis", "Value=1", ENDITEM,
   "Name=functionform:shangbao", "Value=上报", ENDITEM, //开发分析,有可能是没有触发上报按钮,执行 insert操作?
   "Name=form:qzdlx", "Value=1", ENDITEM,
   "Name=form:spbmc", "Value=test123", ENDITEM,
   "Name=form:forxmmc", "Value=文昌迈号220千伏输变电新建工程>变电站>三通一平工程", ENDITEM,
   "Name=form:bgmc", "Value=test", ENDITEM,
   "Name=form:bgje", "Value=122", ENDITEM,
   "Name=form:ysjl", "Value=dsdssd", ENDITEM,
   "Name=form:dx", "Value=dssd", ENDITEM,
   "Name=form:wgfg", "Value=sddsds", ENDITEM,
   "Name=form:qt", "Value=sdds", ENDITEM,
   "Name=form:jsdz", "Value=文昌", ENDITEM,
   "Name=sbzl", "Value=", ENDITEM,
   "Name=sbmc", "Value=", ENDITEM,
   "Name=sbgg", "Value=", ENDITEM,
   "Name=sbsl", "Value=", ENDITEM,
   "Name=sbdw", "Value=", ENDITEM,
   "Name=form", "Value=form", ENDITEM,
   LAST);
lr_end_transaction("发起流程", LR_AUTO);
回放和后台都没有报错但是没有执行新增插入语句。开发分析,有可能是没有触发上报按钮,执行 insert操作?请问有什么解决方法吗。
分享到:  QQ好友和群QQ好友和群 QQ空间QQ空间 腾讯微博腾讯微博 腾讯朋友腾讯朋友
收藏收藏
回复

使用道具 举报

  • TA的每日心情
    奋斗
    2022-5-8 19:23
  • 签到天数: 137 天

    连续签到: 1 天

    [LV.7]测试师长

    2#
    发表于 2010-11-2 22:48:25 | 只看该作者
    你这个是web_submit_data,不存在是否有触发上报按钮的
    回复 支持 反对

    使用道具 举报

  • TA的每日心情
    奋斗
    2022-5-8 19:23
  • 签到天数: 137 天

    连续签到: 1 天

    [LV.7]测试师长

    3#
    发表于 2010-11-2 22:48:42 | 只看该作者
    开启详细日志,看看具体情况
    回复 支持 反对

    使用道具 举报

    该用户从未签到

    4#
    发表于 2010-11-3 09:17:02 | 只看该作者
    数据库定义的是不是唯一,不能插入重复记录呢?
    回复 支持 反对

    使用道具 举报

    该用户从未签到

    5#
    发表于 2010-11-3 09:21:25 | 只看该作者
    对变量参数化一下试试
    回复 支持 反对

    使用道具 举报

    该用户从未签到

    6#
     楼主| 发表于 2010-11-3 12:03:48 | 只看该作者
    问题补充,日志:
    Starting action Action.
    Action.c(5): Registering web_reg_save_param was successful          [MsgId: MMSG-26390]
    Action.c(12): Registering web_reg_save_param was successful          [MsgId: MMSG-26390]
    Action.c(19): Notify: Transaction "′ò?a·¢?eá÷3ìò3??" started.
    Action.c(21): Found resource "http://192.168.20.61:8080/css/display.css" in HTML "http://192.168.20.61:8080/jbpmjsp/dbrw/dbrw_lcrw_gcqzd_add.jsf?id_=7061&name_=gcqzd"          [MsgId: MMSG-26659]
    Action.c(21): Found resource "http://192.168.20.61:8080/js/collectionform.js" in HTML "http://192.168.20.61:8080/jbpmjsp/dbrw/dbrw_lcrw_gcqzd_add.jsf?id_=7061&name_=gcqzd"          [MsgId: MMSG-26659]
    Action.c(21): Found resource "http://192.168.20.61:8080/js/popcalendar.js" in HTML "http://192.168.20.61:8080/jbpmjsp/dbrw/dbrw_lcrw_gcqzd_add.jsf?id_=7061&name_=gcqzd"          [MsgId: MMSG-26659]
    Action.c(21): Found resource "http://192.168.20.61:8080/js/validateNumber.js" in HTML "http://192.168.20.61:8080/jbpmjsp/dbrw/dbrw_lcrw_gcqzd_add.jsf?id_=7061&name_=gcqzd"          [MsgId: MMSG-26659]
    Action.c(21): Found resource "http://192.168.20.61:8080/dwr/engine.js" in HTML "http://192.168.20.61:8080/jbpmjsp/dbrw/dbrw_lcrw_gcqzd_add.jsf?id_=7061&name_=gcqzd"          [MsgId: MMSG-26659]
    Action.c(21): Found resource "http://192.168.20.61:8080/dwr/util.js" in HTML "http://192.168.20.61:8080/jbpmjsp/dbrw/dbrw_lcrw_gcqzd_add.jsf?id_=7061&name_=gcqzd"          [MsgId: MMSG-26659]
    Action.c(21): Found resource "http://192.168.20.61:8080/dwr/interface/savexmjd.js" in HTML "http://192.168.20.61:8080/jbpmjsp/dbrw/dbrw_lcrw_gcqzd_add.jsf?id_=7061&name_=gcqzd"          [MsgId: MMSG-26659]
    Action.c(21): Detected non-resource "http://192.168.20.61:8080/attachment.jsp?rowid=171791&tableId=1314" in "http://192.168.20.61:8080/jbpmjsp/dbrw/dbrw_lcrw_gcqzd_add.jsf?id_=7061&name_=gcqzd"          [MsgId: MMSG-26574]
    Action.c(21): web_url("dbrw_lcrw_gcqzd_add.jsf") was successful, 196098 body bytes, 1949 header bytes, 312 chunking overhead bytes          [MsgId: MMSG-26385]
    Action.c(30): 171791
    Action.c(32): 2010-11-03 11:52:19
    Action.c(34): Notify: Transaction "′ò?a·¢?eá÷3ìò3??" ended with "Pass" status (Duration: 2.0083 Wasted Time: 0.0018).
    Action.c(36): Notify: Transaction "?′DD·¢?e2ù×÷" started.
    Action.c(38): Resource "http://192.168.20.61:8080/css/display.css" is in the cache already and will not be downloaded again          [MsgId: MMSG-26655]
    Action.c(38): Resource "http://192.168.20.61:8080/js/collectionform.js" is in the cache already and will not be downloaded again          [MsgId: MMSG-26655]
    Action.c(38): Resource "http://192.168.20.61:8080/js/popcalendar.js" is in the cache already and will not be downloaded again          [MsgId: MMSG-26655]
    Action.c(38): Resource "http://192.168.20.61:8080/js/validateNumber.js" is in the cache already and will not be downloaded again          [MsgId: MMSG-26655]
    Action.c(38): Found resource "http://192.168.20.61:8080/dwr/engine.js" in HTML "http://192.168.20.61:8080/jbpmjsp/dbrw/dbrw_lcrw_gcqzd_add.jsf"          [MsgId: MMSG-26659]
    Action.c(38): Resource "http://192.168.20.61:8080/dwr/util.js" is in the cache already and will not be downloaded again          [MsgId: MMSG-26655]
    Action.c(38): Found resource "http://192.168.20.61:8080/dwr/interface/savexmjd.js" in HTML "http://192.168.20.61:8080/jbpmjsp/dbrw/dbrw_lcrw_gcqzd_add.jsf"          [MsgId: MMSG-26659]
    Action.c(38): Detected non-resource "http://192.168.20.61:8080/attachment.jsp?rowid=171791&tableId=1314" in "http://192.168.20.61:8080/jbpmjsp/dbrw/dbrw_lcrw_gcqzd_add.jsf"          [MsgId: MMSG-26574]
    Action.c(38): web_submit_data("dbrw_lcrw_gcqzd_add.jsf") was successful, 83745 body bytes, 846 header bytes, 208 chunking overhead bytes          [MsgId: MMSG-26385]
    Action.c(84): Notify: Transaction "?′DD·¢?e2ù×÷" ended with "Pass" status (Duration: 0.3682).
    Ending action Action.
    有的地方有乱码,是起的事物名称(中文)所以贴出来显示的是乱码
    回复 支持 反对

    使用道具 举报

    该用户从未签到

    7#
    发表于 2010-11-3 14:02:59 | 只看该作者
    "Name=name_", "Value=gcqzd", ENDITEM,

    改下name的值试试
    回复 支持 反对

    使用道具 举报

    本版积分规则

    关闭

    站长推荐上一条 /1 下一条

    小黑屋|手机版|Archiver|51Testing软件测试网 ( 沪ICP备05003035号 关于我们

    GMT+8, 2024-11-14 13:51 , Processed in 0.070273 second(s), 27 queries .

    Powered by Discuz! X3.2

    © 2001-2024 Comsenz Inc.

    快速回复 返回顶部 返回列表