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

 

 ·怎么样在 nt中 添加一个xp的域    »显示摘要«
    摘要: 我在 nt知道怎么添加98的域 但怎么样在 nt中 添加一个xp的域? 谢谢!!! ......
    摘要: 打开窗口后,能不能让控件大小跟着窗口而变,怎么做才好呢? 最好成比例的改变! 盼高手赐教!谢谢。 ......


存储过程输入参数的问题

 
  存储过程有三个输入参数:部门编码,月份,日期。我想在存储过程里实现如果只输入部门参数,就取当天的月份和日期下的部门情况;也可以输入月份日期参数,查询某月某日的部门情况。存储过程里的输入参数的默认值只能为常量,而当天月份只能用函数变量表示,请问该怎么解决?

NO.1   作者: happydreamer

create   proc   名    
  @编码   char(10),  
  @月份   char(2),  
  @日期   char(2)  
  as  
   
  select   *   from   table   where   编码=@编码   and    
  month(date字段)=isnull(@月份,month(getdate()))   and   day(date字段)=isnull(@日期,day(getdate()))  
   
   
  名   10001,null,null  
  名   10001,04,06

NO.2   作者: pengdali

create   proc   名  
  @编码   int,  
  @月份   int=null,  
  @日期   int=null  
  as  
  select   *   from   表   where   @编码=编码   and   isnull(@月份,month(getdate())),isnull(@日期,day(getdate()))  
 


 ·一个问题在线等    »显示摘要«
    摘要: 我写了一段asp程序,不知道为什么出现错误.请大哥哥们帮帮我: <% dim adopenkeyset dim adlockoptimistic dim ipage adopenkeyset = 1 adlockoptimistic = 3 创建并打开 connection 对象。 set con = server.createobject("adodb.co......
» 本期热门文章:

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