View Issue Details

IDProjectCategoryView StatusLast Update
0000236trackerdata servicingpublic2019-09-09 23:57
ReporterDigitalMy 
PrioritynormalSeverityminorReproducibilityhave not tried
Status assignedResolutionopen 
PlatformIBMPCOSWindowsOS Version2008R2
Product Version 
Fixed in Version 
Summary0000236: Transfer data and start mantis with MSSQL DB
Descriptiondata migration to DBMS Microsoft
TagsNo tags attached.
FinishDate
LaboriousnessIndex1
PriorityIndex5
StartDate
WasteTime

Relationships

related to 0000290 assignedDigitalMy Update SQL server (MicroSoft) to version 2019 for UTF-8 support 

Activities

DigitalMy

2017-07-04 13:30

administrator   ~0000546

Last edited: 2019-07-11 17:55

View 6 revisions

MSSQL version Mantis 2.51 installable with new DBMS = MS SQL (mssqlnative),
but have got several faults.

Trasfer fails:
Cannot locate the mapping file to map the provider types to SSIS types
and
Error 0xc02020ff: Source - mantis_bug_file_table [1]: The Source - mantis_bug_file_table was unable to retrieve column information for the SQL command. The following error occurred: ERROR [42000] [MySQL][ODBC 5.3(w) Driver][mysqld-5.5.25a]You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '"mantis_bug_file_table"' at line 1
 (SQL Server Import and Export Wizard)
Pipeline component has returned HRESULT error code 0xC02020FF from a method call. (Microsoft.SqlServer.DTSPipelineWrap)

So, it reads or sends extra quotes in table name. Fixed that.

mantisbt.org/wiki/doku.php/mantisbt:mysql_to_mssql

Additional issue with collation , MS SQL does not have UTF8 one.... and we loose some text on transfer, because mantis created data types are non-unicode. Linked issue 290

DigitalMy

2017-07-04 13:48

administrator   ~0000547

Last edited: 2017-07-04 14:52

View 4 revisions

Mapping files (some) found in C:\Program Files\Microsoft SQL Server\100\DTS\MappingFiles\ and C:\Program Files\Microsoft SQL Server\110\DTS\MappingFiles\ and C:\Program Files (x86)\Microsoft SQL Server\110\DTS\MappingFiles\
not in C:\Program Files (x86)\Microsoft SQL Server\100\DTS\MappingFiles\

copied to this folder, but need MySQL mapping

in log we could see it works in c:\Program Files (x86)\Microsoft SQL Server\110\DTS\ folders

MSSQLToSSIS10.XML used for destination

MySQLToMSSql10.xml
MySQLToSSIS10.xml
MSSQLToMySQL.xml
SSISToMySQL.xm
need for source

DigitalMy

2017-07-04 13:57

administrator   ~0000548

Last edited: 2019-07-05 21:29

View 7 revisions

Used ODBC System DSN x32, chosen MySQL ODBC 5.3 Unicode Driver.
Tested custom query (way two).
Made select manually SELECT * FROM `bugtracker`.`mantis_bug_file_table`;
and set "delete rows in destination table" + "allow identity insert",
and it made transfer successfully (one table).

Need way one to work.
After import manage with query like SELECT * INTO newtable [IN externaldb] FROM oldtable WHERE condition;

Anyway, there are minor DB structure changes, to be fixed manually.
Mantis changed from unserialize( $t_raw_value ); to json_decode( $t_raw_value, true ); \ at the same time as from serialize( $p_value ); to json_encode( $p_value );
This results in SYSTEM ERROR 'Argument 1 passed to columns_remove_invalid() must be of the type array, null given...'

DigitalMy

2019-07-05 19:19

administrator   ~0000790

Last edited: 2019-07-05 19:44

View 2 revisions

1. installed new MantisBT version 2.21.1 with new MSSQL DB (admin/install.php)
2. Used "Microsoft SQL Server Migration Assistant for MySQL" to copy database content from old DB
3. Copied config files and upload files to new folder, adjusted config files
4. Fix version structure changes with custom scripts:
DELETE FROM [mantis].[dbo].[mantis_config_table] WHERE TYPE=3
UPDATE [mantis].[dbo].[mantis_config_table] SET value='209' WHERE config_id='database_version'

DigitalMy

2019-07-11 17:58

administrator   ~0000794

Last edited: 2019-07-11 18:28

View 5 revisions

Next error after press button "Manage Global Profiles" go to link /manage_prof_menu_page.php


APPLICATION ERROR # 12
This account is protected. You are not allowed to access this until the account protection is lifted.
Please use the "Back" button in your web browser to return to the previous page. There you can correct whatever problems were identified in this error or select another action. You can also click an option from the menu bar to go directly to a new section.

remove line
current_user_ensure_unprotected();
 from
account_prof_menu_page.php
 file - fixed

 same error on
account_prof_update.php
account_prof_edit_page.php

DigitalMy

2019-09-09 23:57

administrator   ~0000807

fix file upload:
edit core/file_api.php
remove line 845 :
$t_param['content'] = $c_content;

or add condition above :
if( !db_is_oracle() and $t_method=='DATABASE')