PC Review


Reply
Thread Tools Rate Thread

Database results wizard and ChiliSoft ASP with MySQL database

 
 
=?Utf-8?B?Qm9i?=
Guest
Posts: n/a
 
      1st Apr 2005
I am using FrontPage 2002 on an ISP running MySQL database, ChiliSoft ASP and
Linux. I created an input form and a results table using the database
results wizard.

The wizard generates the SQL query as
fp_sQry="SELECT * FROM Reqmnts WHERE (Retailer = '::Retailer::')"
This is evaluated as bad SQL by MySQL (database results error message)
MySQL appears to be looking for the following code
="SELECT * FROM Reqmnts WHERE Retailer = "Retailer""
How do I get FrontPage to permit double quotes within quotes?
I have run a test by coding in
response.write Request.Form("Retailer") and the server writes out the name
entered in the Form box

If I use a custom query where I specify a specific value within the Column
Retailer, the the code is generated correctly and everything works.
For example,
fp_sQry="SELECT * FROM Reqmnts WHERE (Retailer = 'CVS')"
works correctly.

 
Reply With Quote
 
 
 
 
Thomas A. Rowe
Guest
Posts: n/a
 
      1st Apr 2005
You'll have to learn to hand code or use the custom query function.

The FP database components are design to generate VBScript that works with both Access or MS SQL
server.

The code is not incorrect, different databases requires certain things to be written differently,
this even applies between querying Access and MS SQL server, where both can support using ::
instead of " or '

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

"Bob" <(E-Mail Removed)> wrote in message
news:8695E798-2AFA-4C83-9927-(E-Mail Removed)...
>I am using FrontPage 2002 on an ISP running MySQL database, ChiliSoft ASP and
> Linux. I created an input form and a results table using the database
> results wizard.
>
> The wizard generates the SQL query as
> fp_sQry="SELECT * FROM Reqmnts WHERE (Retailer = '::Retailer::')"
> This is evaluated as bad SQL by MySQL (database results error message)
> MySQL appears to be looking for the following code
> ="SELECT * FROM Reqmnts WHERE Retailer = "Retailer""
> How do I get FrontPage to permit double quotes within quotes?
> I have run a test by coding in
> response.write Request.Form("Retailer") and the server writes out the name
> entered in the Form box
>
> If I use a custom query where I specify a specific value within the Column
> Retailer, the the code is generated correctly and everything works.
> For example,
> fp_sQry="SELECT * FROM Reqmnts WHERE (Retailer = 'CVS')"
> works correctly.
>



 
Reply With Quote
 
=?Utf-8?B?Qm9i?=
Guest
Posts: n/a
 
      1st Apr 2005
Thanks for the suggestion, the custom query function returns the same results
because it inserts the ::

Is there any way to instruct FP and the VBScript editor to use ' or some
other character in place of " for enclosing the QRY string that is generated
by FP?

"Thomas A. Rowe" wrote:

> You'll have to learn to hand code or use the custom query function.
>
> The FP database components are design to generate VBScript that works with both Access or MS SQL
> server.
>
> The code is not incorrect, different databases requires certain things to be written differently,
> this even applies between querying Access and MS SQL server, where both can support using ::
> instead of " or '
>
> --
> ==============================================
> 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
>
> "Bob" <(E-Mail Removed)> wrote in message
> news:8695E798-2AFA-4C83-9927-(E-Mail Removed)...
> >I am using FrontPage 2002 on an ISP running MySQL database, ChiliSoft ASP and
> > Linux. I created an input form and a results table using the database
> > results wizard.
> >
> > The wizard generates the SQL query as
> > fp_sQry="SELECT * FROM Reqmnts WHERE (Retailer = '::Retailer::')"
> > This is evaluated as bad SQL by MySQL (database results error message)
> > MySQL appears to be looking for the following code
> > ="SELECT * FROM Reqmnts WHERE Retailer = "Retailer""
> > How do I get FrontPage to permit double quotes within quotes?
> > I have run a test by coding in
> > response.write Request.Form("Retailer") and the server writes out the name
> > entered in the Form box
> >
> > If I use a custom query where I specify a specific value within the Column
> > Retailer, the the code is generated correctly and everything works.
> > For example,
> > fp_sQry="SELECT * FROM Reqmnts WHERE (Retailer = 'CVS')"
> > works correctly.
> >

>
>
>

 
Reply With Quote
 
Thomas A. Rowe
Guest
Posts: n/a
 
      2nd Apr 2005
No, the query string has to be enclosed in double quotes, at least every VBScript example I have
ever seen use " quotes.

You can't change the method FP uses to write VBScript. This is when you need to learn to hand code,
and you will also find that once you do this, you will have a lot more flexibility and options, plus
a lot less code on a page.

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

"Bob" <(E-Mail Removed)> wrote in message
news:E3404B18-F608-41D4-A942-(E-Mail Removed)...
> Thanks for the suggestion, the custom query function returns the same results
> because it inserts the ::
>
> Is there any way to instruct FP and the VBScript editor to use ' or some
> other character in place of " for enclosing the QRY string that is generated
> by FP?
>
> "Thomas A. Rowe" wrote:
>
>> You'll have to learn to hand code or use the custom query function.
>>
>> The FP database components are design to generate VBScript that works with both Access or MS SQL
>> server.
>>
>> The code is not incorrect, different databases requires certain things to be written differently,
>> this even applies between querying Access and MS SQL server, where both can support using ::
>> instead of " or '
>>
>> --
>> ==============================================
>> 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
>>
>> "Bob" <(E-Mail Removed)> wrote in message
>> news:8695E798-2AFA-4C83-9927-(E-Mail Removed)...
>> >I am using FrontPage 2002 on an ISP running MySQL database, ChiliSoft ASP and
>> > Linux. I created an input form and a results table using the database
>> > results wizard.
>> >
>> > The wizard generates the SQL query as
>> > fp_sQry="SELECT * FROM Reqmnts WHERE (Retailer = '::Retailer::')"
>> > This is evaluated as bad SQL by MySQL (database results error message)
>> > MySQL appears to be looking for the following code
>> > ="SELECT * FROM Reqmnts WHERE Retailer = "Retailer""
>> > How do I get FrontPage to permit double quotes within quotes?
>> > I have run a test by coding in
>> > response.write Request.Form("Retailer") and the server writes out the name
>> > entered in the Form box
>> >
>> > If I use a custom query where I specify a specific value within the Column
>> > Retailer, the the code is generated correctly and everything works.
>> > For example,
>> > fp_sQry="SELECT * FROM Reqmnts WHERE (Retailer = 'CVS')"
>> > works correctly.
>> >

>>
>>
>>



 
Reply With Quote
 
Thomas A. Rowe
Guest
Posts: n/a
 
      2nd Apr 2005
Actually, you can try changing the following files under the _fpclass folder:

fpdblib.inc
fpdbrgn1.inc
fpdbrgn2.inc

However FP may at some point overwrite any changes you make to these files.

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

"Thomas A. Rowe" <(E-Mail Removed)> wrote in message news:%(E-Mail Removed)...
> No, the query string has to be enclosed in double quotes, at least every VBScript example I have
> ever seen use " quotes.
>
> You can't change the method FP uses to write VBScript. This is when you need to learn to hand
> code, and you will also find that once you do this, you will have a lot more flexibility and
> options, plus a lot less code on a page.
>
> --
> ==============================================
> 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
>
> "Bob" <(E-Mail Removed)> wrote in message
> news:E3404B18-F608-41D4-A942-(E-Mail Removed)...
>> Thanks for the suggestion, the custom query function returns the same results
>> because it inserts the ::
>>
>> Is there any way to instruct FP and the VBScript editor to use ' or some
>> other character in place of " for enclosing the QRY string that is generated
>> by FP?
>>
>> "Thomas A. Rowe" wrote:
>>
>>> You'll have to learn to hand code or use the custom query function.
>>>
>>> The FP database components are design to generate VBScript that works with both Access or MS SQL
>>> server.
>>>
>>> The code is not incorrect, different databases requires certain things to be written
>>> differently,
>>> this even applies between querying Access and MS SQL server, where both can support using ::
>>> instead of " or '
>>>
>>> --
>>> ==============================================
>>> 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
>>>
>>> "Bob" <(E-Mail Removed)> wrote in message
>>> news:8695E798-2AFA-4C83-9927-(E-Mail Removed)...
>>> >I am using FrontPage 2002 on an ISP running MySQL database, ChiliSoft ASP and
>>> > Linux. I created an input form and a results table using the database
>>> > results wizard.
>>> >
>>> > The wizard generates the SQL query as
>>> > fp_sQry="SELECT * FROM Reqmnts WHERE (Retailer = '::Retailer::')"
>>> > This is evaluated as bad SQL by MySQL (database results error message)
>>> > MySQL appears to be looking for the following code
>>> > ="SELECT * FROM Reqmnts WHERE Retailer = "Retailer""
>>> > How do I get FrontPage to permit double quotes within quotes?
>>> > I have run a test by coding in
>>> > response.write Request.Form("Retailer") and the server writes out the name
>>> > entered in the Form box
>>> >
>>> > If I use a custom query where I specify a specific value within the Column
>>> > Retailer, the the code is generated correctly and everything works.
>>> > For example,
>>> > fp_sQry="SELECT * FROM Reqmnts WHERE (Retailer = 'CVS')"
>>> > works correctly.
>>> >
>>>
>>>
>>>

>
>



 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
results without the Database Results Wizard-via MS-Access marc Microsoft Frontpage 0 1st Mar 2009 09:13 PM
Database Results Wizard formatting Excel results KarenM Microsoft Frontpage 10 28th Aug 2008 03:38 PM
Database Editor & Database Results Wizard =?Utf-8?B?R3VpZG8=?= Microsoft Frontpage 2 26th Jan 2006 09:38 PM
database results wizard locks database =?Utf-8?B?Z2lubnk=?= Microsoft Frontpage 1 15th Dec 2004 09:49 AM
How to Add an All Values Item to a Database Query by Using the FrontPage 2003 Database Results Wizard =?Utf-8?B?RGFuaWVs?= Microsoft Frontpage 4 2nd Feb 2004 05:36 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 07:47 AM.