Results 1 to 5 of 5

Thread: Mysql select from multiple tables for php.

  1. #1
    Join Date
    Apr 2008
    Posts
    242

    Mysql select from multiple tables for php.

    Hi,

    I want some help with PHP mySql.
    Can you please let me know how to make a query to talk with different tables?
    I have some problem with the 2 tables with id name field. How can I give it an auto_increment nature?
    please help me with the syntax atleast.

    Thanks in advance.

  2. #2
    Join Date
    Apr 2008
    Posts
    49

    Re: Mysql select from multiple tables for php.

    SELECT from multiple MySQL Tables

    Code:
    SELECT fulltxt.pqid AS candidate_ft, citations.chid
    FROM citations,fulltxt
    WHERE citations.issn = fulltxt.issn
    AND citations.volume = fulltxt.volume
    AND citations.issue = fulltxt.issue
    AND citations.year = fulltxt.year
    AND citations.spage = fulltxt.spage
    AND citations.pqid = ''
    ;

  3. #3
    Join Date
    Apr 2008
    Posts
    25

    Re: Mysql select from multiple tables for php.

    I have some huge database with around 50 tables & a another table to have the names of all those tables.
    I want to know a query that will select from these table & show me a list of results to see at a glance. Ill be able to look as a whole?
    Please help me if this can be done?

  4. #4
    Join Date
    Feb 2008
    Posts
    1,852

    Re: Mysql select from multiple tables for php.

    hey bayz you need to learn: Database Normalization

    Normalization is a part of relational theory, which requires that each relation (AKA table) has a primary key. As a result, this article assumes that all tables have primary keys, without which a table cannot even be considered to be in first normal form.

    Database normalization is a process by which an existing schema is modified to bring its component tables into compliance with a series of progressive normal forms.

  5. #5
    Join Date
    Oct 2005
    Posts
    2,393

    Re: Mysql select from multiple tables for php.

    SELECT Syntax for multiple mysql tables.

    Code:
    SELECT
        [ALL | DISTINCT | DISTINCTROW ]
          [HIGH_PRIORITY]
          [STRAIGHT_JOIN]
          [SQL_SMALL_RESULT] [SQL_BIG_RESULT] [SQL_BUFFER_RESULT]
          [SQL_CACHE | SQL_NO_CACHE] [SQL_CALC_FOUND_ROWS]
        select_expr [, select_expr ...]
        [FROM table_references
        [WHERE where_condition]
        [GROUP BY {col_name | expr | position}
          [ASC | DESC], ... [WITH ROLLUP]]
        [HAVING where_condition]
        [ORDER BY {col_name | expr | position}
          [ASC | DESC], ...]
        [LIMIT {[offset,] row_count | row_count OFFSET offset}]
        [PROCEDURE procedure_name(argument_list)]
        [INTO OUTFILE 'file_name' export_options
          | INTO DUMPFILE 'file_name'
          | INTO var_name [, var_name]]
        [FOR UPDATE | LOCK IN SHARE MODE]]

Similar Threads

  1. MySQL: Entering data in tables
    By Botan in forum Software Development
    Replies: 2
    Last Post: 22-12-2010, 05:44 AM
  2. How to manage databases and tables in MySQL?
    By Aahlaadith in forum Software Development
    Replies: 5
    Last Post: 17-12-2010, 07:18 AM
  3. How to detect failure of MySQL database tables
    By Agneya in forum Software Development
    Replies: 5
    Last Post: 27-02-2010, 04:40 AM
  4. How to create MySQL Database and Tables in PHP?
    By Orton in forum Software Development
    Replies: 4
    Last Post: 23-02-2010, 06:45 AM
  5. How to select multiple table in MySql
    By Doroteo in forum Software Development
    Replies: 4
    Last Post: 05-11-2009, 09:28 PM

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Page generated in 1,751,333,793.72897 seconds with 16 queries