Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

ASP VS SQL 1

Status
Not open for further replies.

e1k4l3cs

MIS
Nov 11, 2002
56
SG
Can anybody define ASP from SQL to me ??? I am kind of stuck !!! Can ASP work under MicroSoft Access 2002 just like SQL can ??? I am totally CONFUSED !!! Please help me out... A MILLION thanks...
Kelvin
 
Hi,
Frankly, I don't quite understand your question ... ASP and SQL are totally 2 different animal... ASP is a script for you to write 'web-based applications' while SQL is a database technology ...

You can develop ASP using vbScript or javaScript (under .NET, you can write it in anything). If you're trying to write an SQL storedProcedure, you will write it in one of the few SQL language (T-SQL, etc, etc).

If you're trying to compare the speed between an ASP and SQL stored procedure, I dare say that an SQL Stored Procedure will win anytime. Although you may not be able to do it using StoredProcedure all the time (complexities).

Think you should elaborate on your Q.

- Joseph ~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-
Visit --> for (Replica) Watches, Pen, Handbags, Hats, Jerseys and more ... at prices that makes your code spin ...
~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-
 
Ermm... I think I am trying to know more abt both languauges related to ADO objects... Anyway, ur info was resourceful to me... Thx Joseph...

The following 3 pointsgot something to do with web database right ???

1)Dynamically edit, change or add any content of a Web page
2)Respond to user queries or data submitted from HTML forms
3)Access any data or databases and return the results to a browser

SQL can be used for web database purposes right ???
Sorry if I elaborated poorly on my question again coz I am VERY new to these 2 languages...

Kelvin
 
Hi,
Can I recommend you some publishers? I personally like Wrox as they seems to be very good at explaining these stuff :)

I think what you qouted are your 'Requirements'. (for small scale projects), use ASP to do all the front-end and business logics. You can either use SQL for database or just use Access.

1)Dynamically edit, change or add any content of a Web page
*** This is not related to ASP or SQL. This is a requirement for your project (I think).

2)Respond to user queries or data submitted from HTML forms
*** ditto. But I guess you use ASP to query your backend database and format it for the users to see (HTML).

3)Access any data or databases and return the results to a browser
*** this is eseentially the same as point 2 above.

SQL is a database, it doesn't matter what you're using it for .. webApplication or LAN application.

regards,
- Joseph
~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-
Visit --> for (Replica) Watches, Pen, Handbags, Hats, Jerseys and more ... at prices that makes your code spin ...
~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-
 
Ermm... Joseph... Can u explain the following lines that I took from a tutorial based website ??? Thx...

SQL and Active Server Pages:

SQL is an important part of ASP, because the Active Data Object (ADO) used in ASP to access databases, rely on SQL for data access.

Kelvin

 
I do not know the context of your tutorial (what scenario it is referring to) because the statement is not entirely true. So, my answer below may not be in the correct context either.

ADO is a layer that handles data access. However, it is not necessary that it is accessing an SQL server. You can also access a Microsoft Access database, or other databases. Basically, you can store your data in any databases (SQL [Microsoft, Oracle, mySQL, etc, etc], Microsoft Access, Excel, text file, etc, etc). You use the ADO object (in your ASP) to access them.

You should use MS's online documentation:

regards,
- Joseph ~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-
Visit --> for (Replica) Watches, Pen, Handbags, Hats, Jerseys and more ... at prices that makes your code spin ...
~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-
 
Hmmmmm.......That means ASP can work along with SQL(I use SQL from within MS Access 2002) right ???

Kelvin
 
The SQL statement you write in MsAccess is transparent to ASP. So, if you build a view in MsAccess using SQL, you access the view from ASP (via ADO) as Name. HOWEVER, you cannot build a parameterized query in MsAccess and access it via ADO in ASP. MsAccess do not allow that. If you need to write parameterized query, you have no choice but to use an SQLServer.

Note, I think you're confused between the term 'SQL Statement' 'SQL Server' and 'SQL Database/SQL Datastore'. You need to differentiate them.

