text
stringlengths
6
9.38M
-- phpMyAdmin SQL Dump -- version 4.7.0 -- https://www.phpmyadmin.net/ -- -- Host: localhost -- Generation Time: Sep 01, 2017 at 04:29 PM -- Server version: 10.1.25-MariaDB -- PHP Version: 5.6.31 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OL...
-- This file should undo anything in `up.sql` DROP TABLE tracks; DROP TABLE albums; DROP TABLE artists;
USE burgers_db INSERT INTO burgers (burger_name) values ('Monster Burger'); INSERT INTO burgers (burger_name) values ('Clam Burger'); INSERT INTO burgers (burger_name) values ('Meister Burger');
DROP TABLE IF EXISTS TBL_EMPLOYEES; CREATE TABLE TBL_EMPLOYEES ( id INT AUTO_INCREMENT PRIMARY KEY, first_name VARCHAR(250) NOT NULL, last_name VARCHAR(250) NOT NULL, email VARCHAR(250) DEFAULT NULL ); DROP TABLE IF EXISTS EMPLOYEE; CREATE TABLE EMPLOYEE ( emp_id INT AUTO_INCREMENT PRIMARY ...
SELECT PeakName,RiverName, LOWER(SUBSTRING(PeakName, 1, LEN(PeakName) - 1) + RiverName) AS Mix FROM Peaks JOIN Rivers ON RIGHT(Peaks.PeakName, 1) = LEFT(Rivers.RiverName, 1) ORDER BY Mix ASC
-- ----------------------------------------------------- -- Table `#__joomleague_prediction_admin` -- ----------------------------------------------------- CREATE TABLE IF NOT EXISTS `#__joomleague_prediction_admin` ( `id` INT(11) NOT NULL AUTO_INCREMENT , `prediction_id` INT(11) NOT NULL DEFAULT '0' , `user_id`...
--中心利润导入功能 /*==============================================================*/ /* Table: ERP_PROFIT_CENTER(利润中心维护表) */ /*==============================================================*/ DECLARE tb_exists NUMBER; BEGIN SELECT COUNT(*) INTO tb_exists FROM tabs WHERE table_name='ERP_PROFIT_CENTER'; ...
SELECT timeslots.id AS [timeslot_id], weekdays.id as [weekday_id], weekdays.name as [day], reservations.reason_short, group_concat(users.sigle, ' - ') AS [users] FROM timeslots LEFT OUTER JOIN reservations_timeslots ON reservations_timeslots.timeslot_id = timeslots.id LEFT OUTER JOIN reserva...
INSERT INTO dbo.organizations([id], [name], [country]) VALUES (1, 'National Association of the Municipalities in Republic of Bulgaria','BG'); INSERT INTO dbo.organizations([id], [name], [country]) VALUES (2, 'The regional association of municipalities "Trakia"','BG'); INSERT INTO dbo.organizations([id], [name], [countr...
 Create table Solicitud( SolicitudId int identity(1,1) Primary key, Razon varchar(100), Fecha varchar(20), Total float )go create table SolicitudDetalle( Id int identity(1,1) Primary key, SolicitudId int foreign key references Solicitud(SolicitudId), Material varchar(100), Cantidad int, Precio flo...
drop table if exists Plans; drop table if exists Tasks; drop table if exists TaskTimes; /*==============================================================*/ /* Table: Plans */ /*==============================================================*/ create table Plan...
CREATE TABLE IF NOT EXISTS study_analysis ( id SERIAL, study_id INTEGER REFERENCES studies (id) ON DELETE SET NULL ON UPDATE CASCADE, title VARCHAR(255), slug VARCHAR(255), body TEXT, PRIMARY KEY (id) );
-- MySQL dump 10.13 Distrib 8.0.17, for Win64 (x86_64) -- -- Host: localhost Database: user_db -- ------------------------------------------------------ -- Server version 8.0.17 /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; /*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */; /*!...
-- // address -- Migration SQL that makes the change goes here. CREATE TABLE address ( address_id SERIAL PRIMARY KEY, event_url CHARACTER VARYING(255) NOT NULL, note CHARACTER VARYING(255) NOT NULL, count_number INT DEFAULT 0 ); -- //@UNDO -- SQL to undo the change goes here. DROP TABLE address;
-- MySQL dump 10.13 Distrib 8.0.11, for Win64 (x86_64) -- -- Host: 127.0.0.1 Database: proface -- ------------------------------------------------------ -- Server version 8.0.11 /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; /*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */; /*!...
--- Get topology faces from edges and register to new layer
DELETE FROM TASK; DELETE FROM TASK_USER WHERE status <> 'admin'; INSERT INTO TASK_USER (id, name, email,status) values ('00000000-0000-0000-0000-000000000000', 'Pat Smith', 'somethingelse@something.com','status');
-- Start of generated script for 10.108.0.222-DB2-YKT (db2inst4) -- May-16-2007 at 09:19:53 create user YKT_CONF identified by "kingstar" default tablespace TS_YKT_WEB temporary tablespace TEMP profile DEFAULT quota unlimited on TS_YKT_WEB; grant create any index to YKT_CONF; grant create any ta...
''' 执行用时:364 ms, 在所有 MySQL 提交中击败了75.28% 的用户 内存消耗:0 B, 在所有 MySQL 提交中击败了100.00% 的用户 通过测试用例:12 / 12 ''' # Write your MySQL query statement below select actor_id, director_id from actordirector group by actor_id, director_id having count(1) >= 3 ''' 执行用时:1079 ms, 在所有 MySQL 提交中击败了5.09% 的用户 内存消耗:0 B, 在所有 MySQL 提交中击败了1...
DROP TABLE IF EXISTS Departement ; CREATE TABLE Departement ( id_dept int AUTO_INCREMENT NOT NULL, nom_dept VARCHAR(20), description_dept VARCHAR(20), type_dept ENUM('secondaire','tertaire') NOT NULL, nbre_etu_1A_dept INT(5), nbre_etu_2A_dept INT(5), long_dept FLOAT(8,6), lat_dept FLOAT(8,6), annee_universita...
/* UNION ----- !! since UNION does not include duplicates, the sort is implicit in order to remove them !! */ /* ABOUT SET OPERATORS ----------------------- When a set operator pairs two SELECT statements, the datatypes of the columns in the column list in the first SELECT must be similar – but not identical – to t...
SET SQLBLANKLINES ON CREATE OR REPLACE VIEW rv_pp_mrp AS SELECT mrp.pp_mrp_id, mrp.ad_client_id, mrp.ad_org_id, mrp.created, mrp.createdby, mrp.isactive, mrp.isavailable, mrp.updated, mrp.updatedby, pp.ismps, mrp.name, mrp.description, mrp.c_order_id, mrp.c_orderline_id, mrp.dateordered, mrp.datec...
-- alter table houses add column image text; -- alter table houses add column monthly_mortgage decimal; -- alter table houses add column rent decimal;
-- upgrade-4.0.3.0.2-4.0.3.0.3.sql SELECT acs_log__debug('/packages/intranet-rest/sql/postgresql/upgrade/upgrade-4.0.3.0.2-4.0.3.0.3.sql',''); SELECT im_report_new ( 'REST My Timesheet Projects and Hours', -- report_name 'rest_my_timesheet_projects_hours', -- report_code 'intranet-rest', -- package_key...
SELECT $table_fields FROM dc_ui.correspondence ORDER BY correspondence_name ASC;
insert into Administrators (idAdministrator, Name, LastName) values (1, 'Semyon', 'Petrov'); insert into Administrators (idAdministrator, Name, LastName) values (2, 'Evgeniy', 'Petrosyan'); insert into Faculty (idFaculty, Name, EnrolleesLimit, Administrator_id) values (1, 'Faculty of Biotechnology', 10, 2); insert int...
set search_path to musicbrainz; copy area_type from 's3://cs327e-final-project-datasets/music-brainz-csv/area_type.csv' iam_role 'arn:aws:iam::609062125426:role/redshifts3role' region 'us-east-1' csv quote '"' ignoreheader 1 trimblanks compupdate ON maxerror 50; copy area from 's3://cs327e-final-project-datasets/musi...
with users as ( select * from {{ref('users')}} ) select location, count(*) as total_users from users where date(last_access_date) > date('2021-01-01') group by 1
-- DBMS_SQL ref, including the record types -- https://docs.oracle.com/en/database/oracle/oracle-database/18/arpls/DBMS_SQL.html -- Data Types -- https://docs.oracle.com/en/database/oracle/oracle-database/19/sqlrf/Data-Types.html#GUID-A3C0D836-BADB-44E5-A5D4-265BA5968483 -- data types reference -- 'Oracle Built-in ...
-- phpMyAdmin SQL Dump -- version 4.1.14 -- http://www.phpmyadmin.net -- -- Client : 127.0.0.1 -- Généré le : Dim 13 Décembre 2015 à 23:27 -- Version du serveur : 5.6.17 -- Version de PHP : 5.5.12 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER...
INSERT INTO PUBLIC."user" ("email", "password", "avatar", "name", "role", "status") VALUES ('diemtrang596@gmail.com', '123456789', NULL, 'Nguyen Thi Diem Trang', 'Admin', 'Active'), ('nguyenthidiemtrang1996@gmail.com', '123456789', NULL, 'Diem Trang', 'Manager', 'Active'), ('diemtrang.nguyen@tanvieta.co', '12345678...
DROP ALL objects; CREATE TABLE DAILY_TRIP ( ID INTEGER(32) not null, TRIP_DATE DATE, VEHICLE_ID INTEGER(32) not null, ROUTE_ID INTEGER(32) not null, TRIP_TIME TIMESTAMP, SUPERVISOR_ID INTEGER(32)); CREATE UNIQUE INDEX IF NOT EXISTS SYS_IDX_SYS_PK_10171_10174 ON DAILY_TRIP (ID); ALTER TABLE DAILY_TRIP ALTER COL...
-- Use the `ref` function to select from other models select * from test_dbt.public.my_first_dbt_model where id = 1
create table customer ( id bigserial not null constraint customer_pkey primary key, email varchar(255), first_name varchar(255), last_name varchar(255) ); alter table customer owner to postgres; create table product ( id bigserial not null constraint product_pkey primary key, code varchar(10) not null...
select getdate() select year('12.2.2000') select month('12.2.2000') select day('12.2.2000') select datepart(yy,getdate()) select datepart(mm,getdate()) select datepart(dd,getdate()) select datepart(dw,getdate()) select datepart(hh,getdate()) select datepart(MI,getdate()) select datepart(ss,getdate()) select DATENAME(dw...
-- phpMyAdmin SQL Dump -- version 4.6.5.2 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Generation Time: 17 Feb 2021 pada 08.11 -- Versi Server: 10.1.21-MariaDB -- PHP Version: 5.6.30 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CL...
CREATE DEFINER=`administrator`@`localhost` PROCEDURE `filterBusiness`(radius FLOAT, uLat FLOAT, uLong FLOAT, filter1 VARCHAR(45), filter2 VARCHAR(45)) BEGIN #Searches database for businesses which meet the radius and cuisine filter criteria specified by the user. #Both Filters active IF(filter1 IS NOT NULL A...
SELECT emp_no, award_date, award_amount FROM employee_awards WHERE emp_no = 253406 AND award_date = str_to_date('2018-07-20','%Y-%m-%d'); DELETE FROM employee_awards WHERE emp_no = 253406 AND award_date = str_to_date('2018-07-20','%Y-%m-%d'); # video 2.02 # ----------- SELECT first_name, last_name, hire_date FR...
IF OBJECT_ID('@gis_schema.location_attribute', 'U') IS NULL CREATE TABLE @gis_schema.[location_attribute]( [location_attribute_id] [int] IDENTITY(1,1) NOT NULL, [location_id] [int] NOT NULL, [attribute_concept_id] [int] NULL, [attribute_start_date] [date] NULL, [attribute_end_date] [date] NULL, [value_as_number]...
CREATE Procedure spr_list_BeatwiseTotalOutstanding (@Date DateTime) As Create Table #temp(BeatID Int, Value Decimal(18,6)) -- Invoice Insert #temp(BeatID, Value) Select BeatID, IsNull(Sum(Balance),0) From InvoiceAbstract Where (IsNull(Status,0) & 192) = 0 And InvoiceType In (1,3) And ...
Create Procedure mERP_sp_saveGTOverdueInvoice As Begin Select 0 /* Below lines are commented as ITC informed that it is not required to track the invoices which are overdue exceeded and shown in Forum login alert */ -- Insert into GT_Invoice(InvoiceID,Documentid,InvoiceType,Alerttype,GroupId,GroupName,DefinedLimi...
create Procedure mERP_SP_getTallyDetails AS BEGIN Create Table #Tax(Taxtype nvarchar(100) COLLATE SQL_Latin1_General_CP1_CI_AS, ForumDesc nvarchar(255) COLLATE SQL_Latin1_General_CP1_CI_AS, TallyDesc nvarchar(255) COLLATE SQL_Latin1_General_CP1_CI_AS) insert into #Tax(Taxtype,ForumDesc) Select 'Input' as [Type]...
CREATE TABLE contractors ( ID SERIAL NOT NULL, NAME TEXT NOT NULL, PRIMARY KEY (ID) ); CREATE TABLE clients ( username TEXT NOT NULL, PRIMARY KEY (username) ); CREATE TABLE accessControl ( username TEXT NOT NULL, timestamp TIMESTAMP NOT NULL, contractorID INT NOT NULL, FOREIGN KEY (contractorID) REF...
IF NOT EXISTS (SELECT 1 FROM Record.RecordInformation) BEGIN INSERT INTO Record.RecordInformation VALUES('681DC25D-3101-41C4-AB0C-1EF8F0775B6A', '583DC25D-3101-41C3-AB0C-1EF8F0775B5A', 'Treatment test', 200, GETUTCDATE()) END
CREATE TABLE konsument ( ID INT , Kürzel CHAR(3) , Passwort VARCHAR(45), EMail VARCHAR(45) , PRIMARY KEY (ID) ); CREATE TABLE buchungen( ID INT, Datum date, Betrag double, Konsument_fk int, art_fk int, primary key (ID), foreign key(konsument_fk) references konsument(ID), foreign key(art_fk) refer...
-- phpMyAdmin SQL Dump -- version 3.5.2.2 -- http://www.phpmyadmin.net -- -- Host: 127.0.0.1 -- Generation Time: Feb 22, 2018 at 11:51 AM -- Server version: 5.5.27 -- PHP Version: 5.4.7 SET SQL_MODE="NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; /...
CREATE TABLE IF NOT EXISTS `Tattler` ( `Created` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP, `Modified` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP, `UserToken` varchar(36) NOT NULL, `Channel` varchar(255) NOT NULL, `IsLocked` tinyint(1) NOT NULL DEFAULT '0', PRIMARY KEY (`User...
DROP TABLE IF EXISTS PaySlips CASCADE; CREATE TABLE PaySlips ( employee_id INTEGER, payslip_date DATE NOT NULL, payslip_amount DEC(64,2) NOT NULL, payslip_num_work_hours INTEGER DEFAULT NULL, payslip_num_work_days INTEGER DEFAULT NULL, /* either num_work_hours or num_work_days is null */ CH...
delete from Race; delete from Feature where Type = 'RacialTrait'; delete from RaceFeatureList; delete from RaceLanguageList; insert into Race ( Name, LowLightVisionDepth, DarkVisionDepth, Size, Speed, FavoredClass ) values ( 'Dwarf', 0, 60, 'Medium', 20, 'Fighter' ); insert into Feature ( Type, SubType, Name, Descr...
CREATE TABLE [Hefezopf].[Setting] ( [SettingName] VARCHAR (255) NOT NULL, [SettingValue] NVARCHAR (MAX) NOT NULL, [Setting_SerialVersion] ROWVERSION NOT NULL, CONSTRAINT [PK_Hefezopf_Setting] PRIMARY KEY CLUSTERED ([SettingName] ASC) );
-- Dec 8, 2008 9:45:04 PM COT -- [ adempiere-Feature Requests-2408411 ] Add AD_Workflow.IsBetaFunctionality INSERT INTO AD_Column (AD_Client_ID,AD_Column_ID,AD_Element_ID,AD_Org_ID,AD_Reference_ID,AD_Table_ID,ColumnName,Created,CreatedBy,DefaultValue,Description,EntityType,FieldLength,Help,IsActive,IsAllowLogging,IsA...
-- -- Admin User -- INSERT INTO `user` ( `name`, `email`, `password` ) VALUES ( "Admin", "", "" ); SET @ADMINUSERID = last_insert_id(); INSERT INTO `group` ( `name` ) VALUES ( "Administrators" ); SET @ADMINGROUPID = last_insert_id(); INSERT INTO `user_group` ( `user_id`, `group_id` ) VALU...
--修改时间:2012-12-03 --修改内容:数据补录定义表 --先删除“数据补录定义表" drop table ERP_ADDITIONAL_DEFINE cascade constraints; --重新创建表”数据补录定义表“ create table ERP_ADDITIONAL_DEFINE ( ID NUMBER not null, FIELD_CODE VARCHAR2(60), FIELD_NAME VARCHAR2(100), IS_ADDITIONAL ...
/* DROP TABLE project; DROP TABLE contact; DROP TABLE engineer; DROP TABLE active_project_state; */ CREATE DATABASE pwner; USE pwner; CREATE TABLE project ( project_id INT UNSIGNED NOT NULL AUTO_INCREMENT, contact_id INT UNSIGNED NOT NULL, date_created DATETIME NOT NULL, engineer_id INT UNSIGNED, name VARCHAR(2...
CREATE TABLE info (id INT PRIMARY KEY AUTO_INCREMENT, login VARCHAR(30) NOT NULL UNIQUE, senha VARCHAR(30) NOT NULL UNIQUE, nome VARCHAR(200) NOT NULL UNIQUE, email VARCHAR(100) UNIQUE NOT NULL, cpf CHAR(11) NOT NULL UNIQUE, rg CHAR(8) NOT NULL UNIQUE, idade INT(3), nomePai VARCHAR(200), nomeMao VARCHAR(200), aniver...
-- phpMyAdmin SQL Dump -- version 4.8.1 -- https://www.phpmyadmin.net/ -- -- Servidor: 127.0.0.1 -- Tiempo de generación: 29-05-2019 a las 02:59:47 -- Versión del servidor: 10.1.33-MariaDB -- Versión de PHP: 7.2.6 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_zone = "+00:00"; ...
-- phpMyAdmin SQL Dump -- version 4.8.4 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1:3306 -- Generation Time: Sep 15, 2020 at 02:21 PM -- Server version: 5.7.24 -- PHP Version: 7.2.14 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OLD_CH...
/* 客户报价 */ delimiter $ drop trigger if exists Tgr_Quotations_AftereUpdate $ create trigger Tgr_Quotations_AftereUpdate after update on Quotations for each row begin /*定义变量*/ declare srid varchar(255); declare sNewCustomerNo varchar(255); declare sOldCustomerNo varchar(255); declare dNewDate date...
-- MySQL dump 10.13 Distrib 5.5.44, for debian-linux-gnu (x86_64) -- -- Host: localhost Database: civicgraph -- ------------------------------------------------------ -- Server version 5.5.44-0ubuntu0.14.04.1 /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; /*!40101 SET @OLD_CHARACTER_SET_RESULTS=...
INSERT INTO customer (id, email) VALUES (100005, 'A@ya.ru'), (100006, 'B@ya.ru');
-- TABLE FOR TESTING CREATE TABLE `HD_AUDIT_DB`.`DEPARTMENT` ( `ID` INT NOT NULL AUTO_INCREMENT, `NAME` VARCHAR(30) NULL, `RESPONSIBILITY` VARCHAR(100) NULL, PRIMARY KEY (`ID`)); -- TABLE FOR TESTING CREATE TABLE `HD_AUDIT_DB`.`EMPLOYEE` ( `ID` INT NOT NULL AUTO_INCREMENT, `NAME` VARCHAR(30) NULL, ...
delete from gha_issues_labels where event_id > 281474976710656; delete from gha_issues_assignees where event_id > 281474976710656; delete from gha_issues where event_id > 281474976710656; delete from gha_milestones where event_id > 281474976710656; delete from gha_payloads where event_id > 281474976710656; delete from ...
UPDATE dc_ui.category SET category_name = $1 WHERE category_id = $2
DROP SEQUENCE IF EXISTS CORRELATION_ID_SEQ; DROP TABLE IF EXISTS TESTCASE_HISTORY; DROP TABLE IF EXISTS INVOKE_RECORD; CREATE SEQUENCE CORRELATION_ID_SEQ; DROP TABLE IF EXISTS TESTCASE_HISTORY; CREATE TABLE TESTCASE_HISTORY ( ID BIGINT AUTO_INCREMENT, CORRELATION_ID VARCHAR(20), CLIENTREFUNDID VARC...
--...........................................................Partie1 Exercice1 --Création d'une base de donnée languages CREATE DATABASE `languages`; --Création d'une base de donnée languages si elle n'existe pas (meilleure solution) CREATE DATABASE IF NOT EXISTS `languages`; --............................................
select FirstName, LastName, City, State /* Selected the columns */ from Person left outer join Address /* Left Outer join means all the matched entries + all entries from table Person*/ on Person.PersonId=Address.PersonId; /* Join condition */
/* Drop table Create tables Initial populate *Copy* open orders to separate version "baseline_open" *Move* orders booked before target period to a separate version "baseline_excluded" *Copy* orders to plug the remainder of the current year by adding one year to dates "baseline_plug" Update budget dates to be + 1 year -...
# add a table to hold structural variations CREATE TABLE structural_variation ( structural_variation_id int(10) unsigned NOT NULL AUTO_INCREMENT, seq_region_id int(10) unsigned NOT NULL, seq_region_start int(11) NOT NULL, seq_region_end int(11) NOT NULL, seq_region_strand tinyint(4) NOT NULL, variation_name...
select v.version, count(*) as count from "muPiece" as p join "muVersion" as v on p.version_id = v.id group by v.version limit 5 ;
SELECT TABLE_NAME FROM INFORMATION_SCHEMA.TABLES WHERE TABLE_TYPE = 'BASE TABLE' AND TABLE_CATALOG='dbName'
/* Navicat Premium Data Transfer Source Server : 本地数据库-mysql5.7 Source Server Type : MySQL Source Server Version : 50724 Source Host : localhost:3306 Source Schema : wxlogin Target Server Type : MySQL Target Server Version : 50724 File Encoding : 65001 Date: 02/05/20...
/** * * @author Alexey * @name flat_payments_in_period_agregare */ Select t1.flat_id, sum(t1.payment_sum) as paySum From opl_payments t1 Where :flatID = t1.flat_id and (:beg_date < t1.payment_date) and (:end_date >= t1.payment_date) and (t1.date_id = :dateid or :dateid is null) group by t1.flat_id
-- phpMyAdmin SQL Dump -- version 4.8.5 -- https://www.phpmyadmin.net/ -- -- Хост: 127.0.0.1:3306 -- Время создания: Дек 09 2019 г., 12:50 -- Версия сервера: 10.3.13-MariaDB -- Версия PHP: 7.1.22 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OL...
# STR_TO_DATE # 문자열을 DATETIME형 데이터로 변경 INSERT INTO Orders VALUES (1, 1, 1, 6000, STR_TO_DATE('2014-07-01','%Y-%m-%d')); INSERT INTO Orders VALUES (2, 1, 3, 21000, STR_TO_DATE('2014-07-03','%Y-%m-%d')); INSERT INTO Orders VALUES (3, 2, 5, 8000, STR_TO_DATE('2014-07-03','%Y-%m-%d')); INSERT INTO Orders VALUES (4, 3, 6...
-- MySQL dump 10.16 Distrib 10.1.21-MariaDB, for osx10.6 (i386) -- -- Host: localhost Database: localhost -- ------------------------------------------------------ -- Server version 10.1.21-MariaDB /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; /*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER...
CREATE PROCEDURE sp_create_purchaseorderdetail(@PONumber INT, @ProductCode NVARCHAR(15), @Quantity Decimal(18,6), @PurchasePrice Decimal(18,6), @Serial int =0) AS INSERT INTO PODetail (PONumber, Product_Code, Quantity, Pending, PurchasePrice, Serial) VALUES (@PONumber, @ProductCode, ...
--******************************************************************** -- HP Vertica Analytics Platform -- Copyright (c) 2005 - 2017 Vertica, an HPE company -- -- DESCRIPTION -- -- This file contains a series of SQL commands that demonstrate -- the use of HPE Vertica Geospatial Package. -- -- This example is an analysi...
SET SQL_MODE="NO_AUTO_VALUE_ON_ZERO"; -- -- Base de datos: `consumoelectrico` -- CREATE DATABASE `consumoelectrico` DEFAULT CHARACTER SET utf8 COLLATE utf8_general_ci; USE `consumoelectrico`; -- -------------------------------------------------------- -- -- Estructura de tabla para la tabla `callespoblaciones` --...
drop table ACT_GE_PROPERTY; drop table ACT_GE_BYTEARRAY; drop table ACT_RE_DEPLOYMENT; drop table ACT_RE_MODEL; drop table ACT_RE_PROCDEF; drop table ACT_RU_IDENTITYLINK; drop table ACT_RU_VARIABLE; drop table ACT_RU_TASK; drop table ACT_RU_EXECUTION; drop table ACT_RU_JOB; drop table ACT_RU_EVENT_...
CREATE TABLE EMPLOYEE( EMP_ID INT NOT NULL, NAME VARCHAR (20) NOT NULL, PRIMARY KEY (EMP_ID) ); CREATE TABLE TEAMDETAILS( TEAM_ID INT NOT NULL, EMP_ID INT NOT NULL REFERENCES EMPLOYEE(EMP_ID), SUB_ID INT , SUP_ID INT NOT NULL ); CREATE TABLE REIMBURSEMENT_...
SELECT messages.stream_id, messages.version, messages.position, messages.id AS message_id, messages.created, messages.type, messages.metadata FROM messages INNER JOIN streams ON messages.stream_id = streams.id WHERE messages.stream_id = ? AND messages.version >= ? ORDER BY messages.p...
/* Расширение колонки комментарий в заданиях */ ALTER TABLE TASKS ALTER COLUMN DESCRIPTION VARCHAR(4000) -- /* Изменение таблицы просмотра заданий */ ALTER VIEW /*PREFIX*/S_TASKS AS SELECT T.*, D.DEAL_NUM, A.NAME AS ACTION_NAME, AC1.USER_NAME, AC2.USER_NAME AS PERFORMER_U...
update participant_congress set reported = false; update seminar_participant set reported = false; update seminar_participant set participated = true where active = true; update seminar_participant set participated = false where active = false; update participant set reportPoints = true; ALTER TABLE evaluation...
CREATE TABLE IF NOT EXISTS roles ( id int PRIMARY KEY AUTO_INCREMENT, name varchar(50) unique NOT NULL, createdAt TIMESTAMP not null default current_timestamp ); CREATE TABLE IF NOT EXISTS users ( id int PRIMARY KEY AUTO_INCREMENT, username varchar(45) NOT NULL, password varchar(255) NOT NULL, role_id int NOT NULL, cr...
UPDATE institutions SET rd_iksd_code='BJCAUSEKLIS' WHERE institution_id=1702; UPDATE institutions SET rd_iksd_code='MPS' WHERE institution_id=514; UPDATE institutions SET rd_iksd_code='R104PPII' WHERE institution_id=1482; UPDATE institutions SET rd_iksd_code='R106PPII' WHERE institution_id=878; UPDATE institutions SET ...
-- awr-trans-counts.sql -- see: 'How to Calculate the Number of Transactions in a Database (Doc ID 1292114.1)' -- Jared Still - jkstill@gmail.com -- -- 2016-05-18 initial script -- -- also included are redo log synch write waits, as that is the overhead wait caused by commit set linesize 200 trimspool on set page...
/* Navicat MySQL Data Transfer Source Server : localhost_3306 Source Server Version : 50726 Source Host : localhost:3306 Source Database : newti Target Server Type : MYSQL Target Server Version : 50726 File Encoding : 65001 Date: 2020-11-23 17:33:50 */ SET FOREIGN_KEY_CHECKS=0; -...
-------------------------------------------------------- -- Archivo creado - viernes-febrero-03-2017 -------------------------------------------------------- -------------------------------------------------------- -- DDL for View GPYV_010_FUENTESFINACPROYECTO ------------------------------------------------------...
CREATE TABLE EUsuario( id INT IDENTITY, usuario VARCHAR(20), nome VARCHAR(50) UNIQUE, senha VARCHAR(20), confirmado INT, CONSTRAINT PKUsuarios PRIMARY KEY(id) ) CREATE TABLE EEmail( email VARCHAR(100) UNIQUE, id INT, servidor int, porta INT, senha VARCHAR(40), CONSTRAINT FK_Emai...
CREATE TABLE dbo.ForecastingResults ( Id int NOT NULL IDENTITY (1, 1), StudentRef uniqueidentifier NOT NULL, TreeRef int NOT NULL, ForecastingPoint int NULL, ForecastingPercent float(53) NULL ) ON [PRIMARY]
SELECT cid, first_name, last_name, email, TRIM(SUBSTRING_INDEX(phone_complete, ' ',1)) as phone, IF( LOCATE('ext', phone_complete), # Grab everything after the first comma by counting the number of commas and subtracting 1 from it. TRIM(SUBSTRING_INDEX(phone_complete, ' ',-1)), '' ) as exten...
-- sesswaitu.sql -- show current waits for a username -- may call as '@sesswaitu USERNAME' -- eg. @sesswaitu '%' -- eg. @sesswaitu '%TMR%' -- eg. @sesswaitu 'USSP' -- if username not passed, it will ask for it set line 170 feed on pause off echo off set trimspool on clear col clear break col cusername new_value uu...
CREATE TABLE downloads ( id SERIAL PRIMARY KEY, version VARCHAR NOT NULL ); INSERT INTO downloads (id, version) VALUES (1, "0.1"); INSERT INTO downloads (id, version) VALUES (2, "0.2"); INSERT INTO downloads (id, version) VALUES (3, "0.3");
DROP DATABASE IF EXISTS building; CREATE database building; use building; CREATE TABLE users ( userID int not null auto_increment, username varchar(20), groupID int, primary key (userID) ); INSERT INTO users (username, groupID) VALUES ('Modesto',1), ('Ayine',1), ('Christopher',2), ('Cheng Woo',2), ('Heidy',NULL), ('S...
-- criando tabela PRODUTOS create table PRODUTOS3_AULA4 ( id_pro int not null, nome varchar(30) not null, preco decimal(6,2) not null, quantd int default 200, dtvalidade date not null primary key(nome) ); insert into PRODUTOS3_AULA4 values (1,'Zenfone S5',900.00,default,'04/05/2020'); insert into PRODUTOS...
-- Exercice 1 -- --Dans la table frameworks, afficher toutes les données de la table ayant une version 2.x (x étant un numéro quelconque). source /home/tarek/Exercices-SQL/part6/ajout.sql --on execute le fichier ajout.sql SELECT * -> FROM `frameworks` -> WHERE `version` LIKE 'version 2%'; -- Exercice 2 -- --Dans la ...
-- phpMyAdmin SQL Dump -- version 5.0.1 -- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 -- Waktu pembuatan: 27 Mar 2020 pada 15.52 -- Versi server: 10.4.11-MariaDB -- Versi PHP: 7.4.2 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET AUTOCOMMIT = 0; START TRANSACTION; SET time_zone = "+00:00"; /*!40101 SET @OLD_CHARA...
-- DROP DATABASE IF EXISTS join_us; -- CREATE DATABASE join_us; -- USE join_us; CREATE TABLE users ( email VARCHAR (255) PRIMARY KEY, created_at TIMESTAMP DEFAULT NOW() );
/* Navicat Premium Data Transfer Source Server : LocalHost Source Server Type : MySQL Source Server Version : 100138 Source Host : 127.0.0.1:3306 Source Schema : test_daniel_perez Target Server Type : MySQL Target Server Version : 100138 File Encoding : 65001 Date: 1...
CREATE TABLE user( uid TINYINT AUTO_INCREMENT PRIMARY KEY, username VARCHAR(16) UNIQUE , password VARCHAR(32) ); CREATE TABLE blog_category( id TINYINT AUTO_INCREMENT PRIMARY KEY, name VARCHAR (16...