Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Westi on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Data Reports through ODBC

Status
Not open for further replies.

Cyberseduct

Programmer
May 25, 2001
6
MU
I am using vb6 Data Report using an ODBC connection. My reports that are static (i.e, Reports generated directly from the database without passing any parameter) is OK. The problem is when I try to insert a parameter in the SQL builder it is not being accepted. The same thing works correctly with a connection string but not with an odbc connection. What may be the problem? How can i overcome this as the reports will be on network?

thanks for your help
 
I have done several reports using variables myself. this is how I basically set uyp my database queries:

adoRecord.Source = &quot;SELECT * FROM Table WHERE Datafield = &quot; & variable1 & &quot; AND Date <= #&quot; & datevariable & &quot;#&quot;

that of course is just an example of an SQL query. hope this helps a bit Best Regards and many Thanks!
Michael G. Bronner X-)

&quot;Beer is proof that God wants us to be happy.&quot; Ben Franklin
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top