Path: csiph.com!usenet.pasdenom.info!weretis.net!feeder4.news.weretis.net!feeder2.ecngs.de!ecngs!feeder.ecngs.de!news.osn.de!diablo2.news.osn.de!news.belwue.de!rz.uni-karlsruhe.de!feed.news.schlund.de!schlund.de!news.online.de!not-for-mail From: "Theo Tress" Newsgroups: comp.lang.basic.visual.misc Subject: Re: Trying to pass a date as a parameter to my Acces query in VBA code Date: Thu, 7 Jun 2012 11:31:08 +0200 Organization: 1&1 Internet AG Lines: 19 Message-ID: References: NNTP-Posting-Host: dslb-094-217-086-012.pools.arcor-ip.net Mime-Version: 1.0 Content-Type: text/plain; format=flowed; charset="iso-8859-1"; reply-type=original Content-Transfer-Encoding: 7bit X-Trace: online.de 1339068211 5911 94.217.86.12 (7 Jun 2012 11:23:31 GMT) X-Complaints-To: abuse@einsundeins.com NNTP-Posting-Date: Thu, 7 Jun 2012 11:23:31 +0000 (UTC) In-Reply-To: X-Priority: 3 X-MSMail-Priority: Normal X-Newsreader: Microsoft Windows Mail 6.0.6002.18197 X-MimeOLE: Produced By Microsoft MimeOLE V6.0.6002.18463 Xref: csiph.com comp.lang.basic.visual.misc:1187 Without entering your code deeper, think.. >"SELECT * INTO tbl" & p_sQueryName & " FROM ... it's never a good idea to insert variables directly, because there might be blanks or other unallowed characters in the variable, so simply use somewhat like "SELECT * INTO " & fnConvert(p_sQueryName).... where fnConvert adds chr$(34) around the variable's content. You might just try this before digging deeper. Regards, TT