text
stringlengths
6
9.38M
-- phpMyAdmin SQL Dump -- version 4.5.1 -- http://www.phpmyadmin.net -- -- Host: 127.0.0.1 -- Generation Time: Jan 11, 2018 at 07:31 AM -- Server version: 10.1.9-MariaDB -- PHP Version: 5.6.15 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLI...
-- phpMyAdmin SQL Dump -- version 4.8.5 -- https://www.phpmyadmin.net/ -- -- Host: localhost -- Generation Time: May 26, 2019 at 02:50 PM -- Server version: 5.7.26-0ubuntu0.16.04.1 -- PHP Version: 7.0.33-0ubuntu0.16.04.4 CREATE DATABASE IF NOT EXISTS smart_home; USE smart_home; SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"...
create table user_id_auto ( id bigint default nextval('user_id_seq'::regclass) not null constraint user_id_pk primary key, name varchar ); alter table user_id_auto owner to len; create table user_protobuf_id ( id bigint not null constraint user_protobuf_id_pk primar...
1. Import this file into an empty PostgreSQL database. Note: the file contains a lot of data and may take a while to run; your terminal should return to the command prompt once the import is complete. $ createdb lesson_3 $ psql lesson_3 < tickets.sql 2. Write a query that determines how many tickets have been sol...
-- Adminer 4.3.1 MySQL dump SET NAMES utf8; SET time_zone = '+00:00'; SET foreign_key_checks = 0; SET sql_mode = 'NO_AUTO_VALUE_ON_ZERO'; DROP TABLE IF EXISTS `commande`; CREATE TABLE `commande` ( `id` int(11) NOT NULL AUTO_INCREMENT, `nom` varchar(80) NOT NULL, `prenom` varchar(80) NOT NULL, `mail` varchar(8...
-- MySQL dump 10.13 Distrib 8.0.17, for macos10.14 (x86_64) -- -- Host: localhost Database: eteaching -- ------------------------------------------------------ -- Server version 8.0.17 /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; /*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS ...
-- phpMyAdmin SQL Dump -- version 5.0.2 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Generation Time: Sep 21, 2020 at 11:52 AM -- Server version: 10.4.13-MariaDB -- PHP Version: 7.2.32 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIE...
CREATE PROCEDURE usp_InserRole(@id int,@name varchar(10)) AS BEGIN INSERT INTO Roles(Role_ID,Role_name) VALUES(@id,@name); END
CREATE TABLE Tbl_Product_Sales ( fld_product_id varchar(10) NOT NULL, -- internal identification code of product sold fld_sale_id varchar(10) NOT NULL, -- internal identfication code of sales transaction fld_product_quantity int Default 1, -- quantity of purchased product fld_product_unit_price decimal(7,2), -- u...
use sakila; -- How many distinct (different) actors' last names are there? select count(distinct last_name) from actor; -- In how many different languages where the films originally produced? (Use the column language_id from the film table) select count(distinct language_id) from film; -- How many movies were releas...
CREATE TABLE School ( id BIGINT AUTO_INCREMENT, name VARCHAR(50) NOT NULL , content VARCHAR(100), del INT DEFAULT 1, version INT DEFAULT 1, create_date TIMESTAMP DEFAULT CURRENT_TIMESTAMP , modify_date TIMESTAMP DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP, PRIMARY KEY (id) ); DROP TABLE scho...
/* Navicat MySQL Data Transfer Source Server : localhost Source Server Version : 50621 Source Host : localhost:3306 Source Database : pem Target Server Type : MYSQL Target Server Version : 50621 File Encoding : 65001 Date: 2015-11-05 17:46:39 */ SET FOREIGN_KEY_CHEC...
-- For example, given the above Employee table, the nth highest salary where n = 2 is 200. If there is no nth highest salary, then the query should return null. CREATE FUNCTION getNthHighestSalary(N INT) RETURNS INT BEGIN DECLARE M INT; SET M=N-1; RETURN ( # Write your MySQL query statement below. SELECT...
select * from confirmed_task where confirmation_id = $1;
CREATE TABLE users(username varchar(255) primary key not null, pagequota unsigned int, lastjob datetime, pagecount unsigned int); CREATE TABLE config(key varchar(255), value unsigned int); INSERT INTO config (key, value) VALUES ( "lastupdate", strftime('%s', 'now') );
-- phpMyAdmin SQL Dump -- version 3.4.11.1deb2 -- http://www.phpmyadmin.net -- -- Host: localhost -- Generation Time: Jun 05, 2014 at 06:47 PM -- Server version: 5.5.35 -- PHP Version: 5.4.4-14+deb7u9 SET SQL_MODE="NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_S...
#Changement de mail OK UPDATE `user` SET `mail_user` = :mail, `clef_user` = :clef WHERE `login_user` = :login
-- q1 select course_id from section where semester = 'Fall' and year = 2009 UNION select course_id from section where semester = 'Spring' and year = 2010; -- q2 select course_id from section where semester = 'Fall' and year = 2009 INTERSECT select course_id from section where semester = 'Spring' and year = 2010; -- ...
--Building Classes INSERT INTO BuildingClasses (Type, DefaultBuilding, Description) VALUES ('BUILDINGCLASS_RELIC_HAN', 'BUILDING_RELIC_HAN', 'TXT_KEY_BUILDING_RELIC_HAN'); --================================================================ --Building Definitions --============================================...
INSERT INTO artist (name) VALUES ('Jinglin_Joe'), ('Buckets_Mitchell'), ('Stifle_Tower'); SELECT * FROM artist WHERE name ILIKE 'a%' ORDER BY name ASC LIMIT 5; SELECT first_name, last_name FROM employee WHERE city = ('Calgary') SELECT * FROM employee WHERE reports_to = 2; SELECT COUNT(*) FROM empl...
CREATE TABLE categories ( -- database keys id integer not null, -- primary data title text not null unique, slug text not null unique, -- secondary data description text , priority integer not null default (3), -- server information c...
--Query 1: CREATE TABLE AUTHORS (id SERIAL PRIMARY KEY, name VARCHAR(255)); --This query will create a second table in the lab14_normal database named authors. Confirm the success of this command by typing \d authors in your SQL shell. You should see the authors table schema, as shown above. --Query 2: INSERT I...
insert into TODO values (10001, 'Learn spring 5', false, sysdate(), 'yusuf'); insert into TODO values (10002, 'Learn kubernetes', false, sysdate(), 'yusuf'); insert into TODO values (10003, 'Learn chef', false, sysdate(), 'yusuf');
# ************************************************************ # Sequel Pro SQL dump # Version 4541 # # http://www.sequelpro.com/ # https://github.com/sequelpro/sequelpro # # Host: 127.0.0.1 (MySQL 5.7.32) # Database: phpmvc # Generation Time: 2021-06-15 03:53:31 +0000 # ***********************************************...
LOAD DATA LOCAL INFILE "room.csv" INTO TABLE Room FIELDS TERMINATED BY ","; LOAD DATA LOCAL INFILE "user.csv" INTO TABLE User FIELDS TERMINATED BY ","; LOAD DATA LOCAL INFILE "userDepartment.csv" INTO TABLE UserDepartment FIELDS TERMINATED BY ","; LOAD DATA LOCAL INFILE "event.dat" INTO TABLE Event FIELDS TERMINATED BY...
show columns from STK_XQ_POST; select * from STK_XQ_POST; insert into STK_XQ_POST values (1, CURRENT_TIMESTAMP, false, 10, 'text', 'title', 'avatar_url', 100, null, false, null); insert into STK_XQ_POST values (2, CURRENT_TIMESTAMP, true, 5, 'text123', 'title123', 'avatar_url', 160, null, false, null); update STK_XQ...
DROP TABLE IF EXISTS chat; CREATE TABLE chat ( chat_id serial NOT NULL, sender_id int default 0, message varchar(255) NOT NULL, date timestamp without time zone NOT NULL default now() ); ALTER TABLE chat OWNER TO developers; GRANT ALL ON TABLE chat TO developers;
-- phpMyAdmin SQL Dump -- version 4.9.1 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Generation Time: Dec 23, 2019 at 05:33 PM -- Server version: 10.4.8-MariaDB -- PHP Version: 7.3.10 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OLD...
create table fleet ( id char(3) not null primary key, [name] varchar(50) ); create table ship ( id char(3) not null primary key, [name] varchar(50), date_finished varchar(10), fleet_id char(3) not null, foreign key (fleet_id) references fleet(id) ); create table sailor ( id char(4) no...
CREATE TABLE [wms].[Centros_Distribucion] ( [Id] INT IDENTITY (1, 1) NOT NULL, [Codigo] VARCHAR (20) NOT NULL, [Nombre] VARCHAR (50) NOT NULL, [Id_Tipo_Centro_Distribucion] INT NOT NULL, [Id_Ope...
create database uriage; create table uriage.hanbai(id int not null primary key, shouhin_id int, uriage int); create table uriage.shouhin(id int not null primary key, name varchar(20) CHARACTER SET utf8 COLLATE utf8_general_ci); create user 'testuser'@'localhost' identified by 'testuser’; grant all on uriage.* to 't...
-- phpMyAdmin SQL Dump -- version 5.0.2 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Waktu pembuatan: 29 Sep 2020 pada 16.39 -- Versi server: 10.4.13-MariaDB -- Versi PHP: 7.4.7 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CH...
SELECT coh.name, AVG(completed_at-started_at) AS average_assistance_request_duration FROM students stu JOIN cohorts coh ON coh.id = stu.cohort_id JOIN assistance_requests req ON req.student_id = stu.id GROUP BY coh.name ORDER BY average_assistance_request_duration DESC LIMIT 1;
create table movieTable ( `movieID` int unsigned not null auto_increment primary key, `movieName` char(50) not null ); create table slotTable ( `slotID` int unsigned not null auto_increment primary key, `movieID` text not null, `day` text not null, `time` time not null ); create table seatsTable ( `seatID` in...
SELECT DISTINCT v0123.product, COALESCE(lang_en, lang_zh, lang_de, lang_fr) AS lang, COALESCE(review_en_id, review_zh_id, review_de_id, review_fr_id) AS review_id FROM ( SELECT v012.product AS product, review_en_id, lang_en, review_zh_id, lang_zh, review_de...
CREATE TABLE lms_create_table_test (lms_test_id INTEGER, lms_test_timestamp TIMESTAMP)
-- get a list of hashes, user_ids, and usernames for future use. USE cs340_smithb22; Select credential.user_id, credential.hash, credential.exp_date, user.username FROM credential INNER JOIN user on credential.user_id=user.id -- return all hashes and experation dates for a given usernames USE cs340_smithb22; SELE...
/* Formatted on 17/06/2014 18:06:29 (QP5 v5.227.12220.39754) */ CREATE OR REPLACE FORCE VIEW MCRE_OWN.V_MCRE0_ST_RICH_MON ( ID_DPER, COD_SNDG ) AS WITH T_MCRE0_FL_RICH_MON AS (SELECT (SELECT TO_NUMBER ( TO_CHAR ( TO_DATE (TRIM (PERIODO_RIF)...
-- -- Drop existing objects -- DROP SCHEMA IF EXISTS "order" CASCADE; -- -- Order schema -- CREATE SCHEMA IF NOT EXISTS "order"; -- -- Cart -- CREATE SEQUENCE "order".cart_id_seq INCREMENT 1 MINVALUE 1 START 1 CACHE 1; CREATE TABLE "order".cart ( "id" integer NOT NU...
-- phpMyAdmin SQL Dump -- version 4.4.10 -- http://www.phpmyadmin.net -- -- Client : localhost -- Généré le : Jeu 04 Février 2016 à 18:46 -- Version du serveur : 5.5.42 -- Version de PHP : 5.6.10 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; -- -- Base de données : `ecv_goodplanet` -- -- ---...
USE SCLOUD_PHONE; DROP TABLE IF EXISTS PHONE_TABS_CLICK; DROP TABLE IF EXISTS PHONE_TABS_CLICK_SUMMARY; DROP TABLE IF EXISTS PHONE_TABS_CLICK_SUMMARY_OBS; DROP TABLE IF EXISTS PHONE_ACTIVITY_DAILY; CREATE TABLE PHONE_TABS_CLICK ( IMEI STRING COMMENT '手机IMEI号', TAB_TYPE CHAR(1) COMMEN...
create table if not exists t11.t0 (a int, b int, PRIMARY KEY(a)); create table if not exists t11.t1 (a int, b int, PRIMARY KEY(a)); create table if not exists t11.t2 (a int, b int, PRIMARY KEY(a)); create table if not exists t11.t3 (a int, b int, PRIMARY KEY(a)); create table if not exists t11.t4 (a int, b int, PRIMARY...
DELIMITER $$ CREATE PROCEDURE p_insert_user_info (IN P_UINAME VARCHAR(100),P_UIAGE TINYINT,P_UIID VARCHAR(100), P_UIPWD VARCHAR(100)) BEGIN DECLARE EXIT HANDLER FOR SQLEXCEPTION BEGIN GET DIAGNOSTICS CONDITION 1 @ER_NO= RETURNED_SQLSTATE, @ER_MSG=MESSAGE_TEXT; SELECT @ER_NO, @ER_MSG; ROLLBACK; E...
-- insertion d'entités dans les tables -- pour la table Client INSERT INTO Client(nom, prenom, adresse) VALUES ('de Funès', 'Louis', '85 rue de la Barre'), ('de Funès', 'Olivier', '85 rue de la Barre'), ('Grosso', 'Guy', '1 boulevard Foch'), ('Modo', 'Michel', '3 boulevard Foch'); -- pour la table modele...
drop table if exists employee; create table employee ( employee_id int, first_name varchar(32), last_name varchar(32), email varchar(32), phone_number varchar(32), hire_date date, salary float );
-- menu_panel INSERT INTO sw_ui_panel_styles VALUES (6133006549113932327,-1472711898,-1476066045,0,0,0,0,0,0,0,0,0,0); .quit
create table CONTENTREVIEW_ITEM ( id bigint generated by default as identity, contentId varchar(255) not null, userId varchar(255), siteId varchar(255), taskId varchar(255), externalId varchar(255), dateQueued timestamp, dateSubmitted timestamp, ...
-- Write queries to return the following: -- The following changes are applied to the "dvdstore" database.** -- 1. Add actors, Hampton Avenue, and Lisa Byway to the actor table. insert into actor(first_name,last_name) values('HAMPTON', 'AVENUE'),('LISA', 'BYWAY'); --select * --from actor -- 2. Add "Euclidean P...
--liquibase formatted sql --changeset lautaro:settlement_definition splitStatements:false -- creo la tabla settlement CREATE TABLE settlement( id SERIAL NOT NULL, date timestamp without time zone, amount NUMERIC(17,4), concept VARCHAR(250), chek_number NUMERIC(8), -- número de cheque en caso de que el pago se rea...
-- Problem 16 CREATE DATABASE SoftUni USE SoftUni CREATE TABLE Towns ( Id int IDENTITY NOT NULL, Name nvarchar(20) NOT NULL, CONSTRAINT PK_IdTown PRIMARY KEY (Id) ) CREATE TABLE Adresses ( Id int IDENTITY NOT NULL, AddressText nvarchar(50) NOT NULL, TownId int FOREIGN KEY REFERENCES Towns(Id) CONSTRAINT PK_IdAdress ...
--PROJECTS-- INSERT INTO PROJECT(project_id,title,description,owner_id,creation_date,is_deleted) VALUES (1, 'Skyroof App', 'Implement this API', 1, CURRENT_TIMESTAMP(), false); INSERT INTO PROJECT_COLLABORATORS(fk_project, fk_user) VALUES (1,1); INSERT INTO PROJECT_COLLABORATORS(fk_project, fk_user) VALUES (1,2); IN...
/* manager quản lý trên 2 nhân viên*/ USE coowell; SELECT (select last_name from employees where a.manager_id = employee_id) as name_manager ,manager_id, COUNT(manager_id) FROM employees a GROUP BY manager_id Having Count(manager_id) > 2;
-- phpMyAdmin SQL Dump -- version 5.1.0 -- https://www.phpmyadmin.net/ -- -- 主機: 127.0.0.1 -- 產生時間: 2021-04-01 03:34:28 -- 伺服器版本: 10.4.18-MariaDB -- PHP 版本: 8.0.3 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; /*!...
with source_data as ( select order_id , product_id , quantity , unit_price , discount /* Stitch extration */ , _sdc_extracted_at as last_elt_extract , _sdc_received_at , _sdc_sequence , _sdc_batched_at ...
INSERT INTO wlbPoint VALUES (7088, '31/2-N-14', '31/2-N-14 BY1H', 'TROLL', '054 ', 'DEVELOPMENT', 'Statoil Petroleum AS', 'NO', 'COSLPromoter', 'TROLL N1', '9999-12-31', '9999-12-31', NULL, NULL, 0, 'PRODUCTION', 341.000000, 'http://factpages.npd.no/FactPages/Default.aspx?nav1=wellbore'+'@'+'nav2=PageV...
USE employeesDB; INSERT INTO department (name) VALUES ("Sales"); INSERT INTO department (name) VALUES ("Engineering"); INSERT INTO department (name) VALUES ("Finance"); INSERT INTO department (name) VALUES ("Legal"); INSERT INTO role (title, salary, department_id) VALUES ("Sale...
alter table list add column sizeChoice integer; alter table list_item add column rank integer; alter table list_item add column is_chosen boolean;
CREATE TABLE year_statistics (id_month INT PRIMARY KEY AUTO_INCREMENT NOT NULL, month_name VARCHAR(10) UNIQUE NOT NULL, amount_of_orders INT NOT NULL, # total amount of orders per month couriers_shifts_per_month INT NOT NULL, # number of the shifts in total for all the courier per month average_check FLOAT NOT NULL);...
SELECT NULL AS TABLE_CAT, n.nspname AS TABLE_SCHEM, ct.relname AS TABLE_NAME, a.attname AS COLUMN_NAME, (i.keys).n AS KEY_SEQ, ci.relname AS PK_NAME FROM pg_catalog.pg_class ct JOIN pg_catalog.pg_attribute a ON (ct.oid = a.attrelid) JOIN pg_catalog.pg_namespace n ON (ct.re...
INSERT INTO igualas(id,nombre, slim_duracion, med_duracion, plus_duracion, slim, med, plus) VALUES (1,'empresariales', 3, 7, 10, 24000, 35000, 55000), (2,'estudiantiles', 3, 7, 10, 3000, 5000, 9500), (3,'mipymes', 3, 7, 10, 9000, 14000, 25000), (4,'abogados', 3, 7, 10, 24000, 35000, 55000), (5,'familias', 3, 7, 10, 240...
-- CS 61A Fall 2014 -- Name: Ganesh Prasad Rapolu -- Login: cs61a-yp create table parents as select "abraham" as parent, "barack" as child union select "abraham" , "clinton" union select "delano" , "herbert" union select "fillmore" , "abraham" union select "...
UPDATE Boek SET isbn=9789024532080, WHERE isbn=9789024532070; SELECT * FROM Boek;
-- drop database itcast; create database itcast default character set utf8; use itcast; create table it_user_info( ui_user_id bigint unsigned auto_increment comment '用户ID', ui_name varchar(64) not null comment '用户名', ui_passwd varchar(128) not null comment '密码', ui_age int unsigned null com...
SELECT USER_ID AS keeperId,USER_CNAME AS CName,USER_ENAME AS Ename, year(LEND_DATE) AS BorrowYear,COUNT(YEAR(LEND_DATE)) AS BorrowCnt FROM dbo.MEMBER_M LEFT JOIN dbo.BOOK_LEND_RECORD ON dbo.MEMBER_M.USER_ID = dbo.BOOK_LEND_RECORD.KEEPER_ID GROUP BY USER_ID,USER_CNAME,USER_ENAME,year(LEND_DATE) ORDER BY USER_ID, ye...
# Write your MySQL query statement below # Calculate the change in the global rankings after updating each team's points. ## Calculate ranks before and after the changes with ranks as (select T.team_id, T.name, rank() over (order by points desc, name) as rank_old, rank() over (order by points + poi...
create table award_funding_propoals_bk as select * from award_funding_proposals where award_id in ('106012','104880'); select * from award_funding_propoals_bk; Update Award_Funding_Proposals Set Proposal_ID = 5642 Where Award_ID = 104880 ; select * from Award_Funding_Proposals Where Award_ID = 104880 ; --inser...
-- -- @(#) dbcreate/cffbpfl/mysql/crsp_create_fbpfl.mysql -- -- net.sourceforge.MssCF.CFFBPfl -- -- Copyright (c) 2018 Mark Stephen Sobkow -- -- Licensed under the Apache License, Version 2.0 (the "License"); -- you may not use this file except in compliance with the License. -- You may obtain a copy of the License at...
/* # Upload https://bit.ly/state-names-unpartitioned (state-names-unpartitioned.zip) into S3 lesson-exercises-fname-lname bucket # Upload https://bit.ly/state-names-partitioned (state-names-partitioned.zip) into S3 lesson-exercises-fname-lname bucket # SSH into EC2 instance using EC2 Instance Connect # Start a screen...
-- 20/09/2019 - pickup_time for orders ALTER TABLE `orders` ADD `pickup_time` DATETIME NULL DEFAULT NULL AFTER `delivery_date`;
create table if not exists foss4g.bhmfoss4g ( gid serial primary key, code character varying(15), geom geometry(MultiPolygon, 4326)); insert into foss4g.bhmfoss4g (code, geom) select b.code, st_multi(st_intersection(a.geom, b.geom)) as geom from foss4g.bhmbuffer1000 a, foss4g.divisions b where ...
-- These indexes were added later to the 6.4 install DDL SQL scripts and may already be present on your system -- create index IDX_VInstLog_pInstId on VariableInstanceLog(processInstanceId); -- create index IDX_VInstLog_varId on VariableInstanceLog(variableId); -- create index IDX_VInstLog_pId on VariableIns...
CREATE TABLE FAM_MEMBER( MEM_NO INT NOT NULL PRIMARY KEY AUTO_INCREMENT ,ID VARCHAR(20) NOT NULL ,PASS VARCHAR(20) NOT NULL ,E_MAIL VARCHAR(100) NOT NULL ,MEM_PIC_PATH VARCHAR(255) ,NAME VARCHAR(20) NOT NULL ,BIRTHDAY VARCHAR(20) NOT NULL ,TEL INT NOT NULL ); ...
--script to stop unused properties from making it into the export UPDATE public."FileProperty" SET "AllowExport" = 'false' WHERE "Name" IN ('date_created','date_range','start_date','file_name_language','file_name_translation_language'); COMMIT;
/* Get hard drive capacities that are identical for two or more PCs. Result set: hd.*/ SELECT hd FROM pc GROUP BY hd HAVING count(model) >= 2
DROP DATABASE IF EXISTS react_colors; CREATE DATABASE react_colors; \c react_colors CREATE TABLE colors( id serial primary key, name varchar, hex varchar, red int, green int, blue int );
/* Welcome to the SQL mini project. You will carry out this project partly in the PHPMyAdmin interface, and partly in Jupyter via a Python connection. This is Tier 2 of the case study, which means that there'll be less guidance for you about how to setup your local SQLite connection in PART 2 of the case study. Th...
WITH DUPLICATE AS ( SELECT ROW_NUMBER() OVER(PARTITION BY Passangers ORDER BY Passangers) Pass, Vagons FROM LinkerT ) DELETE FROM DUPLICATE WHERE Pass > 1 SELECT * FROM LinkerT
select t1.*, t2.new_req, t2.all_oc_req, t3.new_keys, t3.alll_oc_keys, t3.new_rec_keys, t4.new_plan, t4.all_oc_plan, t4.new_rec_plan, t4.new_plan_exp, t4.all_oc_plan_exp, t4.new_rec_plan_exp, t4.new_trial, t4.all_oc_trial, t4.new_rec_trial, t4.new_trial_deal, t4.all_oc_trial_deal, t4.n...
INSERT INTO 'db_blog_pessoal','postagem'('date','texto','titulo',) VALUES ('2020-07-26 10:10:10.000','Eu estou aprendendo','API Rest Spring'); ALTER TABLE db_blog_pessoal DROP COLUMN column_date;
CREATE TABLE IF NOT EXISTS Account( Id INT AUTO_INCREMENT PRIMARY KEY, Name VARCHAR(255), Balance DECIMAL(20, 2), CurrencyCode VARCHAR(3), Status BOOLEAN, CreatedDate TIMESTAMP DEFAULT CURRENT_TIMESTAMP, UpdatedDate TIMESTAMP NULL); CREATE TABLE IF NOT EXISTS Transaction( Id INT AUTO_INCREMENT PRIMARY KEY, Tr...
#Турнирные таблицы турниров CREATE VIEW RFPL_table AS SELECT name, matches_complited AS 'matches', matches_win AS 'win', matches_draw AS 'draw', matches_loose AS 'loose', points FROM clubs JOIN tournaments_clubs ON clubs.id = club_id AND tournament_id = 1 ORDER BY points DESC; SELEC...
alter table data_${sid} add column copy_entry bytea;
/* Project Option: Coyote Residence Office TEAM: King James & The Knights of the Data Table Comments on Attributes for Student COMMENT BY: James Small */ COMMENT ON COLUMN student.student_number IS 'The number that uniquely identifies each student at the university - Format: 600001'; COMMENT ON COLUMN student.first_n...
set linesize 120 pagesize 200 trimspool on column username format a10 column osuser format a10 column sid format 99999 column object format a35 column type format a35 select s.username, s.sid, s.serial#, s.osuser, k.ctime, o.object_name object, k.kaddr, case l.locked_mode when 1 then 'No Lock' ...
-- phpMyAdmin SQL Dump -- version 4.9.7 -- https://www.phpmyadmin.net/ -- -- Servidor: localhost:8889 -- Tiempo de generación: 19-07-2021 a las 14:41:39 -- Versión del servidor: 5.7.32 -- Versión de PHP: 7.4.12 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; -- -- Base de datos: `asociados` -- -- -...
/* tbluser This table holds registred users data. */ DROP TABLE IF EXISTS tbrecipeimages, tblrecipesteps, tblrecipeingredients, tblrecipe, tbluser; CREATE TABLE `recipe`.`tbluser` ( `user_id` INT NOT NULL AUTO_INCREMENT, `username` VARCHAR(45) NULL, `pass` VARCHAR(50) NULL, `email_address` VARCHAR(500) NULL,...
-- phpMyAdmin SQL Dump -- version 5.0.2 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Generation Time: Jan 27, 2021 at 06:35 AM -- Server version: 10.5.5-MariaDB -- PHP Version: 7.3.11 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIEN...
CREATE TABLE Employees ( Id INT PRIMARY KEY IDENTITY, FirstName NVARCHAR(17) NOT NULL, LastName NVARCHAR(17) NOT NULL, Title NVARCHAR(30), Notes NVARCHAR(MAX) ) INSERT Employees (FirstName, LastName, Notes) VALUES ('Bruce', 'Wayne', NULL), ('Stanimir', 'Stanimirov', NULL), ('Roberto', 'Firmino', NULL) CREATE TABLE Cu...
--0insert with check option delete form employee_temp where department_id in (select department_id from departments d natural join locations lo where lo.country_id='UK'); insert into (select d.department_id , d.department_name , d.manager_id,d.location_id from departments d where location_id = (select location_id fr...
-- CreateEnum CREATE TYPE "SkillCatergory" AS ENUM ('PROG_LANG', 'PROG_TECH', 'OTHER'); -- CreateTable CREATE TABLE "Link" ( "id" SERIAL NOT NULL, "url" TEXT NOT NULL, "title" TEXT, "description" TEXT, "imageUrl" TEXT, PRIMARY KEY ("id") ); -- CreateTable CREATE TABLE "Skill" ( "id" SERIA...
#Номенклатурни данни за липсващи имунизации - да/не INSERT INTO school_health.confirmation_flag (confirmation_flag_code, confirmation_flag_value) VALUES ('Y','ДА'); INSERT INTO school_health.confirmation_flag (confirmation_flag_code, confirmation_flag_value) VALUES ('N','НЕ');
.headers on .nullvalue '-null-' .mode csv -- -- 01 SELECT DISTINCT taken, quant FROM Survey;
-- phpMyAdmin SQL Dump -- version phpStudy 2014 -- http://www.phpmyadmin.net -- -- 主机: localhost -- 生成日期: 2015 年 09 月 18 日 17:44 -- 服务器版本: 5.5.40 -- PHP 版本: 5.3.29 SET SQL_MODE="NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; /*!40101 SET @OLD_CHARA...
DROP ROLE IF EXISTS demo; create user demo with password 'demo'; drop database if exists amazingdemo; create database amazingdemo with owner demo;
select city, count(city) from venues group by (city) order by 2 DESC LIMIT 5;
/* Formatted on 17/06/2014 18:03:06 (QP5 v5.227.12220.39754) */ CREATE OR REPLACE FORCE VIEW MCRE_OWN.V_MCRE0_APP_RICERCA_ABI_NOME ( COD_COMPARTO, COD_RAMO_CALCOLATO, COD_ABI_ISTITUTO, DESC_ISTITUTO, COD_ABI_CARTOLARIZZATO, COD_NDG, COD_SNDG, DESC_NOME_CONTROPARTE, COD_GRUPPO_ECONOMICO, VA...
.headers on .nullvalue '-null-' .mode csv -- -- 01 SELECT min(dated) FROM Visited WHERE dated IS NOT NULL;
DROP EXTENSION IF EXISTS cstore_fdw; CREATE EXTENSION cstore_fdw; DROP SERVER IF EXISTS cstore_server; CREATE SERVER cstore_server FOREIGN DATA WRAPPER cstore_fdw; DROP FOREIGN TABLE IF EXISTS cstore_data; CREATE FOREIGN TABLE cstore_data ( date date NOT NULL, category text NOT NULL, value_1 int NOT NULL...
CALL add_entry('01',2019,0,200,0.5,0);
-- phpMyAdmin SQL Dump -- version 5.0.1 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Generation Time: May 15, 2020 at 05:33 PM -- Server version: 10.4.11-MariaDB -- PHP Version: 7.4.2 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OLD...