

<rss version="2.0"
	xmlns:atom="http://www.w3.org/2005/Atom" 
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:admin="http://webns.net/mvcb/"
	xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#">
		
	<channel>
		<title>RSS Feeds :: DEVPPL - Forums > Visual Basic Forum : Topics : Problem with WHERE in SQL only in code</title>
	<!--<atom:link href="http://www.devppl.com/forum" rel="self" type="application/rss+xml" />-->
		<description>TOGETHER WE ARE THE BEST</description>
		<link>http://www.devppl.com/forum</link>
		<language>en-gb</language>
		<pubDate>Tue, 17 Aug 2004 14:07:13 +0100</pubDate>
		<lastBuildDate>Sat, 21 Nov 2009 12:29:28 +0000</lastBuildDate>
		<docs>http://blogs.law.harvard.edu/tech/rss</docs>
		<generator>MSSTI v0.0.1 - (C) 2008 leviatan21 - http://www.mssti.com/</generator>
		<copyright>Copyright : (c) RSS Feeds :: DEVPPL - Tue, 17 Aug 2004 14:07:13 +0100</copyright>
		<dc:creator>webmaster@devppl.com (DEVPPL)</dc:creator>

		<image>
			<title>RSS Feeds :: DEVPPL - Forums > Visual Basic Forum : Topics : Problem with WHERE in SQL only in code</title>
			<url>http://www.devppl.com/forum/styles/DEVPPL/imageset/site_logo.gif</url>
			<link>http://www.devppl.com/forum</link>
		</image>
		<ttl>60</ttl>
		
		<item>
			<title>Problem with WHERE in SQL only in code</title>
			<link>http://www.devppl.com/forum/./viewtopic.php?p=50957#p50957</link>
				<description><![CDATA[  Hi Everyone,  Thanks ahead of time for the help.<br /><br />My Code:<br
/><div class="codetitle"><b>Code:</b></div><div class="codecontent">&nbsp;
&nbsp; &nbsp;Private Sub btnExport_Click(ByVal sender As System.Object,
ByVal e As System.EventArgs) Handles btnExport.Click<br />&nbsp; &nbsp;
&nbsp; &nbsp; Dim Conn As New ADODB.Connection<br />&nbsp; &nbsp; &nbsp;
&nbsp; Dim Rec As New ADODB.Recordset<br />&nbsp; &nbsp; &nbsp; &nbsp; Dim
SQLqry As String<br /><br />&nbsp; &nbsp; &nbsp; &nbsp; On Error GoTo
btnExport_Error<br /><br />&nbsp; &nbsp; &nbsp; &nbsp; 'Build SQL Query<br
/>&nbsp; &nbsp; &nbsp; &nbsp; SQLqry = "SELECT&nbsp; &nbsp;
&nbsp;ClockData.&#91;Date&#93;, Employee.FirstName, Employee.LastName,
ClockData.TimeIn, ClockData.TimeOut, ClockData.Comment" & _<br />&nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;" FROM (Employee
INNER JOIN ClockData ON ClockData.EmployeeNumber =
Employee.EmployeeNumber)" & _<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp;" WHERE (ClockData.&#91;Date&#93; <= #4/2/2009#)
AND (ClockData.&#91;Date&#93; >= #4/1/2009#) AND (Employee.FirstName =
'Shai')"<br /><br />&nbsp; &nbsp; &nbsp; &nbsp; Debug.Print(SQLqry)<br
/>&nbsp; &nbsp; &nbsp; &nbsp; 'Open connection to database delared on
Form1_Activated<br />&nbsp; &nbsp; &nbsp; &nbsp; Conn.ConnectionString
=</div>...<p>Statistics : Posted by <a href="http://www.devppl.com/forum/memberlist.php?mode=viewprofile&amp;u=39003">shaiss</a> &bull; on Wed Apr 08, 2009 7:09 pm &bull; Replies 0 &bull; Views 69</p><hr />]]></description>
					<content:encoded><![CDATA[  Hi Everyone,  Thanks ahead of time for the help.<br /><br />My Code:<br
/><div class="codetitle"><b>Code:</b></div><div class="codecontent">&nbsp;
&nbsp; &nbsp;Private Sub btnExport_Click(ByVal sender As System.Object,
ByVal e As System.EventArgs) Handles btnExport.Click<br />&nbsp; &nbsp;
&nbsp; &nbsp; Dim Conn As New ADODB.Connection<br />&nbsp; &nbsp; &nbsp;
&nbsp; Dim Rec As New ADODB.Recordset<br />&nbsp; &nbsp; &nbsp; &nbsp; Dim
SQLqry As String<br /><br />&nbsp; &nbsp; &nbsp; &nbsp; On Error GoTo
btnExport_Error<br /><br />&nbsp; &nbsp; &nbsp; &nbsp; 'Build SQL Query<br
/>&nbsp; &nbsp; &nbsp; &nbsp; SQLqry = "SELECT&nbsp; &nbsp;
&nbsp;ClockData.&#91;Date&#93;, Employee.FirstName, Employee.LastName,
ClockData.TimeIn, ClockData.TimeOut, ClockData.Comment" & _<br />&nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;" FROM (Employee
INNER JOIN ClockData ON ClockData.EmployeeNumber =
Employee.EmployeeNumber)" & _<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp;" WHERE (ClockData.&#91;Date&#93; <= #4/2/2009#)
AND (ClockData.&#91;Date&#93; >= #4/1/2009#) AND (Employee.FirstName =
'Shai')"<br /><br />&nbsp; &nbsp; &nbsp; &nbsp; Debug.Print(SQLqry)<br
/>&nbsp; &nbsp; &nbsp; &nbsp; 'Open connection to database delared on
Form1_Activated<br />&nbsp; &nbsp; &nbsp; &nbsp; Conn.ConnectionString
=</div>...]]></content:encoded>
					<category domain="http://www.devppl.com/forum/viewforum.php?f=57"><![CDATA[Visual Basic Forum]]></category>
			<dc:creator><![CDATA[39003]]></dc:creator>
			<dc:date>2009-04-08T19:09:25+01:00</dc:date>
			<guid isPermaLink="false">http://www.devppl.com/forum/./viewtopic.php?p=50957#p50957</guid>
		</item>
	
	</channel>
</rss>