테이블 스키마를 dbo로 변경

MS-SQL 2013. 4. 14. 00:10 Posted by Dayis

mssql 2005 이전 버전
exec sp_changeobjectowner '유저명.objects명(테이블 또는 프로시져)','dbo'

mssql 2005
alter schema dbo transfer 유저명.objects명(테이블 또는 프로시져)

예)
snjgame이 소유한 aaa테이블, bbb프로시져

mssql 2005이전

exec sp_changeobjectowner 'snjgame.aaa','dbo'
exec sp_changeobjectowner 'snjgame.bbb','dbo'

mssql 2005

alter schema dbo transfer SagoAdmin.UP_NT_SAGO_CHARGEINFO_CANCEL;

'MS-SQL' 카테고리의 다른 글

중복 데이터 삭제  (0) 2014.03.03
전체 테이블의 모든 인덱스 조회  (0) 2013.01.03
MS-SQL 인덱스 조각모음  (0) 2013.01.03
MS-SQL 전체 테이블 크기 조회 (용량순, 테이블이름순)  (0) 2012.08.16
declare cursor  (0) 2012.06.12

URL 정보 확인

JAVASCRIPT 2013. 4. 11. 17:17 Posted by Dayis

<html>

<head>

<script type="text/javascript">

window.onload = function () {

 var hostname = window.location.hostname; 

 var href = window.location.href; 

 var host = window.location.host; 

 var port = window.location.port; 

 var pathname = window.location.pathname; 

 var search = window.location.search; 

 var protocoal = window.location.protocol;

 var _str = "hostname:" + hostname + "<br>";

 _str += "href:" + href + "<br>";

 _str += "host:" + host + "<br>";

 _str += "port:" + port + "<br>";

 _str += "pathname:" + pathname + "<br>";

 _str += "search:" + search + "<br>";

 _str += "protocoal:" + protocoal + "<br>";

 

 var hostname = window.location.hostname; 

 var _host;

 if (hostname.indexOf(".") > 0) {

  _host = hostname.split(".")[0];

 } else {

  _host = hostname;

 }

 document.getElementById("tmpDiv").innerHTML = "host:" + _host + "<hr>" + _str;

}

</script>

</head>

<body>

 <div id="tmpDiv" name="tmpDiv">

 </div>

</body>

</html>

숫자만 입력가능

JAVASCRIPT 2013. 4. 3. 00:18 Posted by Dayis

.....................................................................................................................................................................................................................................................

function onlyNumber(event) {
    var key = window.event ? event.keyCode : event.which;    

    if ((event.shiftKey == false) && ((key  > 47 && key  < 58) || (key  > 95 && key  < 106)
    || key  == 35 || key  == 36 || key  == 37 || key  == 39  // 방향키 좌우,home,end  
    || key  == 8  || key  == 46 ) // del, back space
    ) {
        return true;
    }else {
        return false;
    }    
};


호출하는 부분은 아래와 같다

<input type="text" name="test" value="test" style="ime-mode:disabled;" onkeydown="return onlyNumber(event)">


테스트해볼수 있는 곳


http://jsfiddle.net/cJSkd/4/