select * from files where FDate='202-8-24' 或
select * from files where FDate=202-8-24
不能用#号

解决方案 »

  1.   

    select * from files where FDate='202-8-24' —》2002-8-24,你把日期写错了,如果是access数据库,#一定要加上
      

  2.   


    两位:还是出错啊,
    type mismatch in expression
      

  3.   

    xchunyu (大吊车) :
    完整地解决办法如下:(针对Paradox数据库)
    ******************************************************************
        DateSeparator:='/';//必不可少;
        with Query1 do
        begin
            close;
            SQL.Clear;
            s:= 'select * from flow where ckrq>'''+FormatDateTime  
                 ('mm/dd/yyyy',DateTimePicker1.DateTime)+'''';
            SQL.Add(s);
            open;
        end;
    ******************************************************************
    赶快试试吧!
    怎么样?欢呼吧!!!
    可以结账了吧!!
      

  4.   

    select * from files where FDate=#202-8-24# 在ACCESS是可以用的
    如果是在ORACLE里面的话
    上面都不对
    你自己查一下数据方面的书把
    我自己忘记了
    如果是SQL
    好象可以用
    select * from files where FDate=""'202-8-24'""
    在ORACLE里面好象用TODATE这个函数的