Re: Too few parameters. Expected 1.
From: DVan (dthmtlgod_at_yahoo.com)
Date: 10/20/04
- Next message: Aaron [SQL Server MVP]: "Re: Too few parameters. Expected 1."
- Previous message: Bob Barrows [MVP]: "Re: Error message with sql statement"
- In reply to: Bob Barrows [MVP]: "Re: Too few parameters. Expected 1."
- Messages sorted by: [ date ] [ thread ]
Date: Wed, 20 Oct 2004 16:24:10 -0400
OK. Thanks, I will give it a try.
"Bob Barrows [MVP]" <reb01501@NOyahoo.SPAMcom> wrote in message
news:u4TS9GutEHA.2196@TK2MSFTNGP14.phx.gbl...
> DVan wrote:
> > Yes, that one.
> >
> > I added this per Ray, but still the same problem
> >
> > I added this to my webpage
> >
> > <SCRIPT LANGUAGE="JavaScript">
> > Function sIn(s)
> > sIn = "'" & Replace(s, "'", "''") & "'"
> > End Function
> > </SCRIPT>
> >
> >
> > Then changed the strSQL to
> >
> > strSQL = "SELECT * FROM Printers WHERE PrinterName = sIn(iSerial)"
> >
> >
> I repeat: Response.Write it and attempt to run the resulting statement
from
> the browser window in Access.
>
> You'll see the problem (I hope). You cannot debug a sql statement without
> knowing what it is. Knowing what the vbscript code that's supposed to
> generate it looks like will not help. You need to look at the resulting
> statement.
>
>
> Hint: Does your Printers table contain a field called "sIn(iSerial)"?
>
> Please consider using saved parameter queries as explained in the links in
> my previous message.
>
> Bob Barrows
> --
> Microsoft MVP -- ASP/ASP.NET
> Please reply to the newsgroup. The email account listed in my From
> header is my spam trap, so I don't check it very often. You will get a
> quicker response by posting to the newsgroup.
>
>
- Next message: Aaron [SQL Server MVP]: "Re: Too few parameters. Expected 1."
- Previous message: Bob Barrows [MVP]: "Re: Error message with sql statement"
- In reply to: Bob Barrows [MVP]: "Re: Too few parameters. Expected 1."
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|