How do I connect to two MySQL databases at two different servers from a single php page?

July 16th, 2010

How do I connect to two MySQL databases at two different servers from a single php page?

I need to extract data from 2 MySQL databases located at two different servers. How is it possible from one single PHP page?

Answer

Simply use 2 connection variables. So for the first server :
$conn1 = mysql_connect(“first.server.name”,”user”…
Second :
$conn2 = mysql_connect(“second.server.name”,”user…
Then always make sure you include the connection in the query :
$result = mysql_query(“select * from mytable”,$conn1);
This is not a very efficient use of the database.

How do users get permissions in MySql when they log into my website?

June 30th, 2010

I have a MySql database set up called users. The only things required to register to my website are a username and password. When this is completed, the database populates with the users info as requested. How does MySql make this new users permissions to have it where they can now download files from my website? As of now anyone can download and take my sites files without logging in. How do I stop that also?
Thanks in advance for any help.

Answer:

Essentially what happens is you need to connect to the database through a scripting language to authenticate users. Once a user has logged in, you create a token, usually by creating a session, and then the user will have access to your file downloads.

The basic process is:

1. User logs in.

2. After login, a home page with links will load.

3. When user clicks on the download page, the download page will check to see if the user has a valid session, or token. If so, the user is granted access.

4. On the download page, file names will appear as links, but they should not link directly to the file. There should be an intermediate page that will take the file name and process the download (similar to the source link for Smart File Downloader).

I’ve included two links that show how a basic login script is done plus one to demo how to hide your download files so users can’t access them without logging in.

sql server installation problem!

June 11th, 2010

sql server installation is not on
①, the user name must be the administrator.
②, double click the “Database installation” can not be installed, installation directory can be selected for installation or access to SETUPMSDE installation directory selection MSDE, enter the following double-click SETUP.
③, Sql server7.0 not compatible with Sql server2000, must first be deleted after the installation of 2000 7.0.
Uninstall Sql server7.0 not properly uninstalled, it will result in the registry there SQLSERVER registration information, the start menu bar at the beginning of the existence Services Manager startup items, run-time prompts can not find the suffix name. DLL files can not start the service manager.
Solution: Run, type in “regedit”, enter the registry, find the registration key HKEY_LOCAL_MACHINE, SOFTWARE in the extended menu to open the Extensions Menu, locate and select the next MicroSoft open the MSSQLServer key, right-click this folder to delete, that is, can be installed. After installation, run the Service Manager can not find the suffix name if prompted. DLL files, in the Control Panel after installation of the MSDE uninstall re-install, can solve the problem.
When the user when the machine already exists MSDE2000
Solution:
(1) into the database management, and output into the database user name and password (username admin, password is empty by default), are confirmed into the database maintenance window, select the database recovery, database recovery pop-up window (where the relevant information has been default, For Change can be set), can be directly determined after.
(2) directly to the database installation will prompt the database already exists, overwrite, click Yes you can.
When the user machine or the following versions exist MSDE7.0
Solution:
1), the MSDE7.0 or less version of the database backup. (Using the call database program or the database itself)
2) Uninstall MSDE7.0 or less version
3) and installation MSDE2000 database
4), with a call MSDE7.0 or less just a backup version of the program to restore the database
5), required to restore our software database.
Uninstall “China Personnel Information Management System” software, installation will be installed again unsuccessful
Solution:
①, installation unsuccessful: Delete Windows files and Microsoft.NET under mscoree file
②, Framework can not be installed:
Registry cleaning:
Delete HKEY_LOCAL_MACHINE \ SOFTWARE \ Microsoft \. NETFramework file
Delete HKEY_LOCAL_MACHINE \ SOFTWARE \ Microsoft \ NET Framework Setup file.
When you want to reinstall sql server, and install Shiyou appears “Your machine has been installed on an instance of” prompt, you can delete the program files \ Microsoft SQL Server folder and registry information, and then install.
Such and such a dynamic link file not found
When a certain dynamic link file not found, you can try to install sql server found in the file this file, copied to the system directory of the system and system32 folder (usually this error message, which will prompt This folder is missing several files)
When the installation program configure the server fails, you can try to resolve what
This error message can be found in the system directory, for example, my system is win2000, then the file in C: \ WINNT \ sqlstp.log
Failed 1:
Is working with the service?
driver = (sql server); server = ZHL; UID = sa; PWD =; database = master
[Microsoft] [ODBC Driver Manager] Driver SQLAllocHandle on SQL_H

driver = (sql server); server = ZHL; UID = sa; PWD =; database = master
[Microsoft] [ODBC Driver Manager] Driver SQLAllocHandle on SQL_H
driver = (sql server); server = ZHL; UID = sa; PWD =; database = master
[Microsoft] [ODBC Driver Manager] Driver SQLAllocHandle on SQL_H
SQL Server configuration?
################################################## ##################
13:40:06 Process Exit Code: (-1)
13:40:09 Setup configure the server failed. Reference to the server error logs and C: \ WINNT \ sqlstp.log for more information.
13:40:09 Action CleanUpInstall:
When this error occurs, try reloading the system files
My machine is win2000, win2000 re-run under the dos installation, and then select the repair, rather than a new installation
Repair system files, and then install sql server, this error message does not
Failure 2:
Working with the service?
driver = (sql server); server = ZHL; UID = sa; PWD =; database = master
[Microsoft] [ODBC Driver Manager] Data source not found
driver = (sql server); server = ZHL; UID = sa; PWD =; database = master
[Microsoft] [ODBC Driver Manager] Data source not found
driver = (sql server); server = ZHL; UID = sa; PWD =; database = master
[Microsoft] [ODBC Driver Manager] Data source not found
SQL Server configuration?
################################################## ##################
13:50:07 Process Exit Code: (-1)
13:50:10 Setup configure the server failed. Reference to the server error logs and C: \ WINNT \ sqlstp.log for more information.
13:50:10 Action CleanUpInstall:
When this error occurs because the registry to delete the HKEY_LOCAL_MACHINE \ SOFTWARE \ ODBC in the sql sever the
Failed three:
With the service?
driver = (sql server); server = ZHL; UID = sa; PWD =; database = master
[Microsoft] [ODBC SQL Server Driver] [Named Pipes] Connection?
[Microsoft] [ODBC SQL Server Driver] [Named Pipes] ConnectionRead (ReadFile ()).
driver = (sql server); server = ZHL; UID = sa; PWD =; database = master
[Microsoft] [ODBC SQL Server Driver] [Named Pipes] Connection?
[Microsoft] [ODBC SQL Server Driver] [Named Pipes] ConnectionRead (GetOverLappedResult ()).
driver = (sql server); server = ZHL; UID = sa; PWD =; database = master
[Microsoft] [ODBC SQL Server Driver] [Named Pipes] Connection?
[Microsoft] [ODBC SQL Server Driver] [Named Pipes] ConnectionRead (GetOverLappedResult ()).
SQL Server configuration?
################################################## ##################
17:17:41 Process Exit Code: (-1)
17:17:45 Setup configure the server failed. Reference to the server error logs and
When this error, you must install the ODBC Repair Tool

Service Provider Operations — What you should know…

May 24th, 2010

For a quick overview of the new Service Provider Operations track watch this presentation by Sameer Padhye, SVP of Cisco Services. Here Sameer not only discusses the new track but offers valuable insight on how it will impact Cisco customers and partners.

Read the rest of this entry »

Review Questions from the CCNA SP Operations course

May 24th, 2010

Review Questions are great tools for helping you prep for your exam. Here is a sample of the Review Questions found in the Practice Tab of the SSPO section, to help you master the content of the SSPO course and do well on the exam.

Read the rest of this entry »

What is sybase?

May 18th, 2010

History

Sybase was founded in 1984 by Mark Hoffman, Bob Epstein, Jane Doughty and Tom Haggin in Epstein’s Berkeley, Calif., home. Together, they set out to create a relational database management system (RDBMS), which would organize information and make it available to many computers in a network. At the time, Sybase called the database server “Sybase SQL Server”and made a deal with Microsoft to share the source code for Microsoft to remarket on the OS/2 platform as “SQL Server”. Until version 4.9, Sybase and Microsoft SQL Server were virtually identical. Due to disagreements between the two companies over revenue sharing (or lack thereof), Sybase and Microsoft decided to split the code-lines and went their own way, although the shared heritage is very evident in the Transact-SQL (T-SQL) procedural language as well as the basic process architecture. The big difference is that Sybase has a Unix heritage, while Microsoft SQL Server was adapted and optimized only for the Microsoft Windows NT operating system (vendor lock-in). Sybase continues to offer versions for Windows, several varieties of Unix, and for Linux.

Sybase suffered a major downturn in fortune in the late 1990s when Informix started outselling it by a wide margin. However, Informix was later acquired by IBM in 2001, and no longer competed as an independent company. In November 2005, a book written by a long time Informix employee was released that chronicled the battle between Sybase and Informix.

As of 2006, Oracle is the leader in the database market share by revenue, followed by IBM, and then Microsoft SQL Server.Sybase is well behind its major competitors in the enterprise database market, with 3% market share. Investment banking is one of Sybase’s largest client bases, where optimized installations of ASE and tuned procedures still provide the biggest bang for the footprint.

Following a downturn in the late 1990’s, Sybase returned to profitability under the management of John Chen in 2000, has maintained profitability since then and continues to reinvent itself with a new ‘Unwired Enterprise’ strategy. The ‘Unwired Enterprise’ vision is about allowing companies to deliver data to mobile devices in the field as well as traditional desktops, and combines technology from Sybase’s existing data management products with its new mobility products. Sybase has expanded into the mobile space through a series of acquisitions of enterprise and mobile software companies. In 2006, Sybase completed the acquisition of Mobile 365, later renamed Sybase 365, allowed Sybase to enter the mobile messaging and mobile commerce market. Sybase has maintained a strong foothold in its data management products. It makes a number of data management products including Adaptive Server Enterprise, Sybase IQ, a data analytics warehouse system, and Replication Server, a vendor-neutral data movement system that helps address ever-growing data distribution and management requirements. Sybase has a strong presence in the financial services, telecommunications, technology and government markets[citation needed].

Sybase now works with other industry leaders in infrastructure, data storage and virtualization to optimize technologies for delivery into public and virtual private cloud environments that provide greater technology availability and flexibility to Sybase customers looking to Unwire their Enterprise. Sybase is focused on enabling enterprises to more effectively manage, analyze and mobilize data.

Sybase crossed the $1 billion dollar mark in 2007, and has delivered better than expected results despite the global recession.

In May 2010, SAP announced that it would be acquiring Sybase for $5.8bn.

Timeline

* 1984: Sybase (initially called Systemware) founded by Mark Hoffman, Bob Epstein, Jane Doughty and Tom Haggin out of Epstein’s home in California.
* 1984: For a few months, Sybase (still called Systemware) shares a suite of offices with Cimtec, Inc., in Berkeley, California.
* 1988: Sybase goes into partnership with Microsoft to port SQL Server to Windows and OS/2
* 1991: Sybase goes public at a (split adjusted) price of $6.75.
* 1993: Sybase and Microsoft dissolved their partnership. Microsoft bought the Windows code base from Sybase.
* November 14, 1994: Sybase acquires Powersoft, which bought Watcom earlier that year.
* 1995: Sybase launches PowerDesigner, a modeling and metadata management solution, following its acquisition of PowerAMC.
* 1995: Renames the main product SQL Server to its current name Adaptive Server Enterprise (ASE) for version 11.5.
* 1995: SQL Anywhere 5 was released. It included SQL Remote, SQL Central, Transact SQL syntax, and support for the Sybase Replication Server.
* 1996: Mitchell Kertzman PowerSoft CEO, appointed CEO
* 1996: Sybase launched Sybase IQ, the first column-based analytics platform.
* 1997: Sybase’s flagship database product renamed Adaptive Server Enterprise (ASE)with the release of version 11.5. Microsoft began independently developing its own product after being a Sybase distributor of the product for OS/2 and NT under the name “Microsoft SQL Server” in the mid ’90s. Sybase renamed its product to “Adaptive Server Enterprise” to better distinguish itself from MS SQL Server.
* October 1998: John Chen appointed Chairman, CEO, and President.
* 1998: SQL Anywhere 6 released, with new name “Adaptive Server Anywhere” as the engine and part of the “SQL Anywhere Studio” which now included SQL Modeler (later PowerDesigner), Java introduced to the database.
* 2000: iAnywhere Solutions, Inc was founded as a subsidiary of Sybase.
* June 20, 2001: Sybase acquires New Era of Networks, an application integration company.
* February 28, 2003: Sybase acquires AvantGo.
* 2003: Sybase launches the “Unwired Enterprise” strategy.
* 2004: Sybase acquires XcelleNet, frontline device management software, to enhance its Unwired Enterprise strategy
* September 12, 2005: Sybase releases ASE 15.0.
* August 7, 2006: iAnywhere announces release of SQL Anywhere 10
* November 8, 2006: Sybase completes the purchase of Mobile 365
* February, 2008: Sybase releases Adaptive Server Enterprise, Cluster Edition, with Oracle RAC-like shared-everything clusterability, based on open architecture.
* May 2008: Sybase IQ analytics server sets a new Guinness World Record by powering the world’s largest data warehouse. Sybase also launches RAP – The Trading Edition, an analytics platform for Wall Street.
* August 2008: Sybase promotes the Sybase Unwired Platform (SUP), a platform for developing mobile applications across a heterogeneous environment.
* September 2008: Sybase 365 expands its messaging interoperability with the launch of its global Multi-media Messaging Exchange, MMX 365.
* October 2008: Sybase Canada Limited is recognized as one of Waterloo Area’s Top Employers, as announced in the Waterloo Region Record, Guelph Mercury and Cambridge Times.
* January 21, 2009: Sybase acquires mPayment solutions provider paybox.
* March 2009: Sybase and SAP partner to deliver the new SAP Business Suite software to iPhone, Windows Mobile, BlackBerry and other devices.
* September 2009: Sybase and Verizon partner to manage mobility solutions for enterprises worldwide through Verizon’s Managed Mobility Solutions, which utilizes Sybase’s enterprise device management platform.
* May 12, 2010: SAP announced its intent to acquire Sybase Inc for $6 billion.

Products

Sybase’s main products include: Data Management Products

* Adaptive Server Enterprise (ASE) – Enterprise Class RDBMS and Column-oriented DBMS storage platform.
* Advantage Database Server (ADS) – Relational Database Management System
* Sybase Replication Server – a platform for data replication and movement between database systems, including Sybase and Oracle

Analytics Products

* Sybase IQ – a data warehousing and business intelligence RDBMS
* RAP the Trading Edition- a capital markets analytics platform
* Sybase Complex Event Processing – Optimized real-time risk and trade analytics software

Mobility Products

* SQL Anywhere – RDBMS with a small footprint designed for mobility
* Afaria – Mobile Device management and security software
* Sybase Unwired Platform (SUP) – a framework for developing mobile applications
* SMS Ad Exchange – an SMS mobile advertising service.
* GRX 365 – network performance and security
* mBanking 365 – a mobile banking product
* MMS 365 – a content delivery gateway
* MMX 365 – a messaging exchange
* Sybase 365 mCommerce Solution – an end-to-end solution for mBanking, mPayments and mRemittance

Tools

* PowerBuilder – a rapid application development (RAD) tool.
* PowerDesigner – a modeling and design tool

Subsidiaries

* Sybase 365
* Sybase iAnywhere

User groups

There are many Sybase-centric user groups around the world. The International Sybase User Group (ISUG), with members in more than 60 countries, acts as an umbrella organization for these groups, providing logistical support for user group meetings and other events.

Spatial Implementation

Sybase Inc. is partnered with The Boeing Company who develops and licenses Spatial Query Server for Sybase. Spatial Query Server spatially enables a Sybase ASE Database.

* SQS Boeing’s Spatial Query Server

How to connect sql server 2005 by using windows authentication from a client computer to a server?

May 13th, 2010

Windows Authentication in this case implies that you’re going to pass on whatever you’re logged into Windows with.

If when your XP machine starts, you log in as user Fred with password ‘lovesql’, then that’s what it’s going to send on to the server through Windows Authentication.

If you have a user set up in SQL, you’ll need to instead choose “SQL Server Authentication”. Then you can type in the user and password directly.

But that will need to be a user that’s identified directly in the SQL Server, not a domain account.

CCNA SSPO Exam (640-760) Practice

May 7th, 2010

Use the following resources to help you prepare for your exam. These tools are meant to supplement your learning experience and exam preparation.

The following review questions are taken from the current SSPO curriculum. These review questions do not reflect the actual questions you will receive on the live certification exam. They are only meant to supplement your learning experience.

Read the rest of this entry »

CCNA SSPO Exam (640-760) Study/Learn

May 7th, 2010

Use the following resources to help you prepare for your exam. These tools are meant to supplement your learning experience and exam preparation.

Recommended Classroom Training

The following course is the recommended training for this exam:

Read the rest of this entry »

640-760 SSPO Exam Topics (Blueprint)

May 7th, 2010

The following information provides general guidelines for the content likely to  be included on the Supporting Cisco Service Provider IP NGN Operations exam.  However, other related topics may also appear on any specific delivery of the  exam.

Read the rest of this entry »