Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- strconnection="hostaddr= machine_ip port=5432 user=postgres password=postgres dbname=postgres sslmode=require" ;
- ptr_db_conn = (_TCHAR*)LPCTSTR(strconnection);
- _conn = PQconnectdb(ptr_db_conn);
- if ( PQstatus(m_conn) != CONNECTION_OK)
- {
- char *msg = PQerrorMessage(m_conn);
- cleanUp(msg);
- }else{
- T_RESULT=TRUE;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement