语句如下:
  select * from A where TerminalID='0253' and InputTime between to_date('8:15:12,yyyy-mm-dd hh24:mi:ss) and to_date('16:15:12',yyyy-mm-dd hh24:mi:ss) order by InputTime, InCreate Asc
报错信息:
  不正常地定义参数对象。提供了不一致或不完整的信息。请问我错在哪儿?

解决方案 »

  1.   

    应该是这样吧。
    to_date('16:15:12','yyyy-mm-dd hh24:mi:ss')
      

  2.   

    date1:=formatdatetime('yyyy-mm-dd',pp.date);
    date2:=formatdatetime('yyyy-mm-dd',mm.date);queryStr:='select * FROM gz_last where c1 like ''%'+edit1.text+'%'' and to_char(d4,''yyyy-mm-dd'')='''+date1+'''';
    MyQueryPro;
      

  3.   

    queryStr:='select * FROM gz_last where c2 like ''%'+edit1.text+'%''  and to_char(d4,''yyyy-mm-dd'')>='''+date1+''' and to_char(d4,''yyyy-mm-dd'')<='''+date2+'''';
                     MyQueryPro;
      

  4.   

    呵呵,已经找到问题原因了,主要是时间那块
    应该是这样的to_date('2005-02-06 12:23:49','yyyy-mm-dd hh24:mi:ss')
    一开始我少加了日期,后面控制格式的那块又少加了单引号