Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

SQLBindParameter question..

Posted on 1998-10-27
1
Medium Priority
?
260 Views
Last Modified: 2013-11-20
I found SQLBindParameter is very difficult to use, even I read all help files, I still could not be able to use it. Could anyone give me some helpful tips about using this API please.
0
Comment
Question by:stephenkong
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
1 Comment
 

Accepted Solution

by:
jinda earned 0 total points
ID: 1323905
Example:

void MyFunction( void* Value, long lSize )
{
SDWORD cb_value;
CString strStmt;
long lID = 101;

strStmt.Format( "insert into myTable"
            " ( ID, BINARYVALUE )"
            " values"
            " (%ld, ?)",
            lID );


cb_value = lSize;

nRc = SQLBindParameter( hStmt, 1, SQL_PARAM_INPUT,
            SQC_C_BINARY,
            SQL_BINARY,
            lSize, 0, Value, 0, &cb_value);

nRc = SQLExecDirect( hStmt, (unsigned char*)(LPCSTR)strStmt, SQL_NTS);

..
}


0

Featured Post

Tech or Treat!

Submit an article about your scariest tech experience—and the solution—and you’ll be automatically entered to win one of 4 fantastic tech gadgets.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction: Database storage, where is the exe actually on the disc? Playing a game selected randomly (how to generate random numbers).  Error trapping with try..catch to help the code run even if something goes wrong. Continuing from the seve…
If you use Adobe Reader X it is possible you can't open OLE PDF documents in the standard. The reason is the 'save box mode' in adobe reader X. Many people think the protected Mode of adobe reader x is only to stop the write access. But this fe…
This video will show you how to get GIT to work in Eclipse.   It will walk you through how to install the EGit plugin in eclipse and how to checkout an existing repository.
In this video, Percona Solution Engineer Rick Golba discuss how (and why) you implement high availability in a database environment. To discuss how Percona Consulting can help with your design and architecture needs for your database and infrastr…

610 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question