change normal encryption to none encryption
This commit is contained in:
parent
c5d02cbeec
commit
b808f3bd87
|
@ -153,7 +153,7 @@ class ColumnMeta
|
|||
public $dataType; //a string that includes the size of the type if necessary (e.g., decimal(10,5))
|
||||
public $colName; //column name
|
||||
public $options; //a string that is null by default (e.g. NOT NULL Identity (1,1) )
|
||||
public $encType; //randomized, deterministic, or normal; default is null
|
||||
public $encType; //randomized, deterministic, or none; default is null
|
||||
public $forceEncrypt; //force encryption on a datatype not supported by Column Encrypton
|
||||
|
||||
public function __construct($dataType, $colName = null, $options = null, $encType = null, $forceEncrypt = false)
|
||||
|
@ -169,7 +169,7 @@ class ColumnMeta
|
|||
if (isColEncrypted()) {
|
||||
$this->encType = "deterministic";
|
||||
} else {
|
||||
$this->encType = "normal";
|
||||
$this->encType = "none";
|
||||
}
|
||||
} else {
|
||||
$this->encType = $encType;
|
||||
|
|
|
@ -48,7 +48,7 @@ try {
|
|||
$num = $stmt2->fetchColumn();
|
||||
echo "There are $num rows in the table.\n";
|
||||
|
||||
createTable($conn1, $tableName, array(new ColumnMeta("int", "idx", "NOT NULL PRIMARY KEY", "normal"), "txt" => "varchar(20)"));
|
||||
createTable($conn1, $tableName, array(new ColumnMeta("int", "idx", "NOT NULL PRIMARY KEY", "none"), "txt" => "varchar(20)"));
|
||||
insertRow($conn1, $tableName, array("idx" => 0, "txt" => 'String0'));
|
||||
insertRow($conn1, $tableName, array("idx" => 1, "txt" => 'String1'));
|
||||
insertRow($conn1, $tableName, array("idx" => 2, "txt" => 'String2'));
|
||||
|
|
|
@ -15,7 +15,7 @@ try {
|
|||
|
||||
// Prepare test table
|
||||
$tableName = "pdo_test_table";
|
||||
createTable($conn1, $tableName, array(new ColumnMeta("int", "idx", "NOT NULL PRIMARY KEY", "normal"), "txt" => "varchar(20)"));
|
||||
createTable($conn1, $tableName, array(new ColumnMeta("int", "idx", "NOT NULL PRIMARY KEY", "none"), "txt" => "varchar(20)"));
|
||||
insertRow($conn1, $tableName, array("idx" => 0, "txt" => "String0"));
|
||||
insertRow($conn1, $tableName, array("idx" => 1, "txt" => "String1"));
|
||||
insertRow($conn1, $tableName, array("idx" => 2, "txt" => "String2"));
|
||||
|
|
|
@ -15,7 +15,7 @@ try {
|
|||
|
||||
// Prepare test table
|
||||
$tableName = "pdo_test_table";
|
||||
createTable($conn1, $tableName, array(new ColumnMeta("int", "id", "NOT NULL PRIMARY KEY", "normal"), "label" => "char(1)"));
|
||||
createTable($conn1, $tableName, array(new ColumnMeta("int", "id", "NOT NULL PRIMARY KEY", "none"), "label" => "char(1)"));
|
||||
insertRow($conn1, $tableName, array("id" => 1, "label" => "a"));
|
||||
insertRow($conn1, $tableName, array("id" => 2, "label" => "b"));
|
||||
insertRow($conn1, $tableName, array("id" => 3, "label" => "c"));
|
||||
|
|
|
@ -16,7 +16,7 @@ try {
|
|||
// Prepare test table
|
||||
$dataCols = "id, label";
|
||||
$tableName = "pdo_test_table";
|
||||
createTable($conn1, $tableName, array(new ColumnMeta("int", "id", "NOT NULL PRIMARY KEY", "normal"), "label" => "char(1)"));
|
||||
createTable($conn1, $tableName, array(new ColumnMeta("int", "id", "NOT NULL PRIMARY KEY", "none"), "label" => "char(1)"));
|
||||
insertRow($conn1, $tableName, array("id" => 1, "label" => 'a'));
|
||||
insertRow($conn1, $tableName, array("id" => 2, "label" => 'b'));
|
||||
insertRow($conn1, $tableName, array("id" => 3, "label" => 'c'));
|
||||
|
|
|
@ -15,7 +15,7 @@ try {
|
|||
|
||||
// Prepare test table
|
||||
$tableName = "pdo_test_table";
|
||||
createTable($conn1, $tableName, array(new ColumnMeta("int", "id", "NOT NULL PRIMARY KEY", "normal"), "label" => "char(1)"));
|
||||
createTable($conn1, $tableName, array(new ColumnMeta("int", "id", "NOT NULL PRIMARY KEY", "none"), "label" => "char(1)"));
|
||||
insertRow($conn1, $tableName, array("id" => 1, "label" => "a"));
|
||||
insertRow($conn1, $tableName, array("id" => 2, "label" => "b"));
|
||||
insertRow($conn1, $tableName, array("id" => 3, "label" => "c"));
|
||||
|
|
|
@ -106,7 +106,7 @@ function katmaiSparseChar($conn)
|
|||
if ($input !== trim($value1)) {
|
||||
echo "The value is unexpected!\n";
|
||||
}
|
||||
// trimming it required since SPARSE is not supported for encrypted columns
|
||||
// trimming is required since SPARSE is not supported for encrypted columns
|
||||
if (trim($value1) !== trim($value2)) {
|
||||
echo "The values don't match!\n";
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue