ProC 연결 Oracle 코드

500 단어 ProC잇닿다Oracle

int connectDb()
{
EXEC SQL BEGIN DECLARE SECTION;
char username[20];
char password[20];
char connect_string[20];
EXEC SQL END DECLARE SECTION;

strcpy(username,"lbc1");
strcpy(password,"lbtux");
strcpy(connect_string, "lbc1");

EXEC SQL CONNECT :username IDENTIFIED BY :password USING :connect_string;
if ( sqlca.sqlcode < 0 )
{
return -1;
}
}

좋은 웹페이지 즐겨찾기