Imran Aziz
June 10th, 1999, 02:26 AM
Hello all,
When I try to configure DSN by SQLConfigDataSource and give UID=sa and PWD=xxx as parameters it gives invalid parameter value pair, otherwise it creates the DSN,what might be the problem,Has anyone face the same problem.
Code is
char chr='\0';
char pszAttributes[400];
sprintf( pszAttributes,
"DSN=My Bogus DS%cServer=bottles%cUID=sa%cPWD=%cDatabase=pubs%cUseProcForPrepare=yes%c%c",chr,chr,chr,chr,chr,chr,chr );
retcode = SQLConfigDataSource(NULL,ODBC_ADD_SYS_DSN,"SQL Server",pszAttributes);
Please Respond,
Regards
Imran.
When I try to configure DSN by SQLConfigDataSource and give UID=sa and PWD=xxx as parameters it gives invalid parameter value pair, otherwise it creates the DSN,what might be the problem,Has anyone face the same problem.
Code is
char chr='\0';
char pszAttributes[400];
sprintf( pszAttributes,
"DSN=My Bogus DS%cServer=bottles%cUID=sa%cPWD=%cDatabase=pubs%cUseProcForPrepare=yes%c%c",chr,chr,chr,chr,chr,chr,chr );
retcode = SQLConfigDataSource(NULL,ODBC_ADD_SYS_DSN,"SQL Server",pszAttributes);
Please Respond,
Regards
Imran.