具体是这样:
   table表中的出生日期是字符型的,比如:“19780101”能不能这样写:
   select t.file form table t where mid(t.birthday,1,4)='1978'或者这样写:
   select t.file form table t where clng(t.birthday)>1978 and clng(t.birthday)<1990我在asp中用第二中写法,显示错误,称找不到列

解决方案 »

  1.   

    没有mid    ->substr
    没有clng   你这是啥意思?
      

  2.   

    clng是javascript的函数吧, 怎么能在SQL中用呢
    ------------------------------------------------
    SELECT t.file
    FROM table1 t
    WHERE to_number(t.birthday) > 19780000
    AND to_number(t.birthday) < 19909999
      

  3.   

    谢谢,我刚开始学习oracle,还不太懂,以前一直用asp+access和asp+sql server做应用,在那里边可以用这些函数!