If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > Database Server Software > MySQL > setting up table relationships

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 07-21-04, 13:10
-Dman100- -Dman100- is offline
Registered User
 
Join Date: Jan 2004
Posts: 124
setting up table relationships

I'm looking for information or resources on setting up table relationships in MySQL? I'm familiar with setting up table relationships in Access, but new to MySQL. I apologize for the novice question here?

Thanks in advance.
-Dman100-
Reply With Quote
  #2 (permalink)  
Old 07-21-04, 14:08
1andyw 1andyw is offline
Registered User
 
Join Date: Mar 2004
Location: Erie, PA
Posts: 8
My documentation file states that table type InnoDB is the only type that will allow foreign keys. Check: mysql/Docs/manual_toc.html/paragraph 14.4.5.

Also, have you checked out "phpmyadmin" as a user interface? If you have not, check it out. I know of a decent tutorial for that feature. PM me if you want that url.

Andy
Reply With Quote
  #3 (permalink)  
Old 07-21-04, 14:57
-Dman100- -Dman100- is offline
Registered User
 
Join Date: Jan 2004
Posts: 124
Hi Andy,
Thanks for replying my post. I'm completely new to MySQL. Will ASP work okay with MySQL? I always see PHP as the server side language for MySQL. I'm currently just testing out MySQL and want to build a very simple database with two tables, create a relationship between the two tables, make a connection and use ASP write some information to the tables. Easy in Access to do, but I'm struggling with MySQL.

Thanks,
-Dman100-
Reply With Quote
  #4 (permalink)  
Old 07-21-04, 21:20
1andyw 1andyw is offline
Registered User
 
Join Date: Mar 2004
Location: Erie, PA
Posts: 8
I should defer to the experienced members. My knowledge of mysql is very limited. My knowledge of ASP is zip. Sorry. Andy
Reply With Quote
  #5 (permalink)  
Old 07-21-04, 21:40
r937 r937 is offline
SQL Consultant
 
Join Date: Apr 2002
Location: Toronto, Canada
Posts: 19,534
Quote:
Originally Posted by -Dman100-
Will ASP work okay with MySQL?
absolutely yes

mysql doesn't have an equivalent for microsoft access relationships, which are merely a convenience for generating the query syntax for joining tables (oh, and sometimes for enforcing relational integrity)

in mysql you have to write the joins yourself, and handle the integrity in your app
__________________
r937.com | rudy.ca
please visit Simply SQL and buy my book
Reply With Quote
  #6 (permalink)  
Old 08-24-04, 06:53
1andyw 1andyw is offline
Registered User
 
Join Date: Mar 2004
Location: Erie, PA
Posts: 8
load data local infile error

mysql> LOAD DATA LOCAL INFILE "C:/APACHE/HTDOCS/SURVEY/cfst.csv" INTO TABLE surv
ey(surid,ruid,inputdate,formno,clientname,age,sex, consumer,relationship,relation
name,collmethod,mostlike,leastlike,othertext,genq, qualq,effectq,accessq,location
,hours,parking,
-> transportation,waitingarea,timewaiting,ADA,appoint ment,callsreturned,staf
f,other);
Query OK, 617 rows affected (0.44 sec)
Records: 617 Deleted: 0 Skipped: 0 Warnings: 17893

The above successfully loaded all the files into my mysql db however, all fields inthe mysql db record "Null" except he first field, surid. What shoud I look for to made this worK. I was careful to make the the fields were in idenical order, that the field names were exactly the same, but still no go. Your help would be appreciated. Andy
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On