C++ for dummy question:
I'm trying to connect to Firebird with the following code:
I have set INCLUDE path (@Tools/Options) with the location of Firebird\INCLUDE folder.
My brain's having cramps on this problem.
TIA
I'm trying to connect to Firebird with the following code:
Code:
#include "stdafx.h"
#include <ibase.h>
int main(int argc, char* argv[])
{
char dpb[24] = {isc_dpb_version1, isc_dpb_num_buffers, 1, 90,
isc_dpb_user_name, 6, 'S','Y','S','D','B','A',
isc_dpb_password, 9, 'm','a','s','t','e','r','k','e','y'};
ISC_STATUS_ARRAY status;
isc_db_handle hDb = 0L;
char * pdbname = "d:/firebird/mydata.fdb";
isc_attach_database(status, strlen(pdbname), pdbname, &hDb, 24, dpb);
if(status[0] == 1)
printf("Error occurred\n");
printf("Hello World!\n");
return 0;
}
My brain's having cramps on this problem.
TIA