Database Results Query

S

stuart

I'm setting up a search by date page that searches through
an access database. The problem I'm having is frontpage
keeps adding an extra character to my query. Here is the
example:

S-SQL="SELECT * FROM allsprint WHERE (RMAcustdate >=
#::startdate::# AND RMAcustdate <= #::enddate::#)
ORDER BY RMAcustdate ASC"

but when it writes the code here is what I get:

fp_sQry="SELECT * FROM allsprint WHERE (RMAcustdate >=
#::startdate::# AND RMAcustdate <= #::enddate::#) ORDER
BY RMAcustdate ASC>"

as you can see, it adds the ">" character after ASC at the
end of the fp_sQry statement. The problem is that
frontpage wont let me delete this character in the second
query and the first query doesn't contain it. what you do
in the first statement changes the second so I don't
understand why this is happening. I wish there was a way
to turn off the overwrite function of frontpage...please
help
 
T

Thomas A. Rowe

How are you insert this code?

You should be able to type it in directly in HTML / Code View or type in notepad, then copy and past
into HTML / Code View.

--
==============================================
Thomas A. Rowe (Microsoft MVP - FrontPage)
WEBMASTER Resources(tm)

FrontPage Resources, WebCircle, MS KB Quick Links, etc.
==============================================
 
M

Mark Fitzpatrick

Look at the first query. There's an &lt; in there. There shouldn't be. What
FP is probably doing is converting the &lt; into a < and then trying to make
it a valid item by adding the closing > at the end.

Hope this helps,
Mark Fitzpatrick
Microsoft MVP - FrontPage
 
S

Stuart

I'm using the database results wizard...I have found a way
around it by taking out the character, copying all the
code, closing frontpage, mapping a drive to the server and
changing it there from notepad...but waht a pain in the
butt.

The really funny thing is when you change it in the html
in frontpage and save it tells you it will be overwritten
and it adds a different character evertime...I'm not happy
with microsoft...all their soft ware is too "do it for
You"...I like software that you tell it what to do, not
the other way around.
-----Original Message-----
How are you insert this code?

You should be able to type it in directly in HTML / Code
View or type in notepad, then copy and past
 
T

Thomas A. Rowe

When using the FP Database component, you can only manually change the grey code, and save the page
while in HTML / Code view. As with all Webbot generated code, the FP will overwrite any manual
changes you make, that are not consistent with what the Webbot generates.

If you want complete control over your ASP code, then you will have to learn to hand code your ASP /
VBScript and not rely on the FP database component.

--
==============================================
Thomas A. Rowe (Microsoft MVP - FrontPage)
WEBMASTER Resources(tm)

FrontPage Resources, WebCircle, MS KB Quick Links, etc.
==============================================
 
B

Bob Lehmann

If you don't like the "do it for You" stuff, why did you use the db wizard
stuff?

Bob Lehmann
 
S

Stuart

Thomas,

the thing that doesn't make sense to me is the fact that
the grey code doesn't contain the extra character that i'm
trying to get rid of. Only the code that is generated has
the extra character and you can't change that...how do I
get rid of it in the grey code if it isn't there?

-----Original Message-----
When using the FP Database component, you can only
manually change the grey code, and save the page
while in HTML / Code view. As with all Webbot generated
code, the FP will overwrite any manual
changes you make, that are not consistent with what the Webbot generates.

If you want complete control over your ASP code, then you
will have to learn to hand code your ASP /
 
J

Jim Buyens

I have a feeling that you're trying to modify your SQL
statement in Code View, and this is something you should
never do. Instead:

1. Double-click any yellow part of your database
results region.
2. Advance to page 2 of the wizard,
3. Click Custom Query and Edit.
4. Fix your SQL statement.
5. Click OK, Next, Next, Next, and Finish.
6. Save and test.

Jim Buyens
Microsoft FrontPage MVP
http://www.interlacken.com
Author of:
*----------------------------------------------------
|\---------------------------------------------------
|| Microsoft Office FrontPage 2003 Inside Out
||---------------------------------------------------
|| Web Database Development Step by Step .NET Edition
|| Microsoft FrontPage Version 2002 Inside Out
|| Faster Smarter Beginning Programming
|| (All from Microsoft Press)
|/---------------------------------------------------
*----------------------------------------------------
 
T

Thomas A. Rowe

Is the code with the problem being pull from a field in your database?

--
==============================================
Thomas A. Rowe (Microsoft MVP - FrontPage)
WEBMASTER Resources(tm)

FrontPage Resources, WebCircle, MS KB Quick Links, etc.
==============================================
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top