sql stringlengths 6 1.05M |
|---|
-- @testpoint:opengauss关键字function(非保留),作为模式名
--关键字不带引号-成功
drop schema if exists function;
create schema function;
drop schema function;
--关键字带双引号-成功
drop schema if exists "function";
create schema "function";
drop schema "function";
--关键字带单引号-合理报错
drop schema if exists 'function';
create schema 'function';
--关键字... |
-- CreateTable
CREATE TABLE "User" (
"id" SERIAL NOT NULL,
"createdAt" TIMESTAMP(3) NOT NULL DEFAULT CURRENT_TIMESTAMP,
"updatedAt" TIMESTAMP(3),
"username" TEXT NOT NULL,
"email" TEXT NOT NULL,
"password" TEXT NOT NULL,
"dataId" INTEGER NOT NULL,
PRIMARY KEY ("id")
);
-- CreateTable
C... |
<filename>Modules/import/officine2/sql/clients.sql
select
p.inopat,
p.cmatricule,
p.lmatricule,
p.lcarteinvalide,
p.ltierspayant,
p.cnom,
p.cprenom,
p.cadresse,
p.ccodepost,
p.clocalite,
p.cpays,
p.ctelephone,
p.cgsm,
p.cfax,
p.cemail,
p.ise... |
-- phpMyAdmin SQL Dump
-- version 4.6.4
-- https://www.phpmyadmin.net/
--
-- Servidor: 127.0.0.1
-- Tiempo de generación: 11-01-2017 a las 16:47:52
-- Versión del servidor: 5.7.14
-- Versión de PHP: 5.6.25
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
SET time_zone = "+00:00";
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHAR... |
DROP DATABASE IF EXISTS loanmeahome;
CREATE DATABASE loanmeahome; |
<reponame>quocchienit/wambi-project
DELETE FROM `function_list` ;
-- ----------------------------
-- Records of function_list
-- ----------------------------
INSERT INTO `function_list` VALUES ('0', '1', 'funtion out-patient');
|
<filename>database-deploy-logging.sql
CREATE SCHEMA IF NOT EXISTS dbdeploy;
/* Simple lookup table */
CREATE TABLE IF NOT EXISTS dbdeploy.activitytype(
activitytypeid smallint primary key,
activitytype varchar(32)
);
WITH activity_types as (
select 1 as activitytypeid, 'START' as activitytype
union ... |
<reponame>JohnShandy/swganh
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET NAMES utf8 */;
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
CREATE TABLE IF NOT EXISTS `mood` (
... |
##################################################
# Create Database
##################################################
CREATE DATABASE if not exists miniblog;
GRANT all privileges on miniblog.*
to 'miniblog'@'localhost'
identified by 'secret';
##################################################
# Create Table... |
<gh_stars>1-10
ALTER TABLE `dlayer`.`user_site_page_content_item_html`
ADD CONSTRAINT `user_site_page_content_item_html_fk1` FOREIGN KEY (`site_id`) REFERENCES `user_site` (`id`),
ADD CONSTRAINT `user_site_page_content_item_html_fk2` FOREIGN KEY (`page_id`) REFERENCES `user_site_page` (`id`),
ADD CONSTRAIN... |
<reponame>Novitoll/devops-linux-mentoring-program<gh_stars>1-10
GRANT ALL PRIVILEGES ON *.* TO 'root'@'192.168.56.101' IDENTIFIED BY 's3cr3t' WITH GRANT OPTION;
FLUSH PRIVILEGES; |
<filename>src/test/resources/sql/alter_operator/fbc73c7f.sql
-- file:alter_operator.sql ln:52 expect:true
ALTER OPERATOR === (boolean, boolean) SET (RESTRICT = NONE, JOIN = NONE)
|
USE employees_db
INSERT INTO department (name)
VALUES ('Sales'),
('Engineering'),
('Finance');
USE employees_db;
INSERT INTO role (title, salary, department_id)
VALUES ('Sales Lead', 100000, 1),
('Salesperson', 80000, 1),
('Lead engineer', 150000, 2),
('Software Engineer', 120000, 2);
USE employees_db;
INSERT INTO e... |
<reponame>tewksbg/kvwmap-en<gh_stars>0
-- View zum Austausch der BRWs
BEGIN;
SET search_path = bodenrichtwerte, public;
SET default_with_oids = true;
CREATE OR REPLACE VIEW bw_boris_view AS
SELECT
bw.gutachterausschuss||'_'||LPAD(cast(bodenrichtwertnummer as char(13)), 7 , '0') as brwid,
k.kreisname as kreis... |
<filename>api/src/test/resources/dev/sql/user.sql<gh_stars>0
-- MySQL dump 10.16 Distrib 10.1.26-MariaDB, for debian-linux-gnu (x86_64)
--
-- Host: localhost Database: api_dev
-- ------------------------------------------------------
-- Server version 10.1.26-MariaDB-0+deb9u1
/*!40101 SET @OLD_CHARACTER_SET_CLIENT... |
USE bc_server_db;
CREATE TABLE system_signal_float_info
(
id INT UNSIGNED NOT NULL AUTO_INCREMENT PRIMARY KEY,
ctime TIMESTAMP DEFAULT CURRENT_TIMESTAMP,
mtime TIMESTAMP DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
/* The name can't be changed */
/* sys_sig_name_lang_id INT unsigned not null,... |
-- show policies on table
select *
from pg_policies
where tablename = 'projects';
-- show role names
SELECT rolname
FROM pg_roles;
-- drop a policy
-- drop policy "Allow individual insert access" on public.projects;
-- shows the names of all fk constraints
select *
from information_schema.key_column_usage
where positio... |
<reponame>S17cis526/scrumtastic-shawnco<filename>migrations/1-create-projects.sql<gh_stars>0
CREATE TABLE projects(
id INTEGER PRIMARY KEY,
name TEXT NOT NULL,
description TEXT,
version TEXT,
repository TEXT,
license TEXT
);
|
ALTER TABLE "articles" ADD status varchar(10) NOT NULL DEFAULT 'DRAFT';
|
-- phpMyAdmin SQL Dump
-- version 4.8.0
-- https://www.phpmyadmin.net/
--
-- Host: 127.0.0.1
-- Generation Time: 25-Maio-2018 às 04:56
-- Versão do servidor: 10.1.31-MariaDB
-- PHP Version: 7.2.4
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
SET AUTOCOMMIT = 0;
START TRANSACTION;
SET time_zone = "+00:00";
/*!40101 SET @OL... |
insert into hierarchy (id, name, type) values ('CL_0000694', 'Hours Statistics', 'classification');
insert into hierarchy_entry (id, hierarchy_id, code, parent, name, hierarchy_level_type_id, display_order) values ('367ca100-2026-4d8b-91a6-38a4782fd158', 'CL_0000694', 'CI_0006603', null, 'Mean', null, 1);
insert into... |
create table pm_projects (
id INT,
project_name VARCHAR(50),
project_details TEXT,
created_by VARCHAR(50),
created_time DATE,
active VARCHAR(50)
);
insert into pm_projects (id, project_name, project_details, created_by, created_time, active) values (1, 'Opela', 'Nam ultrices, libero non mattis pulvinar, nulla ped... |
<gh_stars>0
-- phpMyAdmin SQL Dump
-- version 4.6.6deb5
-- https://www.phpmyadmin.net/
--
-- Host: localhost:3306
-- Generation Time: Nov 03, 2020 at 07:54 PM
-- Server version: 10.1.44-MariaDB-0ubuntu0.18.04.1
-- PHP Version: 7.3.23-4+ubuntu18.04.1+deb.sury.org+1
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
SET time_zone ... |
<filename>src/o_canvas_inscricao.type.impl.sql
/*
Copyright (c) 2018 <NAME>
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the ri... |
<filename>mysql/laravel-crud(1).sql
-- phpMyAdmin SQL Dump
-- version 4.9.0.1
-- https://www.phpmyadmin.net/
--
-- Host: 127.0.0.1
-- Waktu pembuatan: 14 Sep 2019 pada 11.53
-- Versi server: 10.3.16-MariaDB
-- Versi PHP: 7.3.6
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
SET AUTOCOMMIT = 0;
START TRANSACTION;
SET time_zone... |
/*
Warnings:
- You are about to drop the `Item` table. If the table is not empty, all the data it contains will be lost.
- You are about to drop the `User` table. If the table is not empty, all the data it contains will be lost.
*/
-- DropForeignKey
ALTER TABLE "Item" DROP CONSTRAINT "Item_userId_fkey";
-- Dro... |
<filename>data_penduduk.sql<gh_stars>0
-- phpMyAdmin SQL Dump
-- version 4.8.5
-- https://www.phpmyadmin.net/
--
-- Host: 127.0.0.1
-- Generation Time: Nov 27, 2020 at 02:45 AM
-- Server version: 10.1.38-MariaDB
-- PHP Version: 7.3.3
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
SET AUTOCOMMIT = 0;
START TRANSACTION;
SET ti... |
--liquibase formatted sql
--changeset patcher-core:Page_F5CAF3CF206A4454A48FA1466932B969 dbms:postgresql runOnChange:true splitStatements:false stripComments:false
select pkg_patcher.p_remove_page('F5CAF3CF206A4454A48FA1466932B969');
INSERT INTO s_mt.t_page (ck_id, ck_parent, cr_type, cv_name, cn_order, cl_static, cv_... |
-- phpMyAdmin SQL Dump
-- version 4.9.1
-- https://www.phpmyadmin.net/
--
-- Host: db:3306
-- Generation Time: Dec 20, 2019 at 12:17 PM
-- Server version: 8.0.18
-- PHP Version: 7.2.23
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
SET AUTOCOMMIT = 0;
START TRANSACTION;
SET time_zone = "+00:00";
/*!40101 SET @OLD_CHARACTER... |
CREATE SCHEMA [DataLock]
|
<filename>src/test/resources/e_fkey.test_141.sql
-- e_fkey.test
--
-- execsql {
-- UPDATE zeus SET a = 'aBc';
-- SELECT * FROM apollo;
-- }
UPDATE zeus SET a = 'aBc';
SELECT * FROM apollo; |
<reponame>Shuttl-Tech/antlr_psql
-- file:identity.sql ln:157 expect:true
SELECT * FROM itest13
|
BEGIN;
-- insert seed data for basic user/platform/project/reward
\i /specs/sql-support/insert_platform_user_project.sql
\i /specs/sql-support/payment_json_build_helpers.sql
select plan(25);
SELECT function_returns(
'payment_service_api', 'pay', ARRAY['json'], 'json'
);
prepare p... |
<reponame>Salvatore-tech/MusicStore<filename>src/DML/STRUMENTO2_DML.sql
INSERT INTO STRUMENTO2 (nome, categoria) VALUES ('Basso', 'Cordofono');
INSERT INTO STRUMENTO2 (nome, categoria) VALUES ('Viola', 'Archi');
INSERT INTO STRUMENTO2 (nome, categoria) VALUES ('Violino', 'Archi');
INSERT INTO STRUMENTO2 (nome, categori... |
/*
Navicat MySQL Data Transfer
Source Server : localhost_3306
Source Server Version : 50505
Source Host : localhost:3306
Source Database : zjds
Target Server Type : MYSQL
Target Server Version : 50505
File Encoding : 65001
Date: 2018-11-29 18:03:45
*/
SET FOREIGN_KEY_CHECKS=0;
--... |
(select 'a' obj, 'b' link from dual) union all
(select 'a', 'c' from dual) union all
(select 'c', 'd' from dual) union all
(select 'd', 'c' from dual) union all
(select 'd', 'e' from dual) union all
(select 'e', 'e' from dual)
|
<filename>config/queries/db_server_init.sql<gh_stars>1-10
ALTER USER 'root'@'localhost' IDENTIFIED WITH mysql_native_password BY 'password';
FLUSH PRIVILEGES;
|
CREATE TABLE ARTIFACTDEPLOYMENT (
ARTFTYPE varchar(31) NOT NULL,
ARTIFACTPATH varchar(255) NOT NULL,
OBJECTNAME varchar(255) NOT NULL,
ACTIVE int NULL,
CHANGETYPE varchar(255) NULL,
CONTENTHASH varchar(255) NULL default "20140101",
DBSCHEMA varchar(255) NULL,
DEP... |
<reponame>ace-ecosystem/ACE
ALTER TABLE `events`
MODIFY COLUMN `status` ENUM('OPEN', 'CLOSED', 'IGNORE', 'INTERNAL COLLECTION') NOT NULL ;
|
<reponame>rmcelroyF8/amazon-redshift-utils
/**********************************************************************************************
Purpose: View to flatten stl_vacuum table and provide details like vacuum start and
end times, current status, changed rows and freed blocks all in one row
... |
-- ASSIGNMENT 2 --
-- ------------------------------------------------------------------
-- DATABASE SCHEMA :
-- ------------------------------------------------------------------
-- depts([deptcode], deptname)
-- students([rollno], name, bdate, {deptcode}, hostel, parent_inc)
-- faculty([fac_code], fac_name, {fac_de... |
-- phpMyAdmin SQL Dump
-- version 4.4.1.1
-- http://www.phpmyadmin.net
--
-- Host: localhost:8889
-- Generation Time: May 10, 2016 at 04:58 AM
-- Server version: 5.5.42
-- PHP Version: 5.6.7
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
SET time_zone = "+00:00";
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIEN... |
<reponame>OpenMPDK/SMDK
CREATE TABLE T1 (
ID INTEGER NOT NULL,
POINTS INTEGER NOT NULL,
AGE TINYINT,
PRIMARY KEY (ID)
);
create index idx_1_tree on T1 (POINTS);
create index idx_t1_id_age on T1 (ID, AGE);
create index idx_t1_id_pts on T1 (ID, POINTS);
create index idx1_t1_tree on T1 (AGE, (ID + POINTS));
create ind... |
-- phpMyAdmin SQL Dump
-- version 5.0.3
-- https://www.phpmyadmin.net/
--
-- Host: 127.0.0.1
-- Waktu pembuatan: 02 Bulan Mei 2021 pada 15.40
-- Versi server: 10.4.14-MariaDB
-- Versi PHP: 7.3.23
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
START TRANSACTION;
SET time_zone = "+00:00";
/*!40101 SET @OLD_CHARACTER_SET_CLIE... |
-- Teste Pickcells
-- SQL script select disciplinas com maior credito
-- Author : <NAME>
SELECT id_disciplina,
disciplina.disciplina,
creditos
FROM creditos
INNER JOIN tipo_curso ON id_tipo = tipo_curso.id
INNER JOIN curso ON id_curso = curso.id
INNER JOIN disciplina ON i... |
<gh_stars>0
-- CREATE DATABASE qanat;
-- use qanat;
-- Station(station_ID,num_plugs,location)
create table Station(
station_ID int not null AUTO_INCREMENT,
num_plugs int not null,
location varchar(50),
primary key (station_ID)
);
-- Plug_Model(model_no, charge_speed)
create table Plug_Model(
model_no varch... |
<reponame>lukasz50018/OracleDataBaseProject
--------------------------------------------------------------------------------
--------------------------------------------------------------------------------
CREATE TABLE OSOBA_LOG
(
ID_LOG INTEGER NOT NULL ,
DATA_ZMIANY DATE,
ID_OSOBY ... |
CREATE DEFINER=`root`@`localhost` PROCEDURE `prc_timedimbuild`()
BEGIN
DECLARE v_full_date DATETIME;
DELETE FROM tblDimTime;
SET v_full_date = '2009-03-01 00:00:00';
WHILE v_full_date < '2009-03-02 00:00:00' DO
INSERT INTO tblDimTime (
fulltime ,
hour ,
min... |
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE PROCEDURE [dbo].[SPTopicsGet]
@TopicId int=1
AS
SELECT
T.TopicId
,T.TopicTitle
,T.TopicShortName
,T.TopicDescription
,T.TopicCreationDate
,T.TopicViews
,T.TopicReplies
,T.UserId
,T.TopicTags
,T.TopicIsClose
,T.TopicOrder
,T.LastM... |
<reponame>saimmehmood/POI_Clustering<gh_stars>0
Steps:
-- Creating 1st Table (poi_latlong):
create Table poi_latlong(
latitude double precision,
longitude double precision,
)
-- Adding geom column:
Alter Table poi_latlong add column geom geometry(POINT,4326)
-- 4326 is SRID - {A spatial reference identifier (SRID... |
SELECT COUNT(*) AS Count FROM Employees
WHERE ManagerID IS NULL |
<reponame>mgjm-docker/mip-tv-server
SELECT COUNT(*)
FROM uniqueIps
WHERE userid = ?
AND day in ? // INPUT set/array
GROUP BY (userid, day, time);
|
SET DEFINE OFF;
CREATE UNIQUE INDEX AFW_01_CODE_ERR_ORCL_PK ON AFW_01_CODE_ERR_ORACL
(SEQNC)
LOGGING
/
|
---------START---------------
ALTER TABLE EGW_LINEESTIMATE ADD COLUMN councilresolutionnumber character varying(100) ;
ALTER TABLE EGW_LINEESTIMATE ADD COLUMN councilresolutiondate timestamp without time zone;
--rollback ALTER TABLE EGW_LINEESTIMATE DROP COLUMN councilresolutionnumber;
--rollback ALTER TABLE EGW_LINEE... |
DROP TABLE songs;
|
<filename>resources/db/patches/mysql/0450~settings.sql<gh_stars>100-1000
# Add missing setting for settings table.
REPLACE INTO settings (section, subsection, name, value, hint, setting) VALUES ('APIs', 'AniDB', 'banned', '0', "Timestamp of WHEN we were 'banned'.", 'AniDB_banned');
|
CREATE PROCEDURE `homes_add_uuid_proc` (IN uuid_in VARCHAR(36))
BEGIN
DECLARE uuid_exists INT;
SELECT EXISTS(SELECT 1 FROM `homes_uuids` WHERE `uuid`=uuid_in LIMIT 1) INTO uuid_exists;
IF uuid_exists = 0 THEN
INSERT INTO `homes_uuids` (`uuid`) VALUES (uuid_in);
END IF;
END; |
ALTER TABLE `prefix_users_entity` DROP KEY `last_action`;
ALTER TABLE `prefix_users_entity` ADD KEY `last_action` (`last_action`);
ALTER TABLE `prefix_users_entity` DROP KEY `last_login`;
ALTER TABLE `prefix_users_entity` ADD KEY `last_login` (`last_login`); |
<filename>src/main/resources/db/migration/V1_1_2__firm_fundamental_migration.sql
drop table IF EXISTS STOCK_FUNDAMENTAL_WEEKLY CASCADE;
CREATE TABLE STOCK_FUNDAMENTAL_WEEKLY
(
ID SERIAL PRIMARY KEY,
CODE varchar(50) NOT NULL,
EXCHANGE varchar(50) NOT NULL,
... |
<filename>Techtest.sql
-- phpMyAdmin SQL Dump
-- version 4.5.2
-- http://www.phpmyadmin.net
--
-- Host: localhost
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_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
/*... |
CREATE TABLE FUNDTRANSFER (
ID int NOT NULL,
bvn bigint,
accNo bigint,
accNoDestination bigint,
amount bigint,
DoC DATE,
Primary Key(ID)
);
INSERT INTO FUNDTRANSFER (ID) VALUES (1);
|
<filename>1.32.0/var/www/html/indicia/modules/indicia_setup/db/version_0_8_0/201202111710_person_attributes.sql
-- Table: person_attributes
-- DROP TABLE person_attributes;
CREATE TABLE person_attributes
(
id serial NOT NULL,
caption character varying(50), -- Display caption for the attribute.
data_type charac... |
<filename>ref/postgresql/f_schd_no.sql<gh_stars>0
CREATE OR REPLACE FUNCTION public.f_schd_no()
RETURNS character varying
LANGUAGE plpgsql
AS $function$
DECLARE
schd_no bigint;
next_val bigint;
BEGIN
SELECT
TO_CHAR(CURRENT_DATE, 'yyyymmdd')::bigint * '100000000'::bigint + 1
INTO
schd_no
;
... |
DROP TABLE urls;
DROP TABLE hits;
CREATE TABLE urls
(
id INT AUTO_INCREMENT PRIMARY KEY,
url VARCHAR(1500) NOT NULL,
created_at TIMESTAMP DEFAULT CURRENT_TIMESTAMP NOT NULL
);
CREATE TABLE hits
(
id INT AUTO_INCREMENT PRIMARY KEY,
url_id INT ... |
<reponame>jonathangreen/simplified-server-core
alter table externalintegrations add column name character varying;
create index "ix_externalintegrations_name" on externalintegrations (name);
alter table externalintegrations add column protocol varchar;
create index "ix_externalintegrations_protocol" on externalintegra... |
ALTER TABLE `{$NAMESPACE}_file`.`macro_transaction`
ADD metadata LONGTEXT NOT NULL COLLATE utf8_bin;
UPDATE `{$NAMESPACE}_file`.macro_transaction SET metadata = '{}'
WHERE metadata = '';
ALTER TABLE `{$NAMESPACE}_pholio`.`pholio_transaction`
ADD metadata LONGTEXT NOT NULL COLLATE utf8_bin;
UPDATE `{$NAMESPACE}_p... |
<reponame>vingkan/sql_tools
SELECT * FROM bonus WHERE NOT EXISTS
(
SELECT *
FROM emp
WHERE emp.emp_name = emp_name
AND bonus_amt > emp.salary)
AND
emp_name IN
(
SELECT emp_name
FROM emp
WHERE bonus_amt < emp.salary);
|
<reponame>rnd0101/urbanmediator<filename>urbanmediator/sql/013-patch.sql
ALTER TABLE locations ADD ranking INT DEFAULT 0;
ALTER TABLE notes ADD ranking INT DEFAULT 0;
|
--List the teachers who have NULL for their department.
SELECT name
FROM teacher
WHERE dept IS NULL
--Note the INNER JOIN misses the teachers with no department and the departments with no teacher.
SELECT teacher.name, dept.name
FROM teacher INNER JOIN dept
ON (teacher.dept=dept.id)
--Use a different ... |
------------------------------------------------------------------------------------------------------------------------
------------------------------------------------------------------------------------------------------------------------
----- vwBuild_CustModelLocation View Creation Script --------------------... |
<reponame>mil0sh/nextjs-hasura-boilerplate
CREATE FUNCTION public.set_current_timestamp_updated_at() RETURNS trigger
LANGUAGE plpgsql
AS $$
DECLARE
_new record;
BEGIN
_new := NEW;
_new."updated_at" = NOW();
RETURN _new;
END;
$$;
CREATE TABLE public.accounts (
id uuid DEFAULT public.gen_random_uuid()... |
# 197. Rising Temperature
# https://leetcode.com/problems/rising-temperature/
select a.Id
from Weather a join Weather b
where datediff(a.Date, b.Date) = 1 and a.Temperature > b.Temperature |
<gh_stars>1-10
CREATE TABLE `#__regoffices_countries` (
`id` INT(11) UNSIGNED NOT NULL AUTO_INCREMENT,
`iso` CHAR(2) NULL DEFAULT NULL,
`status` ENUM('P','N','D') NOT NULL DEFAULT 'P',
`regions` INT(11) NOT NULL DEFAULT '0',
`cities` INT(11) NOT NULL DEFAULT '0',
`offices` INT(11) NOT NULL DEFAULT '0',
PRIMARY K... |
CREATE TABLE IF NOT EXISTS historical_data_daily (
daily_id SERIAL,
ticker TEXT,
date TIMESTAMP,
open REAL,
close REAL,
high REAL,
low REAL,
adjusted_close REAL,
volume INTEGER,
dividend_amount REAL,
split_coefficient REAL
);
|
<reponame>takintsft/fusioninvoice
ALTER TABLE `fi_invoice_items` DROP `item_invoice_taxable`; |
/* alter table [File] add [Description] VARCHAR (MAX) NULL
update [file] set description = 'Lorem ipsum dolor sit amet, consectetur adipiscing elit. Donec turpis urna, posuere vel augue a, sollicitudin sagittis nulla. Curabitur tellus nulla, feugiat nec nisl sed, condimentum feugiat enim. Nullam iaculis'
select * fro... |
<reponame>xyla-io/almacen
--
-- view
--
create or replace view {SCHEMA}cube_tiktok_ad as
with date_range as (
select decode(start_date_fixed, null, decode(start_date_offset, null, null, dateadd(day, start_date_offset, current_date)), start_date_fixed) as start_date,
decode(end_date_fixed, null, decode(end_date_offs... |
<reponame>DaGreat1/platform-samples<gh_stars>1-10
/*
* This pulls a list of all email addresses and the user account it is tied to
* that don't match the list of domains in the WHERE clause. Add however many
* "%domain.com" needed to cover your company's approved domains.
*
* This query should be deprecated by t... |
INSERT INTO `opac_news` (`title`, `content`, `lang`, `timestamp`, `expirationdate`, `number`) VALUES ('Bienvenue dans Koha !','Bienvenue dans Koha 3, la toute nouvelle version du système intégré de gestion de bibliothèque (SIGB) open source de référence. Développé initialement en Nouvelle Zélande et déployé pour la pre... |
-- Revert lists
BEGIN;
DROP TABLE lists;
COMMIT;
|
CREATE TABLE author(
id BIGSERIAL PRIMARY KEY,
name TEXT UNIQUE NOT NULL,
note TEXT NOT NULL
);
CREATE TABLE quote(
id BIGSERIAL PRIMARY KEY,
author_id BIGINT REFERENCES author (id) NOT NULL,
text TEXT NOT NULL,
note TEXT NOT NULL,
retrieved BOOLEAN NOT NULL
);
|
\c deepface_v5;
update func_role set func_auth_flag = '{"home":"rw","monitor":"rw","search-image":"rw","search-cap":"rw","search-repo":"rw","search-illegalsearch":"rw","search-eventsearch":"rw","face-compare":"rw","face-repocollision":"rw","face-trajectory":"rw","dossier":"rw","stat":"rw","rule":"rw","repo":"rw","even... |
update clients set EnableLocalLogin = 1 where description = N'Mvc application'
GO
delete from ClientIdPRestrictions
GO
-- insert into ClientIdPRestrictions( ClientId, Provider)
-- select id, 'aad' from clients where Description = N'Mvc application'
-- GO
-- insert into ClientIdPRestrictions( ClientId, Provider)
-- sele... |
DROP TABLE IF EXISTS HELPDESK_LOCATIONS;
CREATE TABLE HELPDESK_LOCATIONS (LOCATION_ID INTEGER PRIMARY KEY AUTOINCREMENT,
LOCATION VARCHAR(75) NOT NULL);
INSERT INTO HELPDESK_LOCATIONS (LOCATION)
VALUES ('000 - Room 00');
INSERT INTO HELPDESK_LOCATIONS (LOCATION)
VALUES ('001 - Room 01')... |
--! Previous: sha1:1e03200a7cd1c8e5db9df39ffa074e95c18a189c
--! Hash: sha1:671fde8515abe65bb5c05302c3e71a6982bfef9d
-- Enter migration here
alter table if exists form_fields rename to form_elements;
DROP FUNCTION IF EXISTS set_form_field_order;
DROP FUNCTION IF EXISTS set_form_element_order;
CREATE FUNCTION public.se... |
--
-- PostgreSQL database dump
--
-- Dumped from database version 9.5.5
-- Dumped by pg_dump version 9.5.5
SET statement_timeout = 0;
SET lock_timeout = 0;
SET client_encoding = 'UTF8';
SET standard_conforming_strings = on;
SET check_function_bodies = false;
SET client_min_messages = warning;
SET row_security = off;
... |
DROP VIEW IF EXISTS `all_variants`;
CREATE
VIEW `all_variants` AS
SELECT
DISTINCT gnomadv2.Variant
FROM gnomadv2
UNION
SELECT
DISTINCT clinvarsumvar.Variant
FROM clinvarsumvar
UNION
SELECT
DISTINCT oosumvar.Variant
FROM oosumvar
GROUP BY
Variant
|
<filename>sql/yjbb/600469.sql<gh_stars>0
EXEC [EST].[Proc_yjbb_Ins] @Code = N'600469',@CutoffDate = N'2017-09-30',@EPS = N'-0.36',@EPSDeduct = N'0',@Revenue = N'56.84亿',@RevenueYoy = N'4.36',@RevenueQoq = N'6.72',@Profit = N'-2.01亿',@ProfitYoy = N'-431.15',@ProfiltQoq = N'-1461.46',@NAVPerUnit = N'3.9009',@ROE = N'-8.5... |
-- phpMyAdmin SQL Dump
-- version 4.7.4
-- https://www.phpmyadmin.net/
--
-- Host: 127.0.0.1
-- Generation Time: 11 Nov 2019 pada 09.15
-- Versi Server: 10.1.28-MariaDB
-- PHP Version: 5.6.32
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
SET AUTOCOMMIT = 0;
START TRANSACTION;
SET time_zone = "+00:00";
/*!40101 SET @OLD_CH... |
-- phpMyAdmin SQL Dump
-- version 4.8.2
-- https://www.phpmyadmin.net/
--
-- Host: 127.0.0.1
-- Generation Time: Feb 28, 2019 at 01:11 AM
-- Server version: 10.1.34-MariaDB
-- PHP Version: 7.2.7
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
SET AUTOCOMMIT = 0;
START TRANSACTION;
SET time_zone = "+00:00";
/*!40101 SET @OLD... |
-- 宣言部
DECLARE
depNo SCOTT.DEPT.DEPTNO%TYPE;
depName SCOTT.DEPT.DNAME%TYPE;
-- 処理部
BEGIN
SELECT
DEPTNO,
DNAME
INTO
depNo,
depName
FROM
SCOTT.DEPT
WHERE
DEPTNO = 10;
DBMS_OUTPUT.PUT_LINE('部署コード:' || depNo);
DBMS_OUTPUT.PUT_LINE('部署名:' || depName);
END; |
<gh_stars>0
-- phpMyAdmin SQL Dump
-- version 4.5.1
-- http://www.phpmyadmin.net
--
-- Servidor: 1192.168.3.11
-- Tiempo de generación: 07-01-2017 a las 18:47:24
-- Versión del servidor: 10.1.13-MariaDB
-- Versión de PHP: 7.0.5
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
SET time_zone = "+00:00";
/*!40101 SET @OLD_CHARA... |
<filename>database/bodycare.sql
-- phpMyAdmin SQL Dump
-- version 4.8.5
-- https://www.phpmyadmin.net/
--
-- Host: 127.0.0.1
-- Generation Time: Apr 03, 2020 at 10:16 AM
-- Server version: 10.1.38-MariaDB
-- PHP Version: 7.3.3
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
SET AUTOCOMMIT = 0;
START TRANSACTION;
SET time_zone... |
-- phpMyAdmin SQL Dump
-- version 5.0.4
-- https://www.phpmyadmin.net/
--
-- Host: 1172.16.31.10
-- Generation Time: Mar 20, 2021 at 11:53 PM
-- Server version: 10.4.17-MariaDB
-- PHP Version: 8.0.1
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
START TRANSACTION;
SET time_zone = "+00:00";
/*!40101 SET @OLD_CHARACTER_SET_C... |
<reponame>TinuMurani/FastTrackITFinalProject
CREATE PROCEDURE [dbo].[spPatients_DeleteById]
@Id INT
AS
BEGIN
DELETE FROM Patients WHERE Id = @Id;
END |
CREATE OR REPLACE FUNCTION invite_drain(user_id INTEGER, invite_id TEXT)
RETURNS INTEGER
LANGUAGE plpgsql
AS $$
DECLARE
inviter_id INTEGER;
inviter_sats INTEGER;
gift INTEGER;
BEGIN
PERFORM ASSERT_SERIALIZED();
-- check user was created in last hour
-- check user did not already redeem... |
<gh_stars>0
-- phpMyAdmin SQL Dump
-- version 4.8.3
-- https://www.phpmyadmin.net/
--
-- Servidor: 127.0.0.1
-- Tiempo de generación: 21-11-2018 a las 12:35:50
-- Versión del servidor: 10.1.36-MariaDB
-- Versión de PHP: 7.2.11
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
SET AUTOCOMMIT = 0;
START TRANSACTION;
S... |
<gh_stars>1-10
-- new function to return RoleID for Administrators of the Portal passed in as parameter
CREATE FUNCTION [dbo].[dnn_AdministratorRoleId](
@PortalId Int -- Needs to be >= 0, otherwise false is returned
)
RETURNS int
AS
BEGIN
DECLARE @adminRoleId int = 0
SELECT @adminRoleId = Administr... |
-- phpMyAdmin SQL Dump
-- version 4.8.3
-- https://www.phpmyadmin.net/
--
-- Host: 127.0.0.1
-- Generation Time: Mar 24, 2019 at 04:51 PM
-- Server version: 10.1.37-MariaDB
-- PHP Version: 7.2.12
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
SET AUTOCOMMIT = 0;
START TRANSACTION;
SET time_zone = "+00:00";
/*!40101 SET @OL... |
-- --------------------------------------------------------
-- Host: 127.0.0.1
-- Versión del servidor: 10.4.14-MariaDB - mariadb.org binary distribution
-- SO del servidor: Win64
-- HeidiSQL Versión: 11.0.0.5919
-- ------------------------------------------... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.