当前位置:首页
开发技术指南» 文章正文
    引言:

    摘要: 运行总是提示如下信息 [error] unit1.pas(25): unsatisfied forward or external declaration: tform1.profitcount 代码如下:请帮忙改改! unit unit1; interface uses windows, messages, sysutils, variants, classes, graphics, c......
 ·怎么把字符串转化成逻辑值    »显示摘要«
    摘要: 在存储过程中想临时加入一个逻辑表达式: select * from tb_customer where c_no=010101 and @灵活的高级条件 @灵活的高级条件 一般是“ 名称 like %刘% and 出生日期<20” ......


查询记录 转换 问题

查一表记录  
  当字段   Sex   为   1   是   结果变成   男   当为   0   时   结果变成女。。  
  Sql   怎么写...  
   
  谢谢

NO.1   作者: fengfangfang

select     *,case   sex   when   1   then   男   else   女   end     from   test

NO.2   作者: 631799

select   [sex]=case   when   sex=1   then   男   else   女   end,*   from   tb

NO.3   作者: txqgyf

select   sex=case   when   sex=1   then   男else   女  
    from   table


 ·关于数据类型    »显示摘要«
    摘要: 不知那一种类型 是只有日期没能时间的. 我试过smalldatetime 都 不行. ......
» 本期热门文章:

©2000-2007 All Rights Reserved. 最佳浏览:1024X768 MSIE