sql stringlengths 6 1.05M |
|---|
<reponame>rochaandre/scripts-oracle-named
select
'session_cached_cursors' parameter,
lpad(value, 5) value,
decode(value, 0, ' n/a', to_char(100 * used / value, '990') || '%') usage
from
( select
max(s.value) used
from
v$statname n,
v$sesstat s
where
n.name = 'se... |
/*
Navicat MySQL Data Transfer
Source Server : local
Source Server Version : 50624
Source Host : localhost:3306
Source Database : shopceo
Target Server Type : MYSQL
Target Server Version : 50624
File Encoding : 65001
Date: 2015-06-29 01:34:18
*/
SET FOREIGN_KEY_CHECKS=0;
-- -----... |
<filename>scripts/gaming/ironsource/useful_sql.sql
/*create or replace view `get-data-team.tenjin_dv_test.view_ironsource_revenue` as
SELECT *, _TABLE_SUFFIX as table_id,
cast(SPLIT(_TABLE_SUFFIX, '_')[OFFSET(0)] as date) as dataset_date,
SPLIT(_TABLE_SUFFIX, '_')[OFFSET(1)] as appkey
FROM `get-data-team.tenjin_dv_... |
/*
* To change this license header, choose License Headers in Project Properties.
* To change this template file, choose Tools | Templates
* and open the template in the editor.
*/
/**
* Author: danf
* Created: Mar 23, 2018
*/
CREATE TABLE `volunteer_application` (
`volunteer_application_id` int(11) NOT NUL... |
REM /**********************************************************/
REM SCRIPT
REM _DEFAULT.sql
REM TITLE
REM Restore default SQL*Plus settings
REM HINT
REM Restore default SQL*Plus settings
REM NOTES
REM No
REM /**********************************************************/
TTITLE OFF
BTITLE OFF... |
CREATE DATABASE IF NOT EXISTS notejam;
CREATE TABLE IF NOT EXISTS notejam.users (
id INT PRIMARY KEY AUTO_INCREMENT NOT NULL,
email VARCHAR(75) NOT NULL,
password VARCHAR(128) NOT NULL
);
CREATE TABLE IF NOT EXISTS notejam.pads (
id INT PRIMARY KEY AUTO_INCREMENT NOT NULL,
name VARCHAR(100) NOT NULL,
user... |
<gh_stars>10-100
-- file:strings.sql ln:225 expect:true
SELECT 'hawkeye' LIKE 'h%' AS "true"
|
-- file:insert.sql ln:4 expect:true
create table inserttest (col1 int4, col2 int4 NOT NULL, col3 text default 'testing')
|
/*
Run this script on:
(localdb)\v11.0.CSETWeb1000 - This database will be modified
to synchronize it with:
(localdb)\v11.0.CSETWeb1001
You are recommended to back up your database before running this script
Script created by SQL Compare version 14.1.7.14336 from Red Gate Software Ltd at 5/12/... |
-- 2019-12-03T06:49:39.145Z
-- I forgot to set the DICTIONARY_ID_COMMENTS System Configurator
INSERT INTO AD_SysConfig (AD_Client_ID,Created,CreatedBy,IsActive,ConfigurationLevel,AD_SysConfig_ID,Updated,UpdatedBy,Value,Name,AD_Org_ID,EntityType) VALUES (1000000,TO_TIMESTAMP('2019-12-03 08:49:38','YYYY-MM-DD HH24:MI:SS'... |
DELETE FROM Genre;
DELETE FROM BookType;
DELETE FROM DiscType;
DELETE FROM GameType;
DELETE FROM Retailer;
DELETE FROM Game;
DELETE FROM Disc;
DELETE FROM Book;
DELETE FROM Bookshelf; |
/*
** Oracle Sharding Tools Library
**
** Copyright © 2019 Oracle and/or its affiliates. All rights reserved.
** Licensed under the Universal Permissive License v 1.0 as shown at
** http://oss.oracle.com/licenses/upl
*/
/**
Create sharded tables for customer and their corresponding invoices belonging to
each of ... |
# --- Created by Ebean DDL
# To stop Ebean DDL generation, remove this comment and start using Evolutions
# --- !Ups
create table category (
id bigint auto_increment not null,
category_name varchar(255),
constraint pk_category primary key (id))
;
create table item (
id... |
<filename>java-example/flyway-example/src/main/resources/db/migration/V1__Initial_DB.sql<gh_stars>0
CREATE TABLE MESSAGE (
ID INT NOT NULL AUTO_INCREMENT,
MESSAGE VARCHAR(100) NOT NULL,
PRIMARY KEY (ID)
);
|
<reponame>RomanMozhaev/job4j_userlist
INSERT INTO users (user_name, user_email, create_time, user_photo, password, role)
VALUES ('admin', '<EMAIL>', 0, '', 'password', '<PASSWORD>');
|
<filename>spring-petclinic-supplements-service/src/main/resources/db/mysql/schema.sql<gh_stars>0
CREATE DATABASE IF NOT EXISTS petclinic;
GRANT ALL PRIVILEGES ON petclinic.* TO pc@localhost IDENTIFIED BY 'pc';
USE petclinic;
CREATE TABLE IF NOT EXISTS supplements (
id INT(4) UNSIGNED NOT NULL AUTO_INCREMENT PRIMARY... |
WITH vac_stat AS (SELECT EXTRACT(MONTH FROM create_date) as month
FROM resume
GROUP BY month
ORDER BY count(*) DESC
LIMIT 1)
SELECT EXTRACT(MONTH FROM create_date) as vacancy_top_month, (SELECT month FROM vac_stat) resume_top_month
FROM vacancy
GRO... |
<reponame>jankytara2/dbt
{% snapshot example_snapshot %}
{{
config(target_schema=schema, unique_key='a', strategy='check', check_cols='all')
}}
select * from {{ ref('example_seed') }}
{% endsnapshot %}
|
<filename>jeecg-p3-biz-alipay-single/src/main/java/com/jeecg/alipay/account/sql/AlipayMenuDao_getAllFirstMenu.sql
SELECT * FROM alipay_menu AS qm
WHERE (qm.father_id is null or qm.father_id ='')
ORDER BY qm.orders |
<filename>broker/src/main/resources/db/migration/V1_0_11__create_table_service_context.sql
DROP PROCEDURE IF EXISTS create_table_service_context;
DELIMITER //
CREATE PROCEDURE create_table_service_context()
BEGIN
CREATE TABLE service_context
(
id BIGINT NOT NULL AUTO_INCREMENT PRIMARY KEY,... |
<filename>Kwc/Abstract/Cards/Update/3.sql<gh_stars>10-100
ALTER TABLE `kwc_basic_cards` ADD INDEX ( `component` ) ;
|
SELECT t.title, p.fullname, p.email
FROM xpath_table('article_id', 'article_xml', 'articles',
'/article/title|/article/author/@id',
'xpath_string(article_xml,''/article/@date'') > ''2003-03-20'' ')
AS t(article_id integer, title text, author_id integer),
tblPeopleInfo AS p
... |
<reponame>opengauss-mirror/Yat
-- @testpoint: rawtohex函数与order by联合使用
drop table if exists tb;
create table tb(id int,hex int);
insert into tb values(1,3),(4,5),(8,9);
select rawtohex(concat(id,hex)) from tb order by 1;
select rawtohex(concat_ws('',id,hex)) from tb order by 1;
drop table if exists tb; |
<reponame>opengauss-mirror/Yat<filename>openGaussBase/testcase/SQL/INNERFUNC/EXTRACT/Opengauss_Function_Innerfunc_Extract_Case0063.sql
-- @testpoint: extract(field from timestamp)从给定的时间戳里获取年份的值
--(field的取值范围:year年份域)
select extract(year from timestamp '2001-02-16 20:38:40') from sys_dummy; |
<reponame>opengauss-mirror/Yat
-- @testpoint: 关键字usage,作为表名创建普通表
drop table if exists usage cascade;
create table usage(id int,name varchar(20));
create or replace procedure usage_insert
as
begin
for i in 1..10 loop
insert into usage values(i,'usa+'||i);
end loop;
end;
/
call usage_insert();
select * from... |
insert into visita (id_visita, id_estudiante, id_habitacion, fecha) values (1, 1, 932, '2021-01-08');
insert into visita (id_visita, id_estudiante, id_habitacion, fecha) values (2, 2, 932, '2021-11-06');
insert into visita (id_visita, id_estudiante, id_habitacion, fecha) values (3, 3, 932, '2021-06-14');
insert into vi... |
<reponame>emdad87/jb<gh_stars>0
-- phpMyAdmin SQL Dump
-- version 4.6.5.2
-- https://www.phpmyadmin.net/
--
-- Host: 127.0.0.1
-- Generation Time: May 17, 2017 at 04:13 PM
-- Server version: 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_CHA... |
BEGIN;
ALTER TABLE pipelines ADD UNIQUE (id, service_id);
ALTER TABLE pipeline_runs ADD UNIQUE (id, pipeline_id);
ALTER TABLE jobs ADD UNIQUE (id, pipeline_run_id);
CREATE TABLE notifications (
id SERIAL NOT NULL,
created_time TIMESTAMP WITH TIME ZONE DEFAULT now() NOT NULL,
message TEXT NOT NULL,
acknowledged... |
<reponame>LynnOwens/restdemo
CREATE TABLE customer (
id INTEGER AUTO_INCREMENT PRIMARY KEY,
name VARCHAR(255) NOT NULL,
address1 VARCHAR(50),
address2 VARCHAR(50),
city VARCHAR(50),
state VARCHAR(20),
zip INTEGER(5)
); |
create table tuser(
name text primary key not null,
passwd text not null
);
insert into tuser (name,passwd) values('admin','<PASSWORD>');
|
CREATE OR ALTER PROC usp_TransferMoney(@SenderId INT, @ReceiverId INT, @Amount DECIMAL(16,4))
AS
BEGIN
DECLARE @SenderAount DECIMAL = (SELECT a.Balance
FROM Accounts AS a
WHERE a.Id = @SenderId)
BEGIN TRAN;
EXEC usp_WithdrawMoney @SenderId, @Amount
EXEC usp_DepositMoney @ReceiverId, @Amount
IF(@Se... |
<reponame>ManuelCanulDev/ChampionsApi<filename>database.sql
SET NAMES utf8;
CREATE TABLE `champion_abilities` (
`id` int(6) NOT NULL,
`champion` int(6) NOT NULL,
`name` varchar(180) NOT NULL,
`description` text NOT NULL,
`effect` text NOT NULL,
`cost` varchar(180) NOT NULL,
`range` int(4) NOT NULL,
KEY... |
<reponame>thiagocruzrj/Integrator-Microservice
IF OBJECT_ID(N'[__EFMigrationsHistory]') IS NULL
BEGIN
CREATE TABLE [__EFMigrationsHistory] (
[MigrationId] nvarchar(150) NOT NULL,
[ProductVersion] nvarchar(32) NOT NULL,
CONSTRAINT [PK___EFMigrationsHistory] PRIMARY KEY ([MigrationId])
);... |
--This file is licensed under the University of Illinois/NCSA Open Source License. See LICENSE.TXT for details.
/**
*
* Ensure that import-data.sql and usage-time-analysis.sql are run first before
* running this file. For the total performed, I am using CodingTracker data
* instead of CodingSpectator data because... |
<reponame>LVPlum/raven<filename>QuickPacks/sqls/1422493444.sql<gh_stars>0
ALTER TABLE `uctoo_ucenter_member` ADD `type` TINYINT NOT NULL COMMENT '1为用户名注册,2为邮箱注册,3为手机注册';
UPDATE `uctoo_ucenter_member` SET `type` = '1' WHERE `uctoo_ucenter_member`.`type` =0; |
<reponame>kushalbhola/MyStuff<filename>Practice/Practice/Leetcode/DB/184_Department Highest Salary.sql
--URL: https://leetcode.com/problems/department-highest-salary/description/
--Method: 1
With cte as
(
select d.Name as Department, e.Name as Employee , e.salary as Salary, dense_rank() over (partition by d.Name... |
insert into yablog.blogusers (username,password,email,firstname,lastname,last_connection,created_at,created_by, user_profile)
values ("admin","nimda","<EMAIL>","Admin","Administrator",TODAY(), TODAY(), "admin","ADMIN");
insert into yablog.blogposts (id,title,cover, header,content, created_at, created_by, locale, rate... |
ALTER TABLE public."person" ADD CONSTRAINT "fk_person_companyid" FOREIGN KEY ("companyID") REFERENCES public."company"("id") |
# --- !Ups
ALTER TABLE public.document ADD COLUMN title2 text;
ALTER TABLE public.book ADD COLUMN print_isbn character varying(255);
ALTER TABLE public.book ADD COLUMN corporate_author_subordinate_unit character varying(255);
ALTER TABLE public.book ADD COLUMN corporate_author2 character varying(255);
ALTER ... |
<gh_stars>100-1000
ALTER TABLE custom_domain ADD COLUMN "connected" BOOLEAN DEFAULT FALSE;
|
<reponame>PhilippSalvisberg/plscope-utils
/*
* Copyright 2017 <NAME> <<EMAIL>>
*
* 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
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless re... |
<filename>db/migrations/00000000000037_add_last_cart_id_to_user/down.sql<gh_stars>0
DROP INDEX users_last_cart_id
ALTER TABLE users
DROP COLUMN last_cart_id |
<reponame>US-EPA-CAMD/easey-db-scripts<filename>camdecmpswks/views/vw_location_attribute.sql
-- View: camdecmpswks.vw_location_attribute
-- DROP VIEW camdecmpswks.vw_location_attribute;
CREATE OR REPLACE VIEW camdecmpswks.vw_location_attribute
AS
SELECT ml.stack_pipe_id,
ml.unit_id,
mla.grd_elevation,
m... |
INSERT INTO departments (department)
VALUES
('Accounting'),
('Human Resources'),
('Engineering'),
('Product Development'),
('Administration'),
('TOP SECRET');
INSERT INTO roles (title, salary, department_id)
VALUES
("Junior Accountant", 40000, 1),
("Junior Engineer", 41000, 3),
("Accounting Manager", 60000, 1),
("En... |
<reponame>kreako/soklaki
-- Could not auto-generate a down migration.
-- Please write an appropriate down migration for the SQL below:
-- alter table "public"."report" add column "date" date
not null default now();
|
insert into public.adventure(id,player__id,title,player_cards) values(DEFAULT,?,?,?) returning id, created; |
-- insert user profile
insert into Fakebook.Profile(Email,ProfilePictureUrl,FirstName,LastName,PhoneNumber,BirthDate,Status) VALUES ('<EMAIL>','https://www.houseloan.com/img/headshot-male.jpg','Demien','Bevins','1231231234','1/1/2021','Working on project');
insert into Fakebook.Profile(Email,ProfilePictureUrl,FirstNam... |
<reponame>fabsgc/gestnotes<gh_stars>0
-- phpMyAdmin SQL Dump
-- version 4.1.14
-- http://www.phpmyadmin.net
--
-- Client : 127.0.0.1
-- Généré le : Ven 09 Octobre 2015 à 13:56
-- 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 ... |
<reponame>nikolaygornakov/SoftUni-Database-Basics-MSSQL-Server
USE SoftUni
GO
SELECT FirstName, LastName FROM Employees
WHERE LEN(LastName) = 5 |
<gh_stars>1-10
-- This extension is built into postgres and needs no installation
CREATE EXTENSION postgres_fdw;
-- First define the foreign server. We use placeholders here to
-- substitute in locations so that different testing instances can
-- manipulate the location of the annex. Another alternative is to
-- use... |
-- --------------------------------------------------------
-- Host: 127.0.0.1
-- Server version: 10.1.19-MariaDB - mariadb.org binary distribution
-- Server OS: Win32
-- HeidiSQL Version: 9.5.0.5196
-- ------------------------------------------------... |
<gh_stars>1-10
delete from qrtz_cron_triggers where sched_name = 'keyworker-quartz';
delete from qrtz_scheduler_state where sched_name = 'keyworker-quartz';
delete from qrtz_fired_triggers where sched_name = 'keyworker-quartz';
delete from qrtz_locks where sched_name = 'keyworker-quartz';
delete from qrtz_paused_tr... |
<reponame>netology-group/event<gh_stars>1-10
begin;
create extension if not exists "uuid-ossp";
-- Connect to the legacy DB.
create extension if not exists "dblink";
create foreign data wrapper legacy_db_wrapper validator postgresql_fdw_validator;
create server legacy_db foreign data wrapper legacy_db_wrapper options... |
SELECT
'DROP SEQUENCE '||SEQUENCE_NAME||'; ' ||
'CALL CREATE_SEQUENCE('''|| SUBSTR(SEQUENCE_NAME, INSTR(SEQUENCE_NAME, '_')+1, INSTR(SEQUENCE_NAME, '_', 1,2)-5 )||''', '''||
SUBSTR(SEQUENCE_NAME, INSTR(SEQUENCE_NAME, '_', 1,2)+1, STRLEN(SEQUENCE_NAME))||''');'
FROM USER_SEQUENCES
WHERE SEQUENCE_NAME LIKE 'GEN... |
<reponame>taktos/ea2ddl<filename>ea2ddl-dao/src/main/resources/jp/sourceforge/ea2ddl/dao/exbhv/TConnectorBhv_selectForeignKeys.sql<gh_stars>0
-- #ForeignKey#
SELECT
CON.Connector_ID, CON.Start_Object_ID, START_OBJ.Name, OPE_SRC.Name
, CON.End_Object_ID, END_OBJ.Name, OPE_DST.Name, PARAM_SRC.Name
, PARAM_DST... |
<reponame>nyannam/controller-api
update favorites
SET deleted=false, updated=$1
where
favorite::varchar(256)=$2
returning *
|
UPDATE collection
SET publishedDate = NOW(), previewKey = NULL
WHERE published = 1 AND publishedDate IS NULL;
|
<filename>licenses/licenses.sql
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
SET AUTOCOMMIT = 0;
START TRANSACTION;
SET time_zone = "+00:00";
ALTER TABLE `accounts`
ADD `driver_license` tinyint(1) NOT NULL DEFAULT 0;
ALTER TABLE `accounts`
ADD `gun_license` tinyint(1) NOT NULL DEFAULT 0;
ALTER TABLE `accounts`
ADD `he... |
<filename>pkg/migrations/1534512804_unique_group_label.down.sql
ALTER TABLE groups
DROP CONSTRAINT "unique_label"; |
<reponame>Watch-Later/olo
CREATE TABLE `dummy` (
`id` int(10) NOT NULL AUTO_INCREMENT,
`name` varchar(255) NOT NULL,
`age` int(10) NOT NULL,
`password` varchar(512) DEFAULT NULL,
`flag` smallint(5) NOT NULL DEFAULT '0',
`tags` text NOT NULL,
`payload` text NOT NULL,
`foo` int(10) DEFAULT NULL,
`dynast... |
<filename>database/createtablesis-20190108.sql
CREATE TABLE `salary_data` (
`sald_id` int(11) PRIMARY KEY AUTO_INCREMENT,
`sald_empid` int(11) NOT NULL,
`sald_sheadid` varchar(250) NOT NULL,
`sald_shamount` double Default 0,
`sald_month` varchar(100) NOT NULL,
`sald_year` varchar(100) NOT NULL
) ENGI... |
<gh_stars>0
-- @testpoint:opengauss关键字descriptor(非保留),作为数据库名
--关键字不带引号-成功
drop database if exists descriptor;
create database descriptor;
drop database descriptor;
--关键字带双引号-成功
drop database if exists "descriptor";
create database "descriptor";
drop database "descriptor";
--关键字带单引号-合理报错
drop database if exists 'des... |
CREATE TABLE
employee (
id INTEGER,
name VARCHAR(50),
birthday DATE,
email VARCHAR(100)
);
----------
insert into employee (id, name, birthday, email) values (1, '<NAME>', '2020-01-05', '<EMAIL>');
insert into employee (id, name, birthday, email) values (2, '<NAME>', '2022-07-31', '<EMAIL>');
insert into empl... |
DROP DATABASE IF EXISTS tech_blog_db;
CREATE DATABASE tech_blog_db;
USE tech_blog_db;
-- mysql -u root -p
INSERT INTO blog (blog_title, blog_content, user_id)
VALUES ("Test Title.", "Some blog content", 1);
INSERT INTO user (username, password)
VALUES ("sophieM", "<PASSWORD>");
INSERT INTO user (username, pa... |
<gh_stars>0
USE mafia_db;
INSERT INTO department (name)
VALUES ("Security"),
("Distribution"),
("Administration"),
("Laundering"),
("Production");
INSERT INTO employee_role (title, salary, department_id)
VALUES ("Boss", 4500000, 3),
("Underboss", 2000000, 3),
("Co... |
<filename>initdb.sql<gh_stars>0
DROP DATABASE IF EXISTS `yalinidatarepresentation`;
CREATE DATABASE `yalinidatarepresentation`;
USE `yalinidatarepresentation`;
DROP TABLE IF EXISTS `cars`;
CREATE TABLE `car` (
`registration` varchar(15) NOT NULL,
`make` varchar(20) DEFAULT NULL,
`model` varchar(20) DEFAULT NULL,... |
<filename>projeto.sql
-- phpMyAdmin SQL Dump
-- version 4.8.4
-- https://www.phpmyadmin.net/
--
-- Host: 127.0.0.1
-- Generation Time: 18-Mar-2019 às 03:38
-- Versão do servidor: 10.1.37-MariaDB
-- versão do PHP: 7.3.1
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
SET AUTOCOMMIT = 0;
START TRANSACTION;
SET time_zone = "+00:... |
<gh_stars>0
-- phpMyAdmin SQL Dump
-- version 4.7.0
-- https://www.phpmyadmin.net/
--
-- Хост: 127.0.0.1
-- Час створення: Лип 18 2018 р., 12:59
-- Версія сервера: 10.1.24-MariaDB
-- Версія PHP: 7.1.6
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
SET AUTOCOMMIT = 0;
START TRANSACTION;
SET time_zone = "+00:00";
/*!40101 SE... |
<reponame>benpopoff/hyperoxemia-mimic
-- ------------------------------------------------------------------
-- Arterial blood gas table
--
-- Select all ABGs from patient with sepsis and septic shock
-- ------------------------------------------------------------------
DROP MATERIALIZED VIEW IF EXISTS abg_sepsis CASCA... |
<reponame>KhanovaSkola/khanovaskola-v3
ALTER TABLE
users ALTER registered
SET
NOT NULL;
|
<reponame>tansuluu/Opentravel
/*
-- Query: SELECT * FROM hciproject.user
LIMIT 0, 1000
-- Date: 2019-02-06 13:41
*/
INSERT INTO `user` (`user_id`,`about_me`,`active`,`age`,`country`,`email`,`experience`,`gender`,`image`,`languages`,`name`,`password`,`status`,`token`) VALUES (5,'I am from Almaty. I wanna visit Kyrgyzst... |
<gh_stars>1-10
SELECT amname
FROM pg_am
WHERE EXISTS (SELECT 1
FROM pg_proc
WHERE oid=amhandler)
ORDER BY amname; |
<reponame>1newstar/mysql-study<filename>scripts/sql_opt/sql_index_constraint.sql
/*
Index Constraint
*/
/*
查看索引
*/
USE sakila;
(shawn@localhost) [sakila] 13:58:39> SHOW INDEX FROM city\G
*************************** 1. row ***************************
Table: city
Non_unique: 0
Key_name: PRIMARY
Seq_i... |
<gh_stars>10-100
ALTER TABLE eg_applicationindex ALTER COLUMN applicantname TYPE character varying(250); |
<filename>help/ims_tpgoods.sql<gh_stars>0
/*
Navicat MySQL Data Transfer
Source Server : 192.168.3.11_we7
Source Server Version : 50554
Source Host : 192.168.3.11:3306
Source Database : we7
Target Server Type : MYSQL
Target Server Version : 50554
File Encoding : 65001
Date: 2017-07... |
<filename>PowerSchool/Parent Portal Logins.sql
--This statement lists parent portal login attempts (student name and guardian name) ordered by date.
--author: <NAME> date:11/17/20
SELECT s.STUDENT_NUMBER, s.LASTFIRST,s.GRADE_LEVEL, g.FIRSTNAME,g.LASTNAME,paah.LOGINATTEMPTDATE FROM GUARDIANSTUDENT gs --guardianstude... |
ALTER TABLE AM_WORKFLOWS ADD
WF_METADATA VARBINARY(MAX) NULL DEFAULT NULL,
WF_PROPERTIES VARBINARY(MAX) NULL DEFAULT NULL
; |
<filename>BackEnd/Core/sailfish-core/src/main/resources/com/exactpro/sf/statistics/storage/pg/migration/V1.9__testcase_hash.sql<gh_stars>10-100
ALTER TABLE sttestcaseruns
ADD COLUMN hash integer DEFAULT 0 NOT NULL; |
SELECT sumForEachMergeArray(y) FROM (SELECT sumForEachStateForEachIfArrayMerge(x) AS y FROM (SELECT sumForEachStateForEachIfArrayState([[[1, 2, 3], [4, 5, 6], [7, 8, 9]]], [1]) AS x));
|
<gh_stars>0
CREATE TABLE _gct_store_info
(
store_id INT NOT NULL AUTO_INCREMENT,
store_name VARCHAR (64),
store_website VARCHAR (120),
store_location VARCHAR (120),
store_description TEXT,
store_date DATETIME,
store_banner TEXT,
store_stat... |
<filename>data/data_task.sql<gh_stars>0
--
-- Core Form - Room Task Parial
--
INSERT INTO `core_form_field` (`Field_ID`, `type`, `label`, `fieldkey`, `tab`, `form`, `class`, `url_view`, `url_list`, `show_widget_left`, `allow_clear`, `readonly`, `tbl_cached_name`, `tbl_class`, `tbl_permission`) VALUES
(NULL, 'partial', ... |
<filename>data/install.sql
-- phpMyAdmin SQL Dump
-- version 4.8.3
-- https://www.phpmyadmin.net/
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
SET AUTOCOMMIT = 0;
START TRANSACTION;
SET time_zone = "+00:00";
-- --------------------------------------------------------
--
-- Tabellenstruktur für Tabelle `calendar`
--
CREA... |
-- A chat should be pinned for an attendee
-- IF:
-- They belong to the same conference
--
-- AND EITHER:
-- The user manually pinned it
-- The user is a member of the room, and the chat is set to mandatory pin
-- The room is public, and the chat is set to mandatory pin
--
-- ELSE: it should not be pinned.
-- ... |
<reponame>DragonFired-SNHU/DBClass_Assignment1
USE Normalization1;
DROP TABLE IF EXISTS profession;
CREATE TABLE profession (
profession_ID int(11) NOT NULL auto_increment,
profession VARCHAR(50) NOT NULL,
PRIMARY KEY (profession_ID)
) AS
SELECT DISTINCT profession
FROM my_contacts
WHERE profession IS NOT N... |
<reponame>kcushing1/Employee-Tracker
insert into departments (name)
values
("Food Services"),
("Housekeeping"),
("Engineering"),
("Marketing");
insert into roles (title, salary, dept_id)
values
("Cook", 40600.00,1),
("Housekeeping", 41800.00, 2),
("Manager", 34800, 3),
("Engineer", 60000, 4),
("Sales", 46200, 3... |
<filename>ukmbasketitn.sql
-- phpMyAdmin SQL Dump
-- version 4.6.5.2
-- https://www.phpmyadmin.net/
--
-- Host: 127.0.0.1
-- Generation Time: 22 Des 2021 pada 13.29
-- 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_SE... |
/*
PRUEBAS DE JOINS,ALTERS Y SELECTS
*/
--- seleccionar los que empiezan con a----
SELECT * FROM
sucursal
WHERE
nombre_sucursal LIKE '%a';
--- pruebas outer / inner joins ----
SELECT
*
FROM
sucursal s
LEFT JOIN cuenta c ON s.nombre_sucursal = c.nombre_sucursal;
--- insertar sin todad la c... |
ALTER TABLE xcolab_ProposalUnversionedAttribute CHANGE addtionalId additionalId BIGINT(20);
update comment_CategoryGroup set url = '/discussion' where groupId = 701;
|
<reponame>Bayudiartaa/pengaduan-masyarakat
-- MySQL dump 10.13 Distrib 8.0.27, for Linux (x86_64)
--
-- Host: localhost Database: pengaduan_masyarakat
-- ------------------------------------------------------
-- Server version 8.0.27-0ubuntu0.20.04.1
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */... |
create temporary table good_repeat_features as
select min(repeat_feature_id) as repeat_feature_id
from repeat_feature
group by seq_region_id, seq_region_start, seq_region_end, seq_region_strand, analysis_id;
create index good_repeat_features_index
using btree on good_repeat_features (repeat_feature_id);
de... |
<reponame>myinstantcms/icms2-google-2fa
DROP TABLE IF EXISTS `{#}users_google2fa`;
CREATE TABLE `{#}users_google2fa` (
`id` int(11) NOT NULL AUTO_INCREMENT,
`user_id` int(11) NOT NULL,
`is_enabled` tinyint(1) DEFAULT 0,
`secret_key` varchar(50) DEFAULT NULL,
`restore_code` mediumtext DEFAULT NULL,
PRIMARY K... |
<gh_stars>0
SELECT p.filename, p.name as name, p.time, p.timeReal, p.length, p.weight, j.id as jobId, j.date, j.date_until, j.date_done, j.notes, u.name as user, s.name as status, j.amount
FROM print p
INNER JOIN job j ON p.id = j.printId
INNER JOIN status s ON j.statusId = s.id
INNER JOIN user u ON j.u... |
CREATE TABLE experiments
(id INTEGER PRIMARY KEY AUTOINCREMENT
,task_name TEXT
,model_name TEXT
,commit_id TEXT
,created_date DATE
,last_updated_date DATE
);
CREATE TABLE results
(id INTEGER PRIMARY KEY AUTOINCREMENT
,exp_id ... |
SELECT
Id
,[Name]
,Size
FROM Files
WHERE Size > 1000 AND [Name] LIKE '%html%'
ORDER BY Size DESC, Id, [Name] |
CREATE PROCEDURE [dbo].[GetDataLockStatus]
@DataLockEventId BIGINT
AS
BEGIN
SELECT *
FROM
DataLockStatus
WHERE
DataLockEventId = @DataLockEventId
END
|
--
-- PostgreSQL database dump
--
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 search_path = public, pg_catalog;
SET default_tablespace = '';
SET default_with_oids = fals... |
-- MySQL Workbench Forward Engineering
SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0;
SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0;
SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='TRADITIONAL,ALLOW_INVALID_DATES';
-- -----------------------------------------------------
-- Schema kbo
-- ---... |
<filename>db/db_mysql/migrations/20180609164054_0.7.0_update_html_storage.sql<gh_stars>1-10
-- +goose Up
-- SQL in section 'Up' is executed when this migration is applied
ALTER TABLE templates MODIFY html MEDIUMTEXT;
ALTER TABLE pages MODIFY html MEDIUMTEXT;
-- +goose Down
-- SQL section 'Down' is executed when this ... |
DROP TYPE IF EXISTS bridge_api_list_pop_communities CASCADE;
CREATE TYPE bridge_api_list_pop_communities AS (
name VARCHAR,
title VARCHAR
);
DROP FUNCTION IF EXISTS bridge_list_pop_communities
;
CREATE OR REPLACE FUNCTION bridge_list_pop_communities(
in _limit INT
)
RETURNS SETOF bridge_api_list... |
<gh_stars>0
-- phpMyAdmin SQL Dump
-- version 5.0.4
-- https://www.phpmyadmin.net/
--
-- Host: 127.0.0.1
-- Tempo de geração: 23-Maio-2021 às 16:53
-- Versão do servidor: 10.4.17-MariaDB
-- versão do PHP: 8.0.2
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
START TRANSACTION;
SET time_zone = "+00:00";
/*!40101 SET @OLD_CHA... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.