QUERYING PROBLEM

QUERYING PROBLEM

am 09.03.2005 07:15:03 von krisrajz

When I execute a query(written in MS-ACCESS) on an MS-ACCESS database it
retrieves records, and I if do the same through ASP-ADO I got either bof of
eof is true error.

Here's the query

select * from placingdrawing where JOB_CODE="P-82-2004" and TITLE LIKE
"*AREA A*"

Any fix?

TIA
RAJ.

Re: QUERYING PROBLEM

am 09.03.2005 07:24:07 von Jason Brown

couple of possibilities.

use % as a wildcard in place of * (in the LIKE clause)
use ' instead of " for your criteria delimiters

give those a try and report back


--
Jason Brown
Microsoft GTSC, IIS

This posting is provided "AS IS" with no warranties, and confers no rights.


"krisrajz" wrote in message
news:E2DCC1C6-4CFB-4F6F-91C9-FB19F6BCE0C3@microsoft.com...
> When I execute a query(written in MS-ACCESS) on an MS-ACCESS database it
> retrieves records, and I if do the same through ASP-ADO I got either bof
> of
> eof is true error.
>
> Here's the query
>
> select * from placingdrawing where JOB_CODE="P-82-2004" and TITLE LIKE
> "*AREA A*"
>
> Any fix?
>
> TIA
> RAJ.

Re: QUERYING PROBLEM

am 09.03.2005 07:41:02 von krisrajz

Thanx indeed and I'm really surprised about using * in place of %.

Could you please justify why should we replace * by %

"Jason Brown [MSFT]" wrote:

> couple of possibilities.
>
> use % as a wildcard in place of * (in the LIKE clause)
> use ' instead of " for your criteria delimiters
>
> give those a try and report back
>
>
> --
> Jason Brown
> Microsoft GTSC, IIS
>
> This posting is provided "AS IS" with no warranties, and confers no rights.
>
>
> "krisrajz" wrote in message
> news:E2DCC1C6-4CFB-4F6F-91C9-FB19F6BCE0C3@microsoft.com...
> > When I execute a query(written in MS-ACCESS) on an MS-ACCESS database it
> > retrieves records, and I if do the same through ASP-ADO I got either bof
> > of
> > eof is true error.
> >
> > Here's the query
> >
> > select * from placingdrawing where JOB_CODE="P-82-2004" and TITLE LIKE
> > "*AREA A*"
> >
> > Any fix?
> >
> > TIA
> > RAJ.
>
>
>

Re: QUERYING PROBLEM

am 09.03.2005 07:46:09 von Jason Brown

That's just the ADO way. I'm not sure of the formal reason but I guess the
ADO pre-parser may have some issues with the clash between the * in a SELECT
clause and a * in a wildcard.


--
Jason Brown
Microsoft GTSC, IIS

This posting is provided "AS IS" with no warranties, and confers no rights.

"krisrajz" wrote in message
news:D91DFD88-D712-4109-AF73-46D81D6D971B@microsoft.com...
> Thanx indeed and I'm really surprised about using * in place of %.
>
> Could you please justify why should we replace * by %
>
> "Jason Brown [MSFT]" wrote:
>
>> couple of possibilities.
>>
>> use % as a wildcard in place of * (in the LIKE clause)
>> use ' instead of " for your criteria delimiters
>>
>> give those a try and report back
>>
>>
>> --
>> Jason Brown
>> Microsoft GTSC, IIS
>>
>> This posting is provided "AS IS" with no warranties, and confers no
>> rights.
>>
>>
>> "krisrajz" wrote in message
>> news:E2DCC1C6-4CFB-4F6F-91C9-FB19F6BCE0C3@microsoft.com...
>> > When I execute a query(written in MS-ACCESS) on an MS-ACCESS database
>> > it
>> > retrieves records, and I if do the same through ASP-ADO I got either
>> > bof
>> > of
>> > eof is true error.
>> >
>> > Here's the query
>> >
>> > select * from placingdrawing where JOB_CODE="P-82-2004" and TITLE LIKE
>> > "*AREA A*"
>> >
>> > Any fix?
>> >
>> > TIA
>> > RAJ.
>>
>>
>>

EOP

am 09.03.2005 09:07:02 von krisrajz

Thanx much.
RAJ.

"Jason Brown [MSFT]" wrote:

> That's just the ADO way. I'm not sure of the formal reason but I guess the
> ADO pre-parser may have some issues with the clash between the * in a SELECT
> clause and a * in a wildcard.
>
>
> --
> Jason Brown
> Microsoft GTSC, IIS
>
> This posting is provided "AS IS" with no warranties, and confers no rights.
>
> "krisrajz" wrote in message
> news:D91DFD88-D712-4109-AF73-46D81D6D971B@microsoft.com...
> > Thanx indeed and I'm really surprised about using * in place of %.
> >
> > Could you please justify why should we replace * by %
> >
> > "Jason Brown [MSFT]" wrote:
> >
> >> couple of possibilities.
> >>
> >> use % as a wildcard in place of * (in the LIKE clause)
> >> use ' instead of " for your criteria delimiters
> >>
> >> give those a try and report back
> >>
> >>
> >> --
> >> Jason Brown
> >> Microsoft GTSC, IIS
> >>
> >> This posting is provided "AS IS" with no warranties, and confers no
> >> rights.
> >>
> >>
> >> "krisrajz" wrote in message
> >> news:E2DCC1C6-4CFB-4F6F-91C9-FB19F6BCE0C3@microsoft.com...
> >> > When I execute a query(written in MS-ACCESS) on an MS-ACCESS database
> >> > it
> >> > retrieves records, and I if do the same through ASP-ADO I got either
> >> > bof
> >> > of
> >> > eof is true error.
> >> >
> >> > Here's the query
> >> >
> >> > select * from placingdrawing where JOB_CODE="P-82-2004" and TITLE LIKE
> >> > "*AREA A*"
> >> >
> >> > Any fix?
> >> >
> >> > TIA
> >> > RAJ.
> >>
> >>
> >>
>
>
>

Re: QUERYING PROBLEM

am 09.03.2005 16:11:27 von ten.xoc

> Thanx indeed and I'm really surprised about using * in place of %.

* is Access' proprietary way of handling wildcards. All other products I've
used (and not just Microsoft's products) use % in place of *.

Re: QUERYING PROBLEM

am 09.03.2005 16:53:46 von Mark Schupp

The formal reason is the "%" is the standard SQL multi-character wildcard
character. MS Access uses the non-standard "*". If I recall correctly "_" is
the standard single character wildcard character vs Access's "?".

--
--Mark Schupp
Head of Development
Integrity eLearning
www.ielearning.com


"Jason Brown [MSFT]" wrote in message
news:OMUx2OHJFHA.1304@TK2MSFTNGP09.phx.gbl...
> That's just the ADO way. I'm not sure of the formal reason but I guess the
> ADO pre-parser may have some issues with the clash between the * in a
> SELECT clause and a * in a wildcard.
>
>
> --
> Jason Brown
> Microsoft GTSC, IIS
>
> This posting is provided "AS IS" with no warranties, and confers no
> rights.
>
> "krisrajz" wrote in message
> news:D91DFD88-D712-4109-AF73-46D81D6D971B@microsoft.com...
>> Thanx indeed and I'm really surprised about using * in place of %.
>>
>> Could you please justify why should we replace * by %
>>
>> "Jason Brown [MSFT]" wrote:
>>
>>> couple of possibilities.
>>>
>>> use % as a wildcard in place of * (in the LIKE clause)
>>> use ' instead of " for your criteria delimiters
>>>
>>> give those a try and report back
>>>
>>>
>>> --
>>> Jason Brown
>>> Microsoft GTSC, IIS
>>>
>>> This posting is provided "AS IS" with no warranties, and confers no
>>> rights.
>>>
>>>
>>> "krisrajz" wrote in message
>>> news:E2DCC1C6-4CFB-4F6F-91C9-FB19F6BCE0C3@microsoft.com...
>>> > When I execute a query(written in MS-ACCESS) on an MS-ACCESS database
>>> > it
>>> > retrieves records, and I if do the same through ASP-ADO I got either
>>> > bof
>>> > of
>>> > eof is true error.
>>> >
>>> > Here's the query
>>> >
>>> > select * from placingdrawing where JOB_CODE="P-82-2004" and TITLE LIKE
>>> > "*AREA A*"
>>> >
>>> > Any fix?
>>> >
>>> > TIA
>>> > RAJ.
>>>
>>>
>>>
>
>

Re: QUERYING PROBLEM

am 09.03.2005 17:27:46 von ten.xoc

> If I recall correctly "_" is the standard single character wildcard
character vs Access's "?".

That's correct...

Re: QUERYING PROBLEM

am 09.03.2005 18:10:08 von reb01501

I always assumed that they were used in Jet because the developers assumed
that DOS users would be more comfortable using the DOS wildcards rather than
learning to use the ODBC wildcards.

Incidently, ADO requires the use of the ODBC wildcards. It is up to the
providers to translate them into the version-specific characters.

Bob Barrows
Mark Schupp wrote:
> The formal reason is the "%" is the standard SQL multi-character
> wildcard character. MS Access uses the non-standard "*". If I recall
> correctly "_" is the standard single character wildcard character vs
> Access's "?".
>
> --
> --Mark Schupp
> Head of Development
> Integrity eLearning
> www.ielearning.com
>
>
> "Jason Brown [MSFT]" wrote in message
> news:OMUx2OHJFHA.1304@TK2MSFTNGP09.phx.gbl...
>> That's just the ADO way. I'm not sure of the formal reason but I
>> guess the ADO pre-parser may have some issues with the clash between
>> the * in a SELECT clause and a * in a wildcard.
>>
>>
>> --
>> Jason Brown
>> Microsoft GTSC, IIS
>>
>> This posting is provided "AS IS" with no warranties, and confers no
>> rights.
>>
>> "krisrajz" wrote in message
>> news:D91DFD88-D712-4109-AF73-46D81D6D971B@microsoft.com...
>>> Thanx indeed and I'm really surprised about using * in place of %.
>>>
>>> Could you please justify why should we replace * by %
>>>
>>> "Jason Brown [MSFT]" wrote:
>>>
>>>> couple of possibilities.
>>>>
>>>> use % as a wildcard in place of * (in the LIKE clause)
>>>> use ' instead of " for your criteria delimiters
>>>>
>>>> give those a try and report back
>>>>
>>>>
>>>> --
>>>> Jason Brown
>>>> Microsoft GTSC, IIS
>>>>
>>>> This posting is provided "AS IS" with no warranties, and confers no
>>>> rights.
>>>>
>>>>
>>>> "krisrajz" wrote in message
>>>> news:E2DCC1C6-4CFB-4F6F-91C9-FB19F6BCE0C3@microsoft.com...
>>>>> When I execute a query(written in MS-ACCESS) on an MS-ACCESS
>>>>> database it
>>>>> retrieves records, and I if do the same through ASP-ADO I got
>>>>> either bof
>>>>> of
>>>>> eof is true error.
>>>>>
>>>>> Here's the query
>>>>>
>>>>> select * from placingdrawing where JOB_CODE="P-82-2004" and TITLE
>>>>> LIKE "*AREA A*"
>>>>>
>>>>> Any fix?
>>>>>
>>>>> TIA
>>>>> RAJ.

--
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.