3000 N100 battery

3000 N100 battery
 
HomePortalSearchRegisterLog in

Share
 

 How to Connect to mySQL Server using ASP Classic

Go down 
AuthorMessage
Admin
Admin


Posts : 313
Join date : 2011-09-04

How to Connect to mySQL Server using ASP Classic Empty
PostSubject: How to Connect to mySQL Server using ASP Classic   How to Connect to mySQL Server using ASP Classic EmptyMon Sep 12, 2011 3:32 pm

ASP Classic seems to be outdated when the new ASP. net has been introduce by Microsoft but because ASP classic had happened to be established in web progress, some developer still purposes it as key coding language in providing web application to the clients. Only a few programmer when compared to PHP language uses it in developing pages, fortunately I am mostly of the who uses it. The reason I morning still using ASP language because (1) it does not take first language I've ever in your life learned in programming entire world, (2) one of the employer uses ASP expressions in providing website application to his clients. Anyway, for those who have no clue that ASP means, ASP is known as Active Server Pages, known as Classic ASP or ASP Classic was Microsoft's 1st server-side script-engine for dynamically-generated web site. Initially released as some sort of add-on to Internet Information and facts Services (IIS) via that Windows NT 4. 0 Possibility Pack (ca 1998), it had become subsequently included as a free component of Windows Server (since the primary release of Windows 2000 Server). Their bond StringGo back to our topic, according to connectionstrings. com, one connect to mySQL server has MySQL Connector/ODBC 3. 51 which happens to be available for download by dev. mysql. com. Using this connector, your connection string will seems this: "Driver=MySQL ODBC 3.51 Driver; Server=localhost; Database=myDataBase; User=myUsername; Password=myPassword; Option=3; " Where Server - stands out as the name of database server (Default: localhost); Database - is typically the name of the database you ought to use; User - is the username you ought to use to login to help you mySQL server (Default: root) Password - is the password you ought to use to login for you to mySQL serverLet us use the connection string to open a link: < %Dim Conn_StringDim rsCmdConn_String = "Driver=MySQL ODBC 3.51 Driver; Server=localhost; Database=myDataBase; User=myUsername; Password=myPassword; Option=3; "Set rsCmd = Server. CreateObject ("ADODB. Command")rsCmd. ActiveConnection = Conn_String%> Opening Recordset using Parameterize Query Because we are finished with the connection string, let us try out opening a recordset using the active connection we established above: < % Poor RSrsCmd. CommandText = "SELECT * WITH TABLE"rscmd. Prepared = trueSet RS = rsCmd. Execute%> Coordinating the above code: < %Dim Conn_StringDim rsCmdDim RSConn_String = "Driver=MySQL ODBC 3.51 Driver; Server=localhost; Database=myDataBase; User=myUsername; Password=myPassword; Option=3; "Set rsCmd = Server. CreateObject ("ADODB. Command")rsCmd. ActiveConnection = Conn_StringrsCmd. CommandText = "SELECT * WITH TABLE"rsCmd. Prepared = trueSet RS = rsCmd. Execute%> Now RS provides the recordset, to access the inside RS, we will loop from your recordset: < % If you're not RS. EOF then Before RS. EOF Response. write(RS("fieldname")) RS. movenext 'move that will next record Loop Last part if%> Closing the connection and then the recordset: < % RS. Shut down: Set RS = Not a single thing rsCmd. Close = Specify rsCmd = Nothing%> This is all folks. Enjoy in your programming experience. Source: http: //reygcalantaol. com/2011/07/16/how-to-connect-to-mysql-server-using-asp-classic/
Back to top Go down
https://3000-n100.forumotion.com
 
How to Connect to mySQL Server using ASP Classic
Back to top 
Page 1 of 1
 Similar topics
-
» No server response
» New online chess server, www.easychess.com
» Chess-Tournament-Results-Server
» FICS - Free Internet Chess Server
» No server response

Permissions in this forum:You cannot reply to topics in this forum
3000 N100 battery :: Your first category :: Your first forum-
Jump to: