'IT_Expert/WebProgramming'에 해당되는 글 22

  1. 2009.03.23 ASP RecordCount -1 표기될 때
IT_Expert/WebProgramming | Posted by 낫기법필 2009. 3. 23. 16:33

ASP RecordCount -1 표기될 때

출처 : http://cafe.naver.com/hasware.cafe?iframe_url=/ArticleRead.nhn%3Farticleid=49


Set rsCnt = Server.CreateObject("ADODB.RecordSet")
rsCnt.open SQL_SUB,db,3,1,1

뭐 보통 위와 같이 작성을 하게 되면 되어야 하는데 .. 안된다는 것이다.

그래서 아래를 추가 한다.

Set rsCnt = Server.CreateObject("ADODB.RecordSet")

rsCnt.CursorLocation = 3
rsCnt.CursorType = 3
rsCnt.LockType = 3

rsCnt.open SQL_SUB,db

rsCnt.RecordCount   우와 드디어 출력이 되는 구나

[펌] http://taizyeris.tistory.com/219

========================================
아는 것임에도 맨날 가끔씩 접할 때마다 까먹는다.. ㅡㅡ;