Wrox Programmer Forums
|
Classic ASP Databases Discuss using ASP 3 to work with data in databases, including ASP Database Setup issues from the old P2P forum on this specific subtopic. See also the book forum Beginning ASP.NET Databases for questions specific to that book. NOT for ASP.NET 1.0, 1.1, or 2.0.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Classic ASP Databases section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old February 25th, 2007, 09:18 PM
Authorized User
 
Join Date: Feb 2007
Posts: 23
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via AIM to bonkbc Send a message via Yahoo to bonkbc
Default

Hello...I found out what the prob was, after a lot of wasted time. I had done everything correctly, but was using my laptop running IIS as a test server. I uploaded the files that I had been working to the internet and tested there, and it worked perfectly.

It was frustrating, but I thank you all very much. This is the best forum I've ever posted on. Everyone was helpful and very speedy.

Anyway, now that I've figured out that I can't always trust IIS, do you know of a more fool proof configuration for testing? In other words...what would a serious, professional web designer and .asp programmer use as a good testing environment (ie: servers, test servers, cross-browsers etc etc)?? Currently, I use my laptop running IIS on windows XP. I test with IE 6.0, and sometimes Firefox.

I'm enjoying this and learning a lot, I'd like to get better. Still a Newb!

BTW, Imar...your site is great and YES, Sonic Youth ROCKS! I love them.

thanks again,
Brian

 
Old February 25th, 2007, 09:36 PM
Wrox Author
 
Join Date: Oct 2005
Posts: 4,104
Thanks: 1
Thanked 64 Times in 64 Posts
Send a message via AIM to dparsons
Default

Depending on the situation my dev machine is either a box running XP Pro with IIS 5.1 for development and testing purposes

or

XP Pro 64 for development running a virtualized Win2K3 server for testing purposes.

in both accounts my live server is a Win2K3 box.

Its good to cross test with all browsers, just to make sure that your site looks the same across all platforms.

hth.

================================================== =========
Read this if you want to know how to get a correct reply for your question:
http://www.catb.org/~esr/faqs/smart-questions.html
^^Took that from planoie's profile^^
^^Modified text taken from gbianchi profile^^
================================================== =========
Technical Editor for: Professional Search Engine Optimization with ASP.NET
http://www.wiley.com/WileyCDA/WileyT...470131470.html

Discussion:
http://p2p.wrox.com/topic.asp?TOPIC_ID=56429
 
Old February 25th, 2007, 09:53 PM
Authorized User
 
Join Date: Feb 2007
Posts: 23
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via AIM to bonkbc Send a message via Yahoo to bonkbc
Default

by virtualized...do you mean run a program like VMware or similar to it?

thanks!

 
Old February 26th, 2007, 08:58 AM
Wrox Author
 
Join Date: Oct 2005
Posts: 4,104
Thanks: 1
Thanked 64 Times in 64 Posts
Send a message via AIM to dparsons
Default

I am using Virtual Server from Microsoft, but yes, it is the same thing as VMWare

================================================== =========
Read this if you want to know how to get a correct reply for your question:
http://www.catb.org/~esr/faqs/smart-questions.html
^^Took that from planoie's profile^^
^^Modified text taken from gbianchi profile^^
================================================== =========
Technical Editor for: Professional Search Engine Optimization with ASP.NET
http://www.wiley.com/WileyCDA/WileyT...470131470.html

Discussion:
http://p2p.wrox.com/topic.asp?TOPIC_ID=56429
 
Old February 26th, 2007, 04:22 PM
Authorized User
 
Join Date: Feb 2007
Posts: 23
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via AIM to bonkbc Send a message via Yahoo to bonkbc
Default

Hello, I am using a simple access DB that has 2 columns (1: a product name that is text. 2: a unique number, 'listnum', which is the key)

Are multiple SQL statements allowed in one .asp page?

I'm trying to INSERT to this database, but before I do, I need to get the highest ID number from listnum column. The ID # is a unique number, and run in increments from 1 on up to 'x'. Once I get that number, I want to write a new product into another column, and give it a ID # which is 'x' + 1.

Everything is working, except the INSERT into SQL statement. Are multiple SQL statements, with multiple OBJconns and adodb.connections valid?

 
Old February 26th, 2007, 04:28 PM
Wrox Author
 
Join Date: Oct 2005
Posts: 4,104
Thanks: 1
Thanked 64 Times in 64 Posts
Send a message via AIM to dparsons
Default

Only use one connection for all of your processes, your pseudo code is something like this:

//Open database connection
//Open Recordset return listnum id set it to a variable
//close recordset
//Open recordset insert row into database, supplying the above variable
//close recordset
//close database connection

So yes, you can call multiple SQL statements on one page. I must ask though, why arent you using an Auto Increment field for you ID#?

================================================== =========
Read this if you want to know how to get a correct reply for your question:
http://www.catb.org/~esr/faqs/smart-questions.html
^^Took that from planoie's profile^^
^^Modified text taken from gbianchi profile^^
================================================== =========
Technical Editor for: Professional Search Engine Optimization with ASP.NET
http://www.wiley.com/WileyCDA/WileyT...470131470.html

Discussion:
http://p2p.wrox.com/topic.asp?TOPIC_ID=56429
 
Old February 26th, 2007, 04:36 PM
Authorized User
 
Join Date: Feb 2007
Posts: 23
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via AIM to bonkbc Send a message via Yahoo to bonkbc
Default

thank you very much.

As for auto increment? I'm pretty much a newbie, and hacking this together by myself. I did it by hand using a loop. I didn't know I could auto increment. Is that something I could use code to do, or is that set up using attributes in a DB?

thanks again,
Brian

 
Old February 26th, 2007, 04:42 PM
Wrox Author
 
Join Date: Oct 2005
Posts: 4,104
Thanks: 1
Thanked 64 Times in 64 Posts
Send a message via AIM to dparsons
Default

I assume that since you are using an access database, you have the entire program. Inside of access open up your datatable and set your ID column to auto inc (identity) in the column properties located at the bottome of the designer pane.

================================================== =========
Read this if you want to know how to get a correct reply for your question:
http://www.catb.org/~esr/faqs/smart-questions.html
^^Took that from planoie's profile^^
^^Modified text taken from gbianchi profile^^
================================================== =========
Technical Editor for: Professional Search Engine Optimization with ASP.NET
http://www.wiley.com/WileyCDA/WileyT...470131470.html

Discussion:
http://p2p.wrox.com/topic.asp?TOPIC_ID=56429
 
Old February 26th, 2007, 05:08 PM
Authorized User
 
Join Date: Feb 2007
Posts: 23
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via AIM to bonkbc Send a message via Yahoo to bonkbc
Default

thanks! That worked like a charm. I added the autonumber attribute to the id#, and as a result, I no longer needed to even create a RS. I just grabbed the DATA and inserted it, easy as pie.

I think I overcomplicate things sometimes...but getting the hang of it.

Thank you very much!

:D

 
Old February 26th, 2007, 05:14 PM
Wrox Author
 
Join Date: Oct 2005
Posts: 4,104
Thanks: 1
Thanked 64 Times in 64 Posts
Send a message via AIM to dparsons
Default

No problem, glad you got it working.

================================================== =========
Read this if you want to know how to get a correct reply for your question:
http://www.catb.org/~esr/faqs/smart-questions.html
^^Took that from planoie's profile^^
^^Modified text taken from gbianchi profile^^
================================================== =========
Technical Editor for: Professional Search Engine Optimization with ASP.NET
http://www.wiley.com/WileyCDA/WileyT...470131470.html

Discussion:
http://p2p.wrox.com/topic.asp?TOPIC_ID=56429





Similar Threads
Thread Thread Starter Forum Replies Last Post
parametising sql statements in ASP classic trufla Classic ASP Basics 5 June 18th, 2008 02:38 PM
CASE Statements in T-SQL atcs2152 SQL Server 2000 3 April 28th, 2006 10:53 AM
Sql statements in data adapter Raif ASP.NET 1.0 and 1.1 Basics 1 July 14th, 2004 08:50 AM
SQL Statements marmer Classic ASP Basics 3 November 13th, 2003 01:42 AM
Quoting variables in SQL statements tp194 Classic ASP Databases 1 July 4th, 2003 03:41 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.