Snitz Forums 2000
Snitz Forums 2000
Home | Profile | Register | Active Topics | Members | Search | FAQ
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 Community Forums
 Code Support: ASP (Non-Forum Related)
 Please help me, im going mad
 New Topic  Topic Locked
 Printer Friendly
Author Previous Topic Topic Next Topic  

Spoon
Average Member

Ireland
507 Posts

Posted - 12 July 2001 :  12:34:56  Show Profile  Visit Spoon's Homepage  Send Spoon an ICQ Message
Hi,

At this stage ive gone mad, ive tried everything!!!

The script gathers the fields TEXT and LINK from the form, Then when it goes to add it to the ACCESS 2000 DB it messes up, here is my sql stmt

sqlstmt = "INSERT INTO Bottomlinks (TEXT,LINK) VALUES ('"&TEXT&"','"&LINK&"')"

BOTDB.Execute(sqlstmt)

I dont know whats up with it at all. Heres the error i get

-------

Microsoft JET Database Engine error '80040e14'

Syntax error in INSERT INTO statement.

/admin/bodytags/botl.asp, line 205

-----

Maybe its something easy, i just cant figure it out or spot whats wrong. Ive got a feeling its something to do with the LINK string. I trim the Link string and see if it contains the text "http://" . If it does, it continues, heres the code for that bit just incase

-----------------

LINK = Request.Form("LINK")
If LINK = "" Then
Response.Write "<font face=verdana size=2 color=red><b><center>"
Response.Write "You must enter a LINK value</b>"
Response.Write "<br><font size=1 color=blue><a href='Javascript: OnClick= history.back()'>Go Back</a>"
Response.Write "</font></center></font>"
Response.End
End If

LINKSTRING = Lcase(LINK)
LINK = InStr(LINKSTRING,"http://")
If LINK = 0 Then
Response.Write "<font face=verdana size=2 color=red><b><center>"
Response.Write LINKSTRING & "</b> is not a valid URL. Remember you must use the <b>http://</b> Path."
Response.Write "<br><font size=1 color=blue><a href='Javascript: OnClick= history.back()'>Go Back</a>"
Response.Write "</font></center></font>"
Response.End
End If

---------------

Thanks to anyone who helps me

Sunil Kumar

"uohh look at me, ive got a signature, uohh look at me!" :)

davemaxwell
Access 2000 Support Moderator

USA
3020 Posts

Posted - 12 July 2001 :  14:03:30  Show Profile  Visit davemaxwell's Homepage  Send davemaxwell an AOL message  Send davemaxwell an ICQ Message  Send davemaxwell a Yahoo! Message
A couple things. "Text" is a reserved word for Access2000 fields. Renaming that field would probably be a good idea. If the field is defined as a memo, move it to the end of the insert and it might work also....

Dave Maxwell
--------------
Proud to be a "World Class" Knucklehead
Go to Top of Page

Spoon
Average Member

Ireland
507 Posts

Posted - 12 July 2001 :  16:08:04  Show Profile  Visit Spoon's Homepage  Send Spoon an ICQ Message
quote:

A couple things. "Text" is a reserved word for Access2000 fields. Renaming that field would probably be a good idea. If the field is defined as a memo, move it to the end of the insert and it might work also....

Dave Maxwell
--------------
Proud to be a "World Class" Knucklehead



Solved it, thanks a million

Spoon

"uohh look at me, ive got a signature, uohh look at me!" :)
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Topic Locked
 Printer Friendly
Jump To:
Snitz Forums 2000 © 2000-2021 Snitz™ Communications Go To Top Of Page
This page was generated in 0.27 seconds. Powered By: Snitz Forums 2000 Version 3.4.07