@@ -302,28 +302,28 @@ package body AdaBase.Connection.Base.MySQL is
302
302
303
303
declare
304
304
-- populate client version information
305
- result : ABM.my_ulong := ABM.mysql_get_client_version;
305
+ result : constant ABM.my_ulong := ABM.mysql_get_client_version;
306
306
begin
307
307
conn.info_client_version := convert_version (Positive (result));
308
308
end ;
309
309
310
310
declare
311
311
-- populate client information
312
- result : ABM.ICS.chars_ptr := ABM.mysql_get_client_info;
312
+ result : constant ABM.ICS.chars_ptr := ABM.mysql_get_client_info;
313
313
begin
314
314
conn.info_client := CT.SUS (ABM.ICS.Value (Item => result));
315
315
end ;
316
316
317
317
declare
318
318
-- populate server version information
319
- result : ABM.my_ulong := ABM.mysql_get_server_version (conn.handle);
319
+ result : constant ABM.my_ulong := ABM.mysql_get_server_version (conn.handle);
320
320
begin
321
321
conn.info_server_version := convert_version (Positive (result));
322
322
end ;
323
323
324
324
declare
325
325
-- populate server information
326
- result : ABM.ICS.chars_ptr := ABM.mysql_get_server_info (conn.handle);
326
+ result : constant ABM.ICS.chars_ptr := ABM.mysql_get_server_info (conn.handle);
327
327
begin
328
328
conn.info_server := CT.SUS (ABM.ICS.Value (Item => result));
329
329
end ;
@@ -394,7 +394,6 @@ package body AdaBase.Connection.Base.MySQL is
394
394
procedure setTransactionIsolation (conn : out MySQL_Connection;
395
395
isolation : Trax_Isolation)
396
396
is
397
- use type Trax_Isolation;
398
397
sql : constant String := " SET SESSION TRANSACTION ISOLATION LEVEL " &
399
398
ISO_Keywords (isolation);
400
399
begin
@@ -644,7 +643,6 @@ package body AdaBase.Connection.Base.MySQL is
644
643
ABM.MYSQL_TYPE_VAR_STRING |
645
644
ABM.MYSQL_TYPE_STRING =>
646
645
declare
647
- use type ABM.MY_CHARSET_INFO;
648
646
chsetnr : constant Natural := Natural (field.charsetnr);
649
647
bin_set : constant Natural := 63 ;
650
648
binary : constant Boolean := (chsetnr = bin_set);
@@ -770,7 +768,7 @@ package body AdaBase.Connection.Base.MySQL is
770
768
771
769
result : fldlen (1 .. num_columns) := (others => 0 );
772
770
naccess : cres_access;
773
- MLA : ABM.my_ulong_access := ABM.mysql_fetch_lengths
771
+ MLA : constant ABM.my_ulong_access := ABM.mysql_fetch_lengths
774
772
(result => result_handle);
775
773
776
774
begin
@@ -1111,8 +1109,8 @@ package body AdaBase.Connection.Base.MySQL is
1111
1109
procedure establish_uniform_encoding (conn : out MySQL_Connection)
1112
1110
is
1113
1111
use type ABM.my_int;
1114
- result : ABM.my_int;
1115
- charset : String := CT.USS (conn.character_set);
1112
+ result : ABM.my_int;
1113
+ charset : constant String := CT.USS (conn.character_set);
1116
1114
csname : ABM.ICS.chars_ptr := ABM.ICS.New_String (charset);
1117
1115
begin
1118
1116
if conn.prop_active then
@@ -1153,9 +1151,9 @@ package body AdaBase.Connection.Base.MySQL is
1153
1151
if conn.prop_active then
1154
1152
-- conn.dummy := True;
1155
1153
declare
1156
- set : ABM.ICS.chars_ptr :=
1154
+ set : constant ABM.ICS.chars_ptr :=
1157
1155
ABM.mysql_character_set_name (handle => conn.handle);
1158
- setstr : String := ABM.ICS.Value (Item => set);
1156
+ setstr : constant String := ABM.ICS.Value (Item => set);
1159
1157
begin
1160
1158
return ACH.To_Upper (setstr);
1161
1159
end ;
@@ -1170,8 +1168,8 @@ package body AdaBase.Connection.Base.MySQL is
1170
1168
-- -------------------------------
1171
1169
procedure retrieve_uniform_encoding (conn : out MySQL_Connection)
1172
1170
is
1173
- charset : String := character_set (conn => conn);
1174
- charsetuc : String := ACH.To_Upper (charset);
1171
+ charset : constant String := character_set (conn => conn);
1172
+ charsetuc : constant String := ACH.To_Upper (charset);
1175
1173
begin
1176
1174
conn.encoding_is_utf8 := (charsetuc = " UTF8" );
1177
1175
conn.character_set := CT.SUS (charset);
0 commit comments