It will also be easier if you paint the scenario you're trying to do so that I can add my 2 cents in the right context.

regards,
- Joseph ~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-
Visit --> for (Replica) Watches, Pen, Handbags, Hats, Jerseys and more ... at prices that makes your code spin ...
~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-
 
okok... I will go and differentiate between those few SQL related terms... Thx again Joseph...

Kelvin
 
Hi,
Is there a different between a SQL Server and SQL Database ???

Kelvin
 
Hi,

SQL Server is the server application that runs your database. Unlike MsAccess which is a simple client that caters to low transactions, an SQL Server is a big machine itself (normally) that can cater to hundreds/thousands of queries per second.

In MsAccess, there is no 'server', just the .mdb database. In SQL, you differentiate between the Server (engine) and the database. The SQL Database is the file the data is stored in (like the .mdb), but you cannot acccess the file as is. You need to go through the SQLServer to do anything.

Try having 10 people connecting to the same MsAccess .mdb and you know what I mean.
~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-
Visit --> for (Replica) Watches, Pen, Handbags, Hats, Jerseys and more ... at prices that makes your code spin ...
~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-
 
Ermm... I am studying for the upcoming projects... So, I cannot try out yet... Maybe when I start doing the projects then I will try... Anyway, Thx again Joseph...

Kelvin
 
Maybe this will simplify it all a little bit.
ASP is a language used to dynamically generate web sites. It deals with variables, and so on, but knows little to nothing about data beyond the fact that it is stored in an object.
SQL is a language used to request data from a database or send data to a database. This language can be used by just about any programming language in existence to make queries or execute requests to a database programatically. SQL is dependant on the database your talking to, it is only mostly consistent but the language differs a little between access, SQL Server, Oracle, mySQL, etc

ASP can use ADO objects to send SQL string and receive data back into objects. All SQL does is make a request of the database.
The comment you posted above: SQL is an important part of ASP, because the Active Data Object (ADO) used in ASP to access databases, rely on SQL for data access. is mostly true because when your ADO object communicates with a database it uses SQL (on the most part) just like you would. So if you use a .Open command, the ADO object makes an SQL statement and sends it out, utilizing the specified driver.
What the author was trying to point out is that without SQL there would be no data exchange between an ASP script and a database. And that having tht data exchange is a very importnat part of ASP because it allows us to do quite a bit of what we do (usernames, stores, forums, etc, etc)

-Tarwn --- --- --- --- --- --- --- --- --- --- --- --- --- --- --- --- --- ---
For my next trick I will pull a hat out of a rabbit (if you think thats bad you should see how the pigeon feels...) :p
 
Thx Tarwn... That means SQL and ASP do work hand on hand with ADO right ???

Kelvin
 
yeah, its kinda a family crossing the street:

ASP is handed to ADO who is handed to SQL

but SQL and ASP are able to do a lot of things alone and with other people. as you see, they're a really post-modern family.

:) :) :) :) :) :) :) :) :) :) :) :)
 
what a load of bobbins you've all written

ASP = Active Server Pages

the script on you asp page that connect to database via ado, does your while loops, if else stamements etc. You use SQL. I runs on the web server, that generates the HTML code for the user

sql = Structured Query language

The actual statement used to query the database...
ie. "Select * from table where id = 3"

they do go handin hand. SQl is THE 'language' used to interrogate databases, be it access, SQL server, or Oracle.

at a basic level it is easy, but once you get into more complex database applications, then you relly alot more on the SQL to give you the results you want.

check this site out for more jelp about how to use bother asp and sql

 
one last note. ASP is not a language. you ustilize vbscript or JavaScript to right ASP pages. haven't read through the threads completly but I don't think that was stated. I apologize to those who may have. A language that doesn't affect the way you think about programming is not worth knowing.
admin@onpntwebdesigns.com
 
Ermmmm...... Then can I say that a user extracts datas from SQL using SQL statments through ASP and ADO while a user adds datas to a database over the internet through ASP and into the SQL database ??? (Is VBA part of this family too ???) @_@

Kelvin

ASP is handed to ADO who is handed to SQL
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top