Re: Session Variables (again!)

Tech-Archive recommends: Fix windows errors by optimizing your registry

From: Ray (ray_at_ray.com)
Date: 05/23/04


Date: Sun, 23 May 2004 21:13:44 +0000 (UTC)

Identifier is an AutoNumber field. However, with that I get this error

Server error: Unable to retrieve schema information from the query:

SELECT * FROM tblMember where Identifier= " & Session("Identifier")

against a database using the connection string

DRIVER={Microsoft Access Driver (*.mdb)};DBQ=URL=fpdb/books.mdb.

The following error message comes from the database driver software; it may
appear in a different language depending on how the driver is configured.
-------------------------------------------------------
[Microsoft][ODBC Microsoft Access Driver] Syntax error (missing operator) in
query expression 'Identifier= [ & Session(]Identifier")'.

Source: Microsoft OLE DB Provider for ODBC Drivers
Number: -2147217900 (0x80040e14)

"Thomas A. Rowe" <tarowe@mvps.org> wrote in message
news:ehR9HkOQEHA.3012@tk2msftngp13.phx.gbl...
> What type of field is Identifier, text or autonumber or number.
>
> If "Identifier" is a text field use:
>
> SELECT * FROM tblMember where Identifier= '" & Session("Identifier") & "'
>
> If "Identifier" is a number or autonumber field use:
>
> SELECT * FROM tblMember where Identifier= " & Session("Identifier")
>
> --
> ==============================================
> Thomas A. Rowe (Microsoft MVP - FrontPage)
> WEBMASTER Resources(tm)
> http://www.ycoln-resources.com
> FrontPage Resources, WebCircle, MS KB Quick Links, etc.
> ==============================================
> To assist you in getting the best answers for FrontPage support see:
> http://www.net-sites.com/sitebuilder/newsgroups.asp
>
> "Ray" <ray@ray.com> wrote in message
news:c8ql50$7b5$1@hercules.btinternet.com...
> > Having been shown how to pass Session Variables across pages, I tried to
run
> > a query with the Session Variable as a parameter, but I didn't work. The
> > query is "SELECT * FROM tblMember where Identifier= ::Identifier::",
where
> > Identifier is the passed variable. It appears on the page correctly as a
> > number, and the box it appears in is called Identifier.
> >
> >
>
>



Relevant Pages

  • Importing from another database on same server using SQL Server Express
    ... I haven't been able to solve this likely syntax problem despite ... otherwise identical database into a more recent copy. ... I tried a few different query techniques as suggested in historical ... The multi-part identifier "OldDatabase.dbo.Table.PK" could not be ...
    (microsoft.public.sqlserver.msde)
  • Re: Update Query - Want to Update Only the First Match
    ... You have CMSTRAN table in both the main query and in the subquery, ... FROM CORISTRAN INNER JOIN CMSTRAN ON CMSTRAN.ROCREF = CORISTRAN. ... TranID (to hold Table B transaction identifier) ...
    (microsoft.public.access.queries)
  • Re: Excel Calcs in Access
    ... to sort the records into the order you need. ... certain that the query will find the correct "cell above" (i.e. the ... section identifier which is in the same column as the "D"s. ...
    (microsoft.public.access.modulesdaovba)
  • Re: Importing from another database on same server using SQL Server Express
    ... otherwise identical database into a more recent copy. ... I tried a few different query techniques as suggested in historical ... The multi-part identifier "OldDatabase.dbo.Table.PK" could not be ... to another database within the same server instance or otherwise. ...
    (microsoft.public.sqlserver.msde)
  • Re: Study UID in series response?
    ... when I'm doing a C-Find query at series level, ... study UID in the response identifier? ... keys at higher levels...". ...
    (comp.protocols.dicom)