John Hood <
[email protected]> wrote:
I'm trying to get a handle on MySQL and PHP. I started monkeying with
MySQLFront last night to see what I could pick up. I quickly got
stymied by the fact that I didn't understand how to translate MSAccess
data types to MySQL. For that matter, I don't know much about SQL
either. Want to learn though. I guess that MSAccess does more
handholding than I thought

Does anyone have suggestions for help for
goobs who are taking baby steps from MSAccess to Mysql or PHP?
Are you also trying to move DB's created in MS Access to MySQL?
http://dev.mysql.com/doc/mysql/en/Features.html
"Connectivity
Clients can connect to the MySQL server using TCP/IP sockets on any
platform. On Windows systems in the NT family (NT, 2000, or XP),
clients can connect using named pipes. On Unix systems, clients can
connect using Unix domain socket files.
The Connector/ODBC (MyODBC) interface provides MySQL support for
client programs that use ODBC (Open Database Connectivity)
connections. For example, you can use MS Access to connect to your
MySQL server. Clients can be run on Windows or Unix. MyODBC source is
available. All ODBC 2.5 functions are supported, as are many others.
See section 22.1 MySQL ODBC Support."
It looks like MS Access can connect to the MYSQL database. If so, this
would probably be the easiest route to transfer existing structures.
There are differences in data types, but from what I've seen MySQL
allows for larger values than ACCESS, so there should be no problems
in moving the data.
Here are the data types for MySQL:
http://dev.mysql.com/doc/mysql/en/Numeric_types.html
On the left panel you can choose the other data types.
-----------------------------------------------------------------------
I'm working in SQLPLUS (Oracle) and there are many similarities. I'm
not sure exactly what the differences are.
Once logged onto the server we must type > SQLPLUS
to start the application. After logging onto sqlplus any query or
series of commands can be run.
This is a script to create and slightly populate two tables we are
working on as a project. The file name is "employee.sql" and is
executed by typing "@employee" in sqlplus:
-----------------------------------------------------------------------
CREATE TABLE STORE
( STOREID CHAR(15) NOT NULL,
MANAGERID CHAR(9) NOT NULL,
STOREHOURS CHAR(40) NOT NULL,
ADDRESS VARCHAR(40),
SALESTAX FLOAT,
PHONENUM CHAR(10),
PRIMARY KEY (STOREID));
INSERT INTO STORE
VALUES ('123456789','726381982','M - F 9:00 to 5:00 pm',
'142 Hudson St, Houston, TX, 75934', .0825, '4561234567');
CREATE TABLE EMPLOYEE
( EMPLOYEEID CHAR(9) NOT NULL,
LNAME VARCHAR(15) NOT NULL,
FNAME VARCHAR(15) NOT NULL,
MNAME VARCHAR(15),
VACATIONDUE INTEGER,
DEPARTMENT CHAR(20),
HIREDDATE DATE NOT NULL,
POSITION CHAR(15),
MANAGERID CHAR(9) NOT NULL,
STOREID CHAR(15) NOT NULL,
DATEOFBIRTH DATE,
EMPLOYEETYPE CHAR(15),
WAGETYPE CHAR(10) NOT NULL,
SICKLEAVEDUE INTEGER,
ADDRESS VARCHAR(40),
PRIMARYPHONE CHAR(10),
ESSN CHAR(9) NOT NULL,
SEX CHAR(1),
PRIMARY KEY (EMPLOYEEID),
FOREIGN KEY (STOREID) REFERENCES STORE(STOREID),
FOREIGN KEY (MANAGERID) REFERENCES EMPLOYEE(EMPLOYEEID));
INSERT INTO EMPLOYEE
VALUES
('726381982','Magee','Fred','Hansel',2,'CheckOut','12-Jan-02',
'Manager','726381982','123456789','12-Nov-65','Manager','Salary',10,
'342 Warly Ln, Houston, TX, 75934','4562129999','122341345','M');
-----------------------------------------------------------------------
This creates two tables.
The query (typed or in a script):
SQL> select employeeid, fname, lname
would return:
EMPLOYEEID FNAME LNAME
-------------- -------- --------
726381982 Fred Magee
since this is the only employee in the employee table.