This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
USE grnti; | |
GO | |
UPDATE cld | |
SET ParentId = par.Id | |
FROM [dbo].[Categories] as cld | |
left join [dbo].[Categories] as par on | |
( -- Условия для связей 1-2 уровней | |
par.Num2 is null and par.Num3 is null and -- Условия для родительских записей | |
par.Num1 = cld.Num1 and -- Условия совпадения | |
not cld.Num2 is null and cld.Num3 is null -- Условия для дочерних записей |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Abstract contract for the full ERC 20 Token standard | |
// https://github.com/ethereum/EIPs/blob/master/EIPS/eip-20.md | |
pragma solidity ^0.4.21; | |
contract EIP20Interface { | |
/* This is a slight change to the ERC20 base standard. | |
function totalSupply() constant returns (uint256 supply); | |
is replaced with: | |
uint256 public totalSupply; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Abstract contract for the full ERC 20 Token standard | |
// https://github.com/ethereum/EIPs/blob/master/EIPS/eip-20.md | |
pragma solidity ^0.4.21; | |
contract EIP20Interface { | |
/* This is a slight change to the ERC20 base standard. | |
function totalSupply() constant returns (uint256 supply); | |
is replaced with: | |
uint256 public totalSupply; |