D7net
Home
Console
Upload
information
Create File
Create Folder
About
Tools
:
/
proc
/
self
/
root
/
usr
/
share
/
doc
/
unixODBC
/
doc
/
ProgrammerManual
/
Tutorial
/
Filename :
close.html
back
Copy
<HTML> <HEAD> <META HTTP-EQUIV="Content-Type" content="text/html; charset=iso-8859-1"> <TITLE>Closing a connection</TITLE> <LINK REL="Stylesheet" href="odbc.css"> </HEAD> <BODY bgcolor="white"> <table width="90%" cols="3" border="0"> <TR> <TD colspan="3" class="big">Closing a connection</TD> </TR> <TR> <TD colspan="3"><P>Before your program terminates you need to free all resources you have allocated. If you checked the source on the previous page, you certainly spotted <CODE><A HREF="gloss.html#free">SQLFreeHandle</A></CODE>. This function must be used to free each allocated handle. It expects a parameter which states the type of the handle to be freed and the handle itself. So if you want to free an environment handle you should call (in our example program):</P> <CODE> SQLFreeHandle(SQL_HANDLE_ENV, V_OD_Env); </CODE> <P> Before you free any handle make sure that it is no longer needed, wouldn't be funny, if you released to connection handle but forgot to close the connection ;)</P> <P> And if you want to close a connection you need <CODE><A HREF="gloss.html#clos">SQLDisconnect</A></CODE>. This closes the connection associated with the connection handle offered as argument to <CODE>SQLDisconnect</CODE>. In our programm we need to call:</P> <CODE> SQLDisconnect(V_OD_hdbc); </CODE> <P> If you need source code, please have a look <A HREF="conne.html#list">here</A>.</P> </TD> </TR> </TABLE> </BODY> </HTML>
Name
Size
Last Modified
Owner
Permissions
Actions
close.html
1.441
KB
January 06 2014 9:37:01
root
0644
conne.html
4.916
KB
January 06 2014 9:37:01
root
0644
dsn.html
2.59
KB
January 06 2014 9:37:01
root
0644
gloss.html
19.643
KB
January 06 2014 9:37:01
root
0644
index.html
0.271
KB
January 06 2014 9:37:01
root
0644
intro.html
2.318
KB
January 06 2014 9:37:01
root
0644
navi.html
0.999
KB
January 06 2014 9:37:01
root
0644
odbc.css
6.642
KB
January 06 2014 9:37:01
root
0755
query.html
3.516
KB
January 06 2014 9:37:01
root
0644
resul.html
6.793
KB
January 06 2014 9:37:01
root
0644
2017 © D7net | D704T team