text stringlengths 6 9.38M |
|---|
-- phpMyAdmin SQL Dump
-- version 4.7.9
-- https://www.phpmyadmin.net/
--
-- Host: 127.0.0.1
-- Generation Time: 07-Abr-2018 às 01:33
-- Versão do servidor: 10.1.31-MariaDB
-- PHP Version: 7.2.3
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
SET AUTOCOMMIT = 0;
START TRANSACTION;
SET time_zone = "+00:00";
/*!40101 SET @OLD... |
CREATE TABLE [ASData_PL].[FAT_ROATPV2_ProviderAddress]
(
[Id] bigint NOT NULL,
[ProviderId] int NOT NULL,
[Postcode] varchar(25) NULL,
[Latitude] float NULL,
[Longitude] float NULL,
[AddressUpdateDate] [datetime2](7) NULL,
[Coordinates... |
/* Манго */
select
c.clientid
, c.LastName
, c.FirstName
, c.FatherName
, c.PhoneNumber
, iif(c.EmailConfirmed = 1, c.Email, null) as Email
, c.BirthDate
, concat(ar.AddressStr, N', кв. ' + nullif(ar.Apartment, '')) as RegAddress
, isnull(
nullif(concat(af.AddressStr, N', кв.... |
--실행하고 싶으면 파일명의 맨앞의 v를 대문자로 바꿔라
drop table if exists account cascade;
drop table if exists user_infodvo cascade;
drop sequence if exists hibernate_sequence;
create sequence hibernate_sequence start 1 increment 1;
create table account (id int4 not null, password varchar(255), role varchar(255), username varchar(255), p... |
-- -----------------------------------------------------
-- Table `drip`.`DRIP_PROPERTY_GROUP` 系统参数分类表
-- -----------------------------------------------------
DROP TABLE IF EXISTS `drip`.`DRIP_PROPERTY_GROUP`;
CREATE TABLE IF NOT EXISTS `drip`.`DRIP_PROPERTY_GROUP` (
`DBID` BIGINT NOT NULL AUTO_INCREMENT COMMENT '... |
-- Drop Forms
DROP TABLE dbo.Forms |
drop table if exists mUser cascade;
drop sequence if exists mUser_seq;
|
CREATE TABLE IF NOT EXISTS `comments`.`users` (
`id` INT NOT NULL AUTO_INCREMENT COMMENT '',
`username` VARCHAR(50) NOT NULL COMMENT '',
`password` VARCHAR(255) NOT NULL COMMENT '',
`create_date` TIMESTAMP NOT NULL DEFAULT NOW() COMMENT '',
`update_date` TIMESTAMP NOT NULL DEFAULT NOW() ON UPDATE NOW() C... |
# ************************************************************
# Sequel Pro SQL dump
# Version 4541
#
# http://www.sequelpro.com/
# https://github.com/sequelpro/sequelpro
#
# Host: 127.0.0.1 (MySQL 5.7.12-0ubuntu1.1)
# Database: asl_rera
# Generation Time: 2017-03-11 14:39:17 +0000
# ***********************************... |
INSERT INTO users
(user_name, user_pic, is_admin, auth_id)
VALUES
($1, $2, $3, $4)
RETURNING *;
|
/*Query 15*/
/*Using division getting all the reuiremnets of a position
divided by the skills a person have. If everything gets matched up,
Then that person is qualified*/
with qualified_per_id as(select per_id
from person T
where not exists ((select ks_code
from requirements
where pos_code='72... |
select email, salary from employees
where
salary<3000; |
delete from HtmlLabelIndex where id=26150
/
delete from HtmlLabelInfo where indexid=26150
/
INSERT INTO HtmlLabelIndex values(26150,'对不起,该省份不能封存!')
/
INSERT INTO HtmlLabelInfo VALUES(26150,'对不起,该省份不能封存!',7)
/
INSERT INTO HtmlLabelInfo VALUES(26150,'Sorry, the province can not be sealed!',8)
/
INSERT INTO HtmlLabel... |
/* 1) Duree totale reelle des appels effectués après le 15/02/2012 inclus */
SELECT SEC_TO_TIME(SUM(TIME_TO_SEC(appels_emis.duree_reel)))
FROM appels_emis
INNER JOIN tickets ON appels_emis.id_ticket = tickets.id
WHERE tickets.date_ticket >= '2012-02-15'
/* 2) TOP 10 des volumes data facturés par abonné en... |
-- -----------------------------------------------------
-- Table `olist`.`dim_location`
-- -----------------------------------------------------
DROP TABLE IF EXISTS `olist`.`dim_location` ;
CREATE TABLE IF NOT EXISTS `olist`.`dim_location` (
`geolocation_zip_code_prefix` INT(11) NOT NULL,
`geolocation_lat` VARC... |
select * from item order by 2 desc;
select * from category;
select * from item_category ic ;
where ic.categoryid = any ('851e69f9-b43c-4ebd-b96d-ed7e5d69b8bf', '61b646b8-8258-4e09-b9bc-14ab83c1a44b')
and ic.itemid = any ('8123fde8-4b42-43eb-a35d-0bbdb55ee655');
|
{% set raw_schema = generate_schema_name('raw_data') %}
-- test all args
{% set actual_source_yaml = codegen.generate_source(
schema_name=raw_schema,
table_pattern='%',
exclude='',
database_name=target.database,
generate_columns=True,
include_descriptions=True,
include_data_types=True,
... |
update SystemLoginTemplate set iscurrent=0 where iscurrent=1
/
update SystemLoginTemplate set iscurrent=1 where logintemplateid=3
/
UPDATE SystemTemplate SET extendtempletid=3
/ |
CREATE TABLE User (
id INTEGER NOT NULL,
name VARCHAR(250),
PRIMARY KEY (id)
);
create sequence USER_SEQUENCE;
CREATE TABLE Account (
id INTEGER NOT NULL,
user_id INTEGER,
number VARCHAR(20),
amount NUMERIC(15,2) DEFAULT 0,
version INTEGER DEFAULT 0,
PRIMARY KEY (id),
CONSTRAINT accont_fkey FOREIGN KEY (user_id) REFER... |
INSERT INTO POKEMON_SPECIES VALUES('Bulbasaur', 1, 128, 118, 111, 1115, 10, 14);
INSERT INTO POKEMON_SPECIES VALUES('Ivysaur', 2, 155, 151, 143, 1699, 10, 14);
INSERT INTO POKEMON_SPECIES VALUES('Venusaur', 3, 190, 198, 189, 2721, 10, 14);
INSERT INTO POKEMON_SPECIES VALUES('Charmander', 4, 118, 116, 93, 981, 7, null);... |
CREATE TABLE IF NOT EXISTS deed_20151030_clean_buyercount
SELECT
mail_address,
mail_city,
mail_state,
owner_1_label_name,
Count(*) N
FROM
deed_20151030_clean
GROUP BY
1, 2, 3;
|
select
a.TREE_NODE,
a.TREE_NODE_NUM,
a.TREE_NODE_NUM_END,
a.PARENT_NODE_NAME,
ifnull(b.TZ_MENU_MC,"") TZ_MENU_MC,
b.TZ_YXX,
ifnull(b.TZ_COM_ID,"") TZ_COM_ID,
ifnull(b.TZ_MENU_LIMG,"") TZ_MENU_LIMG,
ifnull(b.TZ_MENU_SIMG,"") TZ_MENU_SIMG,
ifnull(b.TZ_MENU_NRID,"") TZ_MENU_NRID
from
PSTREENODE a,
PS_TZ_AQ_... |
/*
Post-Deployment Script Template
--------------------------------------------------------------------------------------
This file contains SQL statements that will be appended to the build script.
Use SQLCMD syntax to include a file in the post-deployment script.
Example: :r .\myfile.sql ... |
-- =============================================
-- Author: Javier
-- Create date: June 2011
-- Description: <Description,,>
-- =============================================
CREATE FUNCTION fnCheckDuplicateDocuments
(
@companyId INT,
@vehicleId INT,
@documentTypeId INT,
@amount VARCHAR(50)
)
RETURNS @TABLE... |
-- * DDL HEADER: dev.asft_clc2_ckstatus_wrk ***
-- *************************** TABLE HEADER ******************************
-- *
-- * NAME : asft_clc2_ckstatus_wrk.sql
-- *
-- * PURPOSE: Creates dev.asft_clc2_ckstatus_wrk table
-- *
-- * HISTORY: AUTHOR DATE DESCRIPTION
-- * ... |
CREATE TABLE user_information (
user_id Serial NOT NULL PRIMARY key,
user_userid TEXT NOT null,
user_password TEXT NOT null,
user_name TEXT NOT NULL,
user_questionid int NOT NULL REFERENCES question_table(question_id),
user_answer TEXT NOT null
);
SELECT * FROM user_information ui;
CREATE TABLE account_number... |
DROP TABLE IF EXISTS `#__rpasoperador`;
CREATE TABLE `#__rpasoperador` (
`id` INT(11) NOT NULL AUTO_INCREMENT,
`dni` VARCHAR(10) NOT NULL,
`telefono` VARCHAR(9),
PRIMARY KEY (`id`)
)
ENGINE =MyISAM
AUTO_INCREMENT =0
DEFAULT CHARSET =utf8;
INSERT INTO `#__rpasoperador` (`dni`,`telefono`) VALUES
('3278... |
/* Formatted on 2015/06/08 13:55 (Formatter Plus v4.8.8) */
TRUNCATE TABLE CPI.giac_deferred_factors;
INSERT INTO cpi.giac_deferred_factors
(procedure_id, MONTH, numerator_factor, denominator_factor,
user_id, last_update, def_tag, line_cd
)
VALUES (1, 1, 1, 24,
... |
insert into jstlmember values('11','pw11','name11');
insert into jstlmember values('12','pw12','name12');
insert into jstlmember values('13','pw13','name13');
insert into jstlmember values('14','pw14','name14');
insert into jstlmember values('15','pw15','name15');
commit;
select * from jstlmember;
select * from addres... |
-- LABORATORY WORK 5
-- BY Drapak_Volodymyr
/* Написати функцію, що повертає кількість замовлень, що містять тільки один продукт у
будь-якій кількості, за ключем покупця, що є параметр функції */
CREATE OR REPLACE FUNCTION get_specific_orders_count(cid IN Customers.CUST_ID%TYPE)
RETURN NUMBER
IS
v_prod_cou... |
CREATE SEQUENCE users_id_seq;
CREATE TABLE users
(
id integer NOT NULL DEFAULT nextval('users_id_seq'::regclass),
first_name text NOT NULL,
last_name text NOT NULL,
email text NOT NULL,
password text NOT NULL,
role text,
CONSTRAINT users_pkey PRIMARY KEY (id),
CONSTRAINT users_email_uix... |
select count(*) as count
from user us left join user_photo up on us.photo=up.id
LEFT JOIN user_profile prof on us.id = prof.user_id
left join base_location loc on loc.id = prof.province
/*left join base_location loc2 on loc.id = loc2.parent_id*/
where us.id in
(
select user_favorite.favorite_id ui... |
CREATE DATABASE IF NOT EXISTS `components`;
DROP TABLE IF EXISTS `components`.`ambient`;
CREATE TABLE `components`.`ambient` (
`id` INT(10) AUTO_INCREMENT NOT NULL,
`temperature` FLOAT(4, 2) NOT NULL,
`humidity` FLOAT(4, 2) NOT NULL,
`createdAt` DATETIME NOT NULL,
PRIMARY KE... |
create table issues
(
issue_id int
auto_increment not null primary key,
title varchar
(255) constraint vtitle check
(length
(title) > 2),
status tinyint default 0 constraint vstatus check
(status >= 0 and status < 2),
created_at timestamp default current_timestamp,
modified_at ti... |
CREATE TABLE user_access(
index_number INT IDENTITY(1,1) NOT NULL
,username NTEXT(2147483646) NOT NULL
,lear_profile_index_number INT NOT NULL
,password NTEXT(2147483646) NOT NULL
,user_type NTEXT(2147483646) NOT NULL) |
-- Create a take_test.sql for each user that multi inserts their answers for.
-- Every user has taken both quizzes and answered all questions.
-- User 1 has gotten a perfect
-- User 2 has answer 3/5 correct.
-- User 3 has answered 1/5 correct.
INSERT INTO answers (user_id, question_id, choice_id)
VALUES (1,1,3), (1... |
select id, name from students
where department_id not in(select id from departments)
|
-- MySQL dump 10.13 Distrib 8.0.17, for Win64 (x86_64)
--
-- Host: localhost Database: gestin
-- ------------------------------------------------------
-- Server version 5.7.26
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
/*!4... |
CREATE TABLE IF NOT EXISTS "categories"(
"id" SERIAL PRIMARY KEY NOT NULL,
"name" VARCHAR(100) NOT NULL,
"description" VARCHAR(500) NOT NULL,
"active" BOOLEAN NOT NULL DEFAULT TRU... |
SELECT units.*
FROM (SELECT s.col_id AS id,
s.col_name AS name,
s.col_code AS code,
TO_CHAR(s.col_description) AS description,
'SKILL' AS objecttype,
s.col_skillaccesssubject AS accesssubjectid,
NULL AS groupid,
... |
-- This file contains the SQL experiments I did for my imaginary poem application
-- Notices how (almost) all of the words I wrote in capital are a differet color
-- That is because VSCode recognizes them as part of the standard SQL language :)
-- This one deletes a table
DROP TABLE poems;
-- This one creates a table... |
ALTER TABLE `user` DROP `profile_picture`, DROP `about`; |
DROP TABLE IF EXISTS products, product_categories, suppliers;
CREATE TABLE product_categories (
id SERIAL PRIMARY KEY,
name VARCHAR(40),
description TEXT,
department VARCHAR(40)
);
CREATE TABLE suppliers(
id SERIAL PRIMARY KEY,
name VARCHAR(40),
description TEXT
);
CREATE TABLE products(
id SERIAL PR... |
CREATE TABLE users
(
id serial not null unique,
name varchar(255) not null,
login varchar(255) not null unique,
password_hash varchar(255) not null
);
CREATE TABLE comics
(
id serial not null unique,
title varchar(255) not null,
user_id int references users (id) on delete cascade not null,
... |
-- phpMyAdmin SQL Dump
-- version 4.9.0.1
-- https://www.phpmyadmin.net/
--
-- Host: 127.0.0.1
-- Generation Time: Oct 18, 2019 at 10:39 PM
-- Server version: 10.4.6-MariaDB
-- PHP Version: 7.3.9
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
SET AUTOCOMMIT = 0;
START TRANSACTION;
SET time_zone = "+00:00";
/*!40101 SET @OL... |
DROP DATABASE IF EXISTS dad1;
CREATE DATABASE dad1;
USE dad1;
CREATE TABLE ItemType
(
ITID INT NOT NULL,
Attack INT,
Defense INT,
Money INT,
Name VARCHAR(50) NOT NULL,
Intellect INT,
HP INT,
Special INT,
PRIMARY KEY (ITID)
);
CREATE TABLE EnemyType
(
Name VARCHAR(50) NOT NULL,
... |
{{ config(
alias = 'bright_moments',
partition_by = ['project_id'],
materialized = 'view',
unique_key = ['project_id']
)
}}
select contract_address, project_id, project_id_base_value, collection_name, artist_name, bright_moments_city, art_collection_unique_id
from (VALUES
... |
CREATE TABLE upload (
id INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT,
user_id INTEGER NOT NULL,
artist INTEGER NOT NULL,
title TEXT NOT NULL,
size INTEGER NOT NULL,
hash TEXT UNIQUE,
info TEXT,
quality TEXT,
image_url TEXT,
server INTEGER NOT NULL,
filename TEXT NOT NULL,
streaming INTEGER NOT NU... |
INSERT INTO tb_category (name) VALUES ('Livros');
INSERT INTO tb_category (name) VALUES ('Eletrônicos');
INSERT INTO tb_category (name) VALUES ('Computadores');
INSERT INTO tb_product (name) VALUES ('The Lord of the Rings');
INSERT INTO tb_product (name) VALUES ('Smart TV');
INSERT INTO tb_product (name) VALUES ('Macb... |
CREATE TABLE [ADM].[C_NIVEL_ESCOLARIDAD] (
[ID_NIVEL_ESCOLARIDAD] INT IDENTITY (1, 1) NOT NULL,
[CL_NIVEL_ESCOLARIDAD] NVARCHAR (100) NOT NULL,
[DS_NIVEL_ESCOLARIDAD] NVARCHAR (200) NOT NULL,
[FG_ACTIVO] BIT CONSTRAINT [DF_C_NIVEL_ESCOLARIDAD_FG_ACTIVO] DEFA... |
-- phpMyAdmin SQL Dump
-- version 4.4.12
-- http://www.phpmyadmin.net
--
-- Host: 127.0.0.1
-- Generation Time: 31 Jul 2019 pada 10.08
-- Versi Server: 5.6.25
-- PHP Version: 5.6.11
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
SET time_zone = "+00:00";
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!... |
update DocUserDefault set hasoperate=1
/
|
--Checklist 79
CREATE OR REPLACE TRIGGER RemoveuFunc
AFTER DELETE ON funcionalidade
FOR EACH ROW
BEGIN
dbms_output.put_line('Funcionalidade removida, Número: '||:old.aplicacao);
END; |
--AUTHORS
--AMALA RICHU ALBERT AROCKIARAJ 29949270
--RACHANA RAMESH 29905257
--FIT5195 MAJOR ASSIGNMENT
--SQL STATEMENTS FOR VERSION 1 AND VERSION 2 SCHEMA
/*---------------------------------------------LEVEL 2 AGGREGATION VERSION 1------------------------------------------------*/
/*---------------------... |
-- CREATE DATABASE kappa
-- change database to kappa
CREATE SCHEMA crm;
CREATE TABLE crm.employee (
-- populated internally
id serial PRIMARY KEY,
first_name varchar(50) NOT NULL,
last_name varchar(50) NOT NULL,
birthdate date NOT NULL,
gender char(1) NOT NULL,
-- gender 'M = male, F = female, O = other'
emai... |
-- phpMyAdmin SQL Dump
-- version 5.0.2
-- https://www.phpmyadmin.net/
--
-- Хост: 127.0.0.1:3306
-- Время создания: Мар 21 2021 г., 20:24
-- Версия сервера: 5.7.29
-- Версия PHP: 7.1.33
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
START TRANSACTION;
SET time_zone = "+00:00";
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHAR... |
DROP DATABASE IF EXISTS bd;
CREATE DATABASE bd;
USE bd;
CREATE TABLE PARTIDA (
ID INT NOT NULL,
FECHA VARCHAR (60),
HORA VARCHAR (60),
ESTADO VARCHAR(60),
DURACION INT,
GANADOR VARCHAR (60),
PRIMARY KEY (ID)
)ENGINE=InnoDB;
CREATE TABLE JUGADOR (
ID INT NOT NULL,
USERNAME VARCHAR(6... |
-- CREATE TABLE SBDC (
-- id SERIAL PRIMARY KEY,
-- name VARCHAR(255) NOT NULL,
-- region VARCHAR(255) NOT NULL,
-- street_address VARCHAR(255) NOT NULL,
-- city VARCHAR(255) NOT NULL,
-- state VARCHAR(255) NOT NULL,
-- zipcode CHAR(5) NOT NULL,
-- );
-- CREATE TABLE users (
-- id SERIAL PRIMARY KEY,
... |
USE DATABASE "LENDING_CLUB";
USE SCHEMA "PUBLIC";
-- Fact Table
CREATE TABLE PUBLIC."ACCEPTED" (
"id" INTEGER NOT NULL PRIMARY KEY,
"member_id" nvarchar(31) NOT NULL,
"loan_amnt" FLOAT NOT NULL,
"funded_amnt" FLOAT NOT NULL,
"funded_amnt_inv" FLOAT NOT NULL,
"term" INTEGER NOT NULL,
"int_ra... |
delete HtmlLabelIndex where (id >=15091 and id <=17027 ) or (id >=822 and id <=7015)
/
delete HtmlLabelInfo where (indexid >=15091 and indexid <=17027) or (indexid >=822 and indexid <=7015)
/
INSERT INTO HtmlLabelIndex values(822,'熟练')
/
INSERT INTO HtmlLabelIndex values(823,'精通')
/
INSERT INTO HtmlLabelIndex values(... |
SELECT * FROM SYSTEMS
WHERE DELETE_FLAG = 0
ORDER BY INSERT_DATETIME %s;
|
-- phpMyAdmin SQL Dump
-- version 4.7.7
-- https://www.phpmyadmin.net/
--
-- Host: localhost:3306
-- Generation Time: Sep 19, 2021 at 09:24 AM
-- Server version: 5.6.41-84.1
-- PHP Version: 5.6.30
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
SET AUTOCOMMIT = 0;
START TRANSACTION;
SET time_zone = "+00:00";
/*!40101 SET @O... |
insert into super_heroes (id, name, created_at, updated_at) values (1, 'Acquaman',now(),now());
insert into super_heroes (id, name, created_at, updated_at) values (2, 'Superman',now(),now());
insert into super_heroes (id, name, created_at, updated_at) values (3, 'Birdman',now(),now());
insert into super_heroes (id, nam... |
INSERT INTO product(id, version, title, price, type)
VALUES (1, 0, 'Paranoid', 20.00, 'Lp');
INSERT INTO product(id, version, title, price, type)
VALUES (2, 0, 'The Richest Man In Babylon', 18.00, 'Lp');
INSERT INTO product(id, version, title, price, type)
VALUES (3, 0, 'Journey In Satchidananda', 25.00, 'Lp');
INSERT ... |
ALTER TABLE `job` ADD `reqiured_id` int(11) NULL DEFAULT NULL;
ALTER TABLE `job` ADD CONSTRAINT `job_required_id` FOREIGN KEY (`reqiured_id`) REFERENCES `requirement` (`id`);
|
# ************************************************************
# Sequel Pro SQL dump
# Vers„o 4541
#
# http://www.sequelpro.com/
# https://github.com/sequelpro/sequelpro
#
# Host: 127.0.0.1 (MySQL 5.7.31)
# Base de Dados: cbo
# Tempo de GeraÁ„o: 2020-08-19 23:52:16 +0000
# **********************************************... |
-- If we list all the natural numbers below 10 that are multiples of 3 or 5, we
-- get 3, 5, 6 and 9. The sum of these multiples is 23.
-- Find the sum of all the multiples of 3 or 5 below 1000.
-- Create the integers 1..100
WITH RECURSIVE cte(x) AS (
VALUES(1)
UNION ALL
SELECT x+1 FROM cte WHERE x+1<1000... |
delete from mainmenuinfo where id<0
/
delete from mainmenuconfig where infoid<0
/
delete from mainmenuinfo where id>=364
/
delete from mainmenuconfig where infoid>=364
/
create or replace PROCEDURE NewPageInfo_Insert_All
AS
id_1 integer;
frontpagename_1 varchar2(100);
defaultIndex_1 integer;... |
delete from SystemLogItem where itemid='143'
/
insert into SystemLogItem (itemid,lableid,itemdesc) values('143',16485,'称呼设置')
/
delete from SystemLogItem where itemid='144'
/
insert into SystemLogItem (itemid,lableid,itemdesc) values('144',16486,'地址类型')
/
delete from SystemLogItem where itemid='145'
/
insert in... |
DROP TABLE IF EXISTS `user`;
CREATE TABLE IF NOT EXISTS `user` (
uid VARCHAR(36) NOT NULL PRIMARY KEY,
username VARCHAR(12) NOT NULL,
password VARCHAR(14) NOT NULL
); |
-----------Base de datos => Sistema Academico-----------
create database efi;
create table persona(
per_id varchar(20) not null,
per_nombre varchar(50) not null,
per_apellido varchar(50) not null,
per_fecha_nacimiento date not null,
per_direccion varchar(100),
per_correo varchar (30) not null,... |
ALTER TABLE `stats` ADD `companyid` INT NOT NULL AFTER `agentid`;
update `stats`
set companyid = (select companyid from agents where agents.id = stats.agentid); |
alter table WorkPlan modify(requestid varchar2(500))
/
alter table WorkPlan modify(projectid varchar2(500))
/
alter table WorkPlan modify(crmid varchar2(500))
/
alter table WorkPlan modify(docid varchar2(500))
/
alter table WorkPlan add taskid_1 varchar2(500)
/
update WorkPlan set taskid_1 = taskid
/
alter table WorkP... |
DROP TABLE IF EXISTS model2;
CREATE TABLE IF NOT EXISTS model2 (
id INT AUTO_INCREMENT,
PRIMARY KEY (id)
);
|
---------------------------
-- Remplissage DIRECTEUR --
---------------------------
INSERT into DIRECTEUR (nom,prenom) values ('Jackson','Michael');
INSERT into DIRECTEUR (nom,prenom) values ('Joel','Billy');
INSERT into DIRECTEUR (nom,prenom) values ('Jhon','Elton');
INSERT into DIRECTEUR (nom,prenom) values ('Clapton... |
/*
Navicat MySQL Data Transfer
Source Server : localhost
Source Server Version : 50520
Source Host : localhost:3306
Source Database : device
Target Server Type : MYSQL
Target Server Version : 50520
File Encoding : 65001
Date: 2018-05-28 06:30:44
*/
SET FOREIGN_KEY_CHECKS=0;
-- --... |
DROP PROCEDURE CPI.DELETE_ALL_TABLES;
CREATE OR REPLACE PROCEDURE CPI.DELETE_ALL_TABLES (
p_par_id IN GIPI_WPOLBAS.par_id%TYPE,
p_line_cd IN GIPI_WPOLBAS.line_cd%TYPE,
p_subline_cd IN GIPI_WPOLBAS.subline_cd%TYPE,
p_iss_cd IN GIPI_WPOLBAS.iss_cd%TYPE,
p_issue_yy IN GIPI_WPOLBAS.issue_yy%TYPE,
p_pol_seq_no I... |
/* Create Foreign Key Constraints */
ALTER TABLE "ADM_TGRPR"
ADD CONSTRAINT "FK_ADM_TGRPR_ADM_TACCI"
FOREIGN KEY ("GRPR_ACCI") REFERENCES "ADM_TACCI" ("ACCI_ACCI")
;
ALTER TABLE "ADM_TGRPR"
ADD CONSTRAINT "FK_ADM_TGRPR_ADM_TGRUP"
FOREIGN KEY ("GRPR_GRUP") REFERENCES "ADM_TGRUP" ("GRUP_GRUP")
;
ALTER TABLE ... |
create table usersData
(
id serial not null primary key,
first_name varchar(50) not null,
last_name varchar(50) not null,
birth_date date not null,
phone_no char(9) unique
);
|
/* Create Table Comments, Sequences for Autonumber Columns */
COMMENT ON TABLE ADM_PAIS
IS 'TABLA DE LOS PAISES ELEGIBLES EN EL SISTEMA'
;
COMMENT ON COLUMN ADM_PAIS.PAIS_PAIS
IS 'ID DE LA TABLA DE PAISES'
;
COMMENT ON COLUMN ADM_PAIS.PAIS_CODI
IS 'CODIGO DEL PAIS'
;
COMMENT ON COLUMN ADM_PAIS.PAIS_NOMB
IS 'NO... |
-- point 5
-- create unique_id table
CREATE TABLE IF NOT EXISTS unique_id(id INTEGER UNIQUE DEFAULT 1, name VARCHAR(256));
|
alter table workflow_nodecustomrcmenu add usecustomsender char(1) null
/ |
-- phpMyAdmin SQL Dump
-- version 4.8.4
-- https://www.phpmyadmin.net/
--
-- Host: 127.0.0.1
-- Generation Time: Oct 15, 2020 at 07:44 AM
-- Server version: 10.1.37-MariaDB
-- PHP Version: 7.1.26
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
SET AUTOCOMMIT = 0;
START TRANSACTION;
SET time_zone = "+00:00";
/*!40101 SET @OL... |
select top 10 *
from CreditRobotRequests
where DateCreated >= '20190501'
and userid = 155924
select top 10 *
from CreditRobotVerdictRequests
where DateCreated >= '20190501'
and userid = 155924
select *
from CreditRobotReports
where DateCreated >= '20190501'
and ApplicationId = '96d62432e3d9456792e3... |
-- phpMyAdmin SQL Dump
-- version 3.4.5
-- http://www.phpmyadmin.net
--
-- Host: mdhblog.db
-- Generation Time: Nov 03, 2011 at 12:32 AM
-- Server version: 5.0.84
-- PHP Version: 5.3.8
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 bluetooth.observations (
id bigserial not null primary key,
user_id bigint,
analysis_id integer,
measured_time integer,
measured_time_no_filter integer,
startpoint_number smallint,
startpoint_name character varying(8),
endpoint_number smallint,
endpoint_name character v... |
-- SCRIPT INFORMATION --
-- Types: mysql mariadb
-- Version: 1
-- Upgrades: 0
-- SCRIPT INFORMATION --
START TRANSACTION;
SET foreign_key_checks = 0;
DROP TABLE IF EXISTS sanctuary_payed_items;
DROP TABLE IF EXISTS sanctuary_reinforced CASCADE;
DROP TABLE IF EXISTS sanctuary_anchors;
DROP TABLE IF EXISTS ... |
./build.sh
psql -f seed.sql journal
|
-- phpMyAdmin SQL Dump
-- version 4.1.14
-- http://www.phpmyadmin.net
--
-- Host: 127.0.0.1
-- Generation Time: May 24, 2015 at 07:53 AM
-- Server version: 5.6.24-log
-- PHP Version: 5.5.12
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
SET time_zone = "+00:00";
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT... |
ALTER TABLE carro
ADD COLUMN foto VARCHAR(255),
ADD COLUMN content_type VARCHAR(255);
ALTER TABLE motorista
ADD COLUMN email VARCHAR(255); |
SELECT tr.id,tr.bought_date,tr.sold_date,tr.code,fn.name,tr.bought_value,tr.sold_value,
tr.rate_of_return,SUMMARY.cumulative_net_worth
FROM tb_trade_records tr,tb_fund_name fn,
(WITH SUMMARY AS
(SELECT *,ROW_NUMBER()OVER(PARTITION BY CODE ORDER BY net_worth_date DESC) AS RK
FROM tb_fund_net_worth
WHERE Net_worth_dat... |
create view hoc.view_history as
select date, hoc.heroes.id as hero_id, name as hero_name, hoc.achievements.id as ach_id, title as ach_title from hoc.ach_history
left join hoc.heroes on hoc.ach_history.hero_id=hoc.heroes.id
left join hoc.achievements on hoc.ach_history.ach_id=hoc.achievements.id
|
CREATE TABLE `poll` (
`poll_id` int(5) NOT NULL,
`poll_name` varchar(30) NOT NULL,
`vote` int(5) NOT NULL,
PRIMARY KEY (`poll_id`)
) ENGINE=InnoDB DEFAULT CHARSET=latin1 AUTO_INCREMENT=5 ;
INSERT INTO `poll` (`poll_id`, `poll_name`, `vote`) VALUES
(1, 'batman', 1),
(2, 'kungfu', 1),
(3, 'deadpool', 0),
(4, ... |
# Creating tables
CREATE TABLE dialogs(
id INT NOT NULL PRIMARY KEY AUTO_INCREMENT,
userFirst INT NOT NULL,
userSecond INT NOT NULL,
FOREIGN KEY (userFirst) REFERENCES users(id),
FOREIGN KEY (userSecond) REFERENCES users(id)
);
CREATE TABLE messages(
id INT NOT NULL PRIMARY KEY AUTO_INCREMENT,
id_dialog... |
--создание таблицы
CREATE TABLE test_pay
(clnt_id NUMBER(10) NOT NULL,
subs_id NUMBER(10) NOT NULL,
pay_sum NUMBER(8, 2) NOT NULL,
pay_date DATE NOT NULL,
del_date DATE
);
/
COMMENT ON COLUMN test_pay.clnt_id
IS 'ID клиента';
COMMENT ON COLUMN test_pay.subs_id
IS 'ID а... |
update PAPERLESS_ASIGNACION
set TiempoEstimadoUsr1= ISNULL(PAPERLESS_PROCESOS_DURACION.duracion * PAPERLESS_ASIGNACION.NumHousesBL,0)
from PAPERLESS_PROCESOS_DURACION
where paperless_asignacion.IdTipoCarga = PAPERLESS_PROCESOS_DURACION.IdTipoCarga
|
/*
MySQL Data Transfer
Source Host: localhost
Source Database: flow
Target Host: localhost
Target Database: flow
Date: 2011/9/5 9:59:40
*/
SET FOREIGN_KEY_CHECKS=0;
-- ----------------------------
-- Table structure for app_config
-- ----------------------------
DROP TABLE IF EXISTS `app_config`;
CREATE ... |
CREATE OR REPLACE PROCEDURE test(v_s_id IN VARCHAR2, result OUT VARCHAR2)
IS
CURSOR cur (student_id VARCHAR2)
IS
SELECT *
FROM student
WHERE s_id = student_id;
BEGIN
FOR cur_rec IN cur(v_s_id)
LOOP
BEGIN
result := cur_rec.s_name;
EXCEPTION
WHEN OTHERS THEN... |
alter table ACT_RU_TASK
add OWNER_ varchar(64);
alter table ACT_RU_TASK
add DELEGATION_ varchar(64);
alter table ACT_RU_TASK
add DUE_DATE_ datetime; |
set search_path to encuestas;
-- View: v_resumen_encuestas
-- DROP VIEW v_resumen_encuestas;
CREATE OR REPLACE VIEW v_resumen_encuestas AS
SELECT a.id AS encuesta_id, b.completas, b.incompletas, b.usuarios, c.grupos, d.preguntas, b.completas::double precision / b.usuarios::double precision * 100::double precision A... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.