TRIAL Move the mouse over tables to read the comments 1 Sample Layout with Groups Read table & column comments as mouse-over tooltips. Generated using DbSchema - www.dbschema.com staff store film film_actor test_index_sync Fk fk_address_city address ref city ( city_id ) city_id Fk fk_city_country city ref country ( country_id ) country_id Fk fk_customer_address customer ref address ( address_id ) address_id Fk fk_customer_store customer ref store ( store_id ) store_id Fk fk_film_language film ref language ( language_id ) language_id Fk fk_film_language_original film ref language ( original_language_id -> language_id ) original_language_id Fk fk_film_actor_actor film_actor ref actor ( actor_id ) actor_id Fk fk_film_actor_film film_actor ref film ( film_id ) film_id Fk fk_film_category_category film_category ref category ( category_id ) category_id Fk fk_film_category_film film_category ref film ( film_id ) film_id Fk fk_inventory_film inventory ref film ( film_id ) film_id Fk fk_inventory_store inventory ref store ( store_id ) store_id Fk fk_payment_customer payment ref customer ( customer_id ) customer_id Fk fk_payment_rental payment ref rental ( rental_id ) rental_id Fk fk_payment_staff payment ref staff ( staff_id ) staff_id Fk fk_rental_customer rental ref customer ( customer_id ) customer_id Fk fk_rental_inventory rental ref inventory ( inventory_id ) inventory_id Fk fk_rental_staff rental ref staff ( staff_id ) staff_id Fk fk_store_address store ref address ( address_id ) address_id Fk fk_store_staff store ref staff ( manager_staff_id -> staff_id ) manager_staff_id Fk fk_staff_address staff ref address ( address_id ) address_id Fk fk_staff_store staff ref store ( store_id ) store_id actorTable sakila.actor Pk pk_actor ( actor_id ) actor_idactor_id * smallint Referred by film_actor ( actor_id ) first_namefirst_name * varchar(45) idx_actor_last_name ( last_name ) last_namelast_name * varchar(45) last_updatelast_update * timestamp default CURRENT_TIMESTAMP addressTable sakila.address Pk pk_address ( address_id ) address_idaddress_id * smallint Referred by customer ( address_id ) Referred by staff ( address_id ) Referred by store ( address_id ) addressaddress * varchar(50) address2address2 varchar(50) districtdistrict * varchar(20) idx_fk_city_id ( city_id ) city_idcity_id * smallint References city ( city_id ) postal_codepostal_code varchar(10) phonephone * varchar(20) idx_location ( location ) locationlocation * geometry last_updatelast_update * timestamp default CURRENT_TIMESTAMP categoryTable sakila.category Pk pk_category ( category_id ) category_idcategory_id * tinyint Referred by film_category ( category_id ) namename * varchar(25) last_updatelast_update * timestamp default CURRENT_TIMESTAMP cityTable sakila.city Pk pk_city ( city_id ) city_idcity_id * smallint Referred by address ( city_id ) citycity * varchar(50) idx_fk_country_id ( country_id ) country_idcountry_id * smallint References country ( country_id ) last_updatelast_update * timestamp default CURRENT_TIMESTAMP countryTable sakila.country Pk pk_country ( country_id ) country_idcountry_id * smallint Referred by city ( country_id ) countrycountry * varchar(50) last_updatelast_update * timestamp default CURRENT_TIMESTAMP customerTable sakila.customer Pk pk_customer ( customer_id ) customer_idcustomer_id * smallint Referred by payment ( customer_id ) Referred by rental ( customer_id ) idx_fk_store_id ( store_id ) store_idstore_id * tinyint References store ( store_id ) first_namefirst_name * varchar(45) idx_last_name ( last_name ) last_namelast_name * varchar(45) emailemail varchar(50) idx_fk_address_id ( address_id ) address_idaddress_id * smallint References address ( address_id ) activeactive * bit default 1 create_datecreate_date * datetime last_updatelast_update * timestamp default CURRENT_TIMESTAMP filmTable sakila.film Pk pk_film ( film_id ) film_idfilm_id * smallint Referred by film_actor ( film_id ) Referred by film_category ( film_id ) Referred by inventory ( film_id ) idx_title ( title ) titletitle * varchar(255) descriptiondescription text release_yearrelease_year year idx_fk_language_id ( language_id ) language_idlanguage_id * tinyint References language ( language_id ) idx_fk_original_language_id ( original_language_id ) original_language_idoriginal_language_id tinyint References language ( original_language_id -> language_id ) rental_durationrental_duration * tinyint default 3 rental_raterental_rate * decimal(4,2) default 4.99 lengthlength smallint replacement_costreplacement_cost * decimal(5,2) default 19.99 ratingrating enum('g','pg','pg-13','r','nc-17') default 'G' special_featuresspecial_features set('trailers','commentaries','deleted scenes','behind the scenes') last_updatelast_update * timestamp default CURRENT_TIMESTAMP film_actorTable sakila.film_actor Pk pk_film_actor ( actor_id, film_id ) actor_idactor_id * smallint References actor ( actor_id ) Pk pk_film_actor ( actor_id, film_id ) idx_fk_film_id ( film_id ) film_idfilm_id * smallint References film ( film_id ) last_updatelast_update * timestamp default CURRENT_TIMESTAMP film_categoryTable sakila.film_category Pk pk_film_category ( film_id, category_id ) film_idfilm_id * smallint References film ( film_id ) Pk pk_film_category ( film_id, category_id ) fk_film_category_category ( category_id ) category_idcategory_id * tinyint References category ( category_id ) last_updatelast_update * timestamp default CURRENT_TIMESTAMP inventoryTable sakila.inventory Pk pk_inventory ( inventory_id ) inventory_idinventory_id * mediumint Referred by rental ( inventory_id ) idx_fk_film_id ( film_id ) idx_store_id_film_id ( store_id, film_id ) film_idfilm_id * smallint References film ( film_id ) idx_store_id_film_id ( store_id, film_id ) store_idstore_id * tinyint References store ( store_id ) last_updatelast_update * timestamp default CURRENT_TIMESTAMP languageTable sakila.language Pk pk_language ( language_id ) language_idlanguage_id * tinyint Referred by film ( language_id ) Referred by film ( original_language_id -> language_id ) namename * char(20) last_updatelast_update * timestamp default CURRENT_TIMESTAMP paymentTable sakila.payment Pk pk_payment ( payment_id ) payment_idpayment_id * smallint idx_fk_customer_id ( customer_id ) customer_idcustomer_id * smallint References customer ( customer_id ) idx_fk_staff_id ( staff_id ) staff_idstaff_id * tinyint References staff ( staff_id ) fk_payment_rental ( rental_id ) rental_idrental_id int References rental ( rental_id ) amountamount * decimal(5,2) payment_datepayment_date * datetime last_updatelast_update * timestamp default CURRENT_TIMESTAMP rentalTable sakila.rental Pk pk_rental ( rental_id ) rental_idrental_id * int Referred by payment ( rental_id ) Unq rental_date ( rental_date, inventory_id, customer_id ) rental_daterental_date * datetime Unq rental_date ( rental_date, inventory_id, customer_id ) idx_fk_inventory_id ( inventory_id ) inventory_idinventory_id * mediumint References inventory ( inventory_id ) Unq rental_date ( rental_date, inventory_id, customer_id ) idx_fk_customer_id ( customer_id ) customer_idcustomer_id * smallint References customer ( customer_id ) return_datereturn_date datetime idx_fk_staff_id ( staff_id ) staff_idstaff_id * tinyint References staff ( staff_id ) last_updatelast_update * timestamp default CURRENT_TIMESTAMP storeTable sakila.store Pk pk_store ( store_id ) store_idstore_id * tinyint Referred by customer ( store_id ) Referred by inventory ( store_id ) Referred by staff ( store_id ) Unq idx_unique_manager ( manager_staff_id ) manager_staff_idmanager_staff_id * tinyint References staff ( manager_staff_id -> staff_id ) idx_fk_address_id ( address_id ) address_idaddress_id * smallint References address ( address_id ) last_updatelast_update * timestamp default CURRENT_TIMESTAMP test_index_syncTable sakila.test_index_sync Pk pk_test_index_sync ( id ) idid * int namename varchar(100) testboolTable sakila.testbool Pk pk_testbool ( id ) idid * int boolfieldboolfield * bit testchartTable sakila.testchart Pk pk_testchart ( label ) labellabel * int textaxistextaxis * varchar(250) intaxisintaxis * int dateaxisdateaxis * date v1v1 * int v2v2 * int v3v3 * int actor_infoView sakila.actor_info actor_idactor_id smallint first_namefirst_name varchar last_namelast_name varchar film_infofilm_info text sales_by_storeView sakila.sales_by_store storestore varchar managermanager varchar total_salestotal_sales decimal staff_listView sakila.staff_list IDID tinyint namename varchar addressaddress varchar zip codezip code varchar phonephone varchar citycity varchar countrycountry varchar SIDSID tinyint staffTable sakila.staff Pk pk_staff ( staff_id ) staff_idstaff_id * tinyint Referred by payment ( staff_id ) Referred by rental ( staff_id ) Referred by store ( manager_staff_id -> staff_id ) first_namefirst_name * varchar(45) last_namelast_name * varchar(45) idx_fk_address_id ( address_id ) address_idaddress_id * smallint References address ( address_id ) picturepicture blob emailemail varchar(50) idx_fk_store_id ( store_id ) store_idstore_id * tinyint References store ( store_id ) activeactive * bit default 1 usernameusername * varchar(16) passwordpassword varchar(40) last_updatelast_update * timestamp default CURRENT_TIMESTAMP You may create multiple layouts with the same or different tables. Layouts will be saved to project file. Double-click any column, foreign key or table headers to edit.

Powered by DbSchema