Notices
Computer & Technology Related Post here for help and discussion of computing and related technology. Internet, TVs, phones, consoles, computers, tablets and any other gadgets.

ASP Resources - Help

Thread Tools
 
Search this Thread
 
Old 25 January 2002, 02:13 PM
  #1  
Dream Weaver
Scooby Regular
Thread Starter
 
Dream Weaver's Avatar
 
Join Date: Feb 2000
Location: Lancashire
Posts: 9,844
Received 0 Likes on 0 Posts
Question

Having a real good go at the moment at my first ASP pages and linking them into MS Access.

The language and syntax is surprisingly easy and I have already created some secure login pages, and pages which list the database items on a nice looking web page. However, I am struggling to INSERT to the DB.

I have a web page complete with form which the data is entered into, and the action points to process_page.asp, which should take the Request.form (method=POST) and INSERT it to the DB. Script is along the lines of:

Conn = Connection syntax (usual connection stuff)

SQL= "INSERT INTO table(field,field) VALUES () etc etc

Conn.execute(SQL)

However it says there is a Data type mismatch in the Conn.execute line.

Are there any superb websites anywhere for ASP/Server side scripting?

DW
Old 25 January 2002, 02:52 PM
  #2  
legacyPete
Scooby Regular
 
legacyPete's Avatar
 
Join Date: Dec 2001
Posts: 202
Likes: 0
Received 0 Likes on 0 Posts
Post

DON'T DO IT!!!

I also made the mistake of trying ASP before I discovered the joys of PHP. ASP is needlessly complicated compared to PHP, and also MS Access is deeply naff - slow and clunky when used online. I beg you, don't fall into the Microsoft trap; PHP runs faster and is a much easier language to use. There is also a fantastic reference site for PHP here that covers all functions etc. I never found any ASP sites as good as this.

Anyway, just my experience... if you do give PHP a try, I would be happy to help with any queries you have.
Old 25 January 2002, 04:37 PM
  #3  
Dream Weaver
Scooby Regular
Thread Starter
 
Dream Weaver's Avatar
 
Join Date: Feb 2000
Location: Lancashire
Posts: 9,844
Received 0 Likes on 0 Posts
Thumbs up

Cheers Pete, however it is just for a small project where say 8 records a week may need to be altered at the most.

Seen as though I have Access and PWS here it makes sense to use them, rather than have to learn a new language and a new DB.

I will still have a go with PHP though - always good to learn more stuff.

DW
Old 25 January 2002, 04:39 PM
  #4  
Fosters
Scooby Regular
 
Fosters's Avatar
 
Join Date: Jul 2000
Location: Islington
Posts: 2,145
Likes: 0
Received 0 Likes on 0 Posts
Post

If you need any help, give me a shout.

Fosters
Old 25 January 2002, 07:40 PM
  #5  
DazV
Scooby Regular
 
DazV's Avatar
 
Join Date: Jun 2000
Posts: 3,783
Likes: 0
Received 0 Likes on 0 Posts
Post

www.4guysfromrolla.com

ASP / PHP - horses for courses.

Access is fine to learn with - eg. if you site gets no more than 20 concurrent connections at a time. Beyond that, move to MySQL, Oracle, SQL Server, etc...

Cold Fusion is another popular choice.

Make sure whoever is hosting your site can offer you these services though. Try Lee at www.siwd.co.uk - he's excellent.

-DV



[Edited by DazV - 1/25/2002 7:43:59 PM]
Old 26 January 2002, 12:02 AM
  #6  
Puff The Magic Wagon!
Moderator
Support Scoobynet!
iTrader: (2)
 
Puff The Magic Wagon!'s Avatar
 
Join Date: May 2000
Location: From far, far away...
Posts: 16,978
Received 15 Likes on 9 Posts
Cool

Fosters is de MAN!

He sorted me out NP in 2hrs

Old 26 January 2002, 10:28 AM
  #7  
Fosters
Scooby Regular
 
Fosters's Avatar
 
Join Date: Jul 2000
Location: Islington
Posts: 2,145
Likes: 0
Received 0 Likes on 0 Posts
Post

Cheers Puff!
Old 26 January 2002, 10:28 PM
  #8  
DazV
Scooby Regular
 
DazV's Avatar
 
Join Date: Jun 2000
Posts: 3,783
Likes: 0
Received 0 Likes on 0 Posts
Post

Back online - long story. Will post tomorrow. 2 days of hell relating to blue-screens-of-death.

Oops, seem to have posted in wrong thread - sorreee

[Edited by DazV - 1/26/2002 11:06:40 PM]
Old 27 January 2002, 01:57 PM
  #9  
Jer
Scooby Regular
 
Jer's Avatar
 
Join Date: Nov 2000
Location: Glasgow
Posts: 1,432
Likes: 0
Received 0 Likes on 0 Posts
Post

Download Macromedia Ultradev, if you know Dreamweaver you will pick up ultradev very quickley. It also has good tutorials on linking Databases and has a password form built in.

Cheers

Jeremy
Old 29 January 2002, 12:48 PM
  #10  
kryten
Scooby Regular
 
kryten's Avatar
 
Join Date: May 2000
Posts: 869
Likes: 0
Received 0 Likes on 0 Posts
Post

Ultradev is all very well and lets you knock things up quickly but it writes awful code!

You really wouldn't want to put it into a production environment as it holds the db open for the entire page and loops recordsets in an inefficient way. Plus trying to modify the code is an absolute nightmare (I know, I've tried to modify a site someone did in Ultradev - found it was quicker to rewrite from scratch!).

Its probably easiest to use ADO to access the database from ASP, it should work fine and be reliable too.

Any questions, feel free to ask....
Old 29 January 2002, 02:21 PM
  #11  
Dream Weaver
Scooby Regular
Thread Starter
 
Dream Weaver's Avatar
 
Join Date: Feb 2000
Location: Lancashire
Posts: 9,844
Received 0 Likes on 0 Posts
Talking

Thanks all, well I have managed it and am very proud of the fact that 2 days ago I had never written a line of ASP, and now I have a full online admin system for the website owner.

I have managed to create a database of records, which can be added to, amended or deleted. Once I got the hang of writing in hidden fields/text fields to hold the variables, and passing the correct variables through to the process pages it was fine. I have even managed to streamline the processes. At first I had a process page for add, amend and delete for each table. Using hidden fields my processes now determine which table we are adding/amending/deleting from/to. Very happy.

Now just need to link the DB into the actual web pages, but it should be easy enough after creating the admin section. Just a case of selecting the info and displaying the record sets on the page.

Maybe time to move towards PHP/MySql now. I presume these are better for large scale e-commerce websites? How do you program a Oracle or MySql database? i.e. for MS you use Access, so what do you use for Oracle, or MySql?

DW
Old 29 January 2002, 02:26 PM
  #12  
HHxx
Scooby Regular
 
HHxx's Avatar
 
Join Date: Nov 2001
Posts: 2,576
Likes: 0
Received 0 Likes on 0 Posts
Cool

I use this place for reference material. They have the source code from the books available for download.

H
Old 29 January 2002, 02:28 PM
  #13  
DazV
Scooby Regular
 
DazV's Avatar
 
Join Date: Jun 2000
Posts: 3,783
Likes: 0
Received 0 Likes on 0 Posts
Post

DreamWeaver,

Regardless of what server-side scripting language your're using, eg. ASP, PHP, you communicate with the database, be it Access, MySQL, etc... using standard SQL commands (pronounced "sequel")

I assume you've already done this by constructing some kind of SQL string with your ASP code, to talk to your Access database.

You should be able to install MySQL, setup a database with it, setup an ODBC source and talk to it using very similar code to what you've written.

Get yourself a good book on ASP / ADO
http://www.amazon.co.uk/exec/obidos/...712530-2412456

Get yourself a good book on the SQL command set too - lots of them.

-DV

PS: I've got a spare reference book on ASP, which costs £45 - huge book, which you can have for £20 if you want.
http://www.amazon.co.uk/exec/obidos/...712530-2412456


[Edited by DazV - 1/29/2002 2:35:54 PM]
Related Topics
Thread
Thread Starter
Forum
Replies
Last Post
Darrell@Scoobyworx
Trader Announcements
26
30 January 2024 01:27 PM
sKunk
ScoobyNet General
3
20 September 2001 09:34 PM
ScoobySnack
Non Scooby Related
45
31 August 2001 04:10 PM
boomer
Midlands (England)
12
22 June 2001 08:50 PM
Stuart H
ScoobyNet General
67
01 December 2000 04:09 PM



Quick Reply: ASP Resources - Help



All times are GMT +1. The time now is 11:10 AM.