SlideShare a Scribd company logo
© 2017 Embarcadero Technologies, Inc.
All rights reserved. Proprietary and confidential.
BDEを使った業務アプリを
移行ツールで最新化
Delphi / C++Builder
業務アプリケーション 刷新実践法
2017年4月14日(金) 14:00~17:00
© 2017 Embarcadero Technologies, Inc.
All rights reserved. Proprietary and confidential.
BDEを使った業務アプリを
移行ツールで最新化
3© 2017 Embarcadero Technologies, Inc. All rights reserved. Proprietary and confidential. #embtwebi_jp
「BDEを使った業務アプリを移行ツールで最新化」アジェンダ
セミナー対象:BDEを使用中のコード資産をお持ちの方
時間: 約50分
• BDEと取り巻く環境
• 既存のコードは財産
• 移行ツールと移行手順実践
• 移行後の広がりと最新化
4© 2017 Embarcadero Technologies, Inc. All rights reserved. Proprietary and confidential. #embtwebi_jp
BDEとは
 Borland Database Engine
• Delphi 6以前 にバンドル
• 最新バージョンversion 5.2
 優れたデータベース・ミドルウエア
• dBase やParadox, Microsoft Access などに特殊ドライバなしでアクセス
• InterBase, SQL Server, Oracle, DB2などにSQL Linkドライバでアクセス
 データベースにビジュアルコンポーネントでアクセス
• TTable, TQuery, TStroedProc, TDataBase, TSession, TUpdateSQL…
5© 2017 Embarcadero Technologies, Inc. All rights reserved. Proprietary and confidential. #embtwebi_jp
2017年におけるBDEの現状
 Borland Database Engine…
• Delphi6以前 (2001年)に付属 :Windows XP 発表年
• 最終バージョンversion 5.2 :2002 年以降アップデートしていない
• 製品のライフサイクル :サポートは継続していない
• Desktop DBのため、dBASE, Paradoxが主たるターゲット
• 対応データベースが最新ではない
• マルチデバイス・クロスプラットフォーム開発に対応していない
• Unicodeに対応していない
• 16bit / 32bitの開発まで
 Windows XPが最終サポート対象OS
• ユーザーアカウントコントロールの考慮をしていない
• Windows XP自体のサポートが終了
6© 2017 Embarcadero Technologies, Inc. All rights reserved. Proprietary and confidential. #embtwebi_jp
BDEサポート範囲のままではマイナスの資産?
 Windows XPのまま運用
• セキュリティリスク
 デスクトップDBで運用
• マルチデバイス運用に対し接続の壁
 新データベース接続の壁
• 古いクライアントドライバのみ
• Unicodeデータベース採用時の壁
 サーバー、ハードウエアの老朽化
• 古いServer OS、相対的なパフォーマンスの低下
 開発した資産が重荷へ…
• 多数のC/Sプロジェクト、FAアプリケーション
7© 2017 Embarcadero Technologies, Inc. All rights reserved. Proprietary and confidential. #embtwebi_jp
移行で古いプロジェクトをプラスの資産に
 既存のコードを生かして最新環境へ
• 少ない労力で旧BDEから最新FireDACへ更新可能
• FireDACへ更新で最新環境へ接続が可能に
 移行によってプロジェクトをリフレッシュ
• 新データベースへの移行
• 新サーバーへの移行
• 新OSの適用
8© 2017 Embarcadero Technologies, Inc. All rights reserved. Proprietary and confidential. #embtwebi_jp
移行においてのポイントとなる点
 OSの更新、64bit化が必要
• 32bit → 64bit、User Account Control を考慮に入れつつ改変
 サードパーティ ライブラリ、コンポーネントの移行
• 古い帳票ツールの移行:FastReportの利用、QuickReport 最新版の利用 を
 使用文字コードをUnicode対応に
• Ansi (SJIS → UTF-8,UTF-16) : Charのサイズ、ポインタの取り扱い, File I/Oの際の留意
 旧サーバーの更新はデータベースの更新を伴う
• デスクトップDB: Paradox から InterBase, Oracle 8 、さらに Oracle11g等最新化
 データベース接続ミドルウェアの更新
• BDE → FireDACへ更新、コンポーネントの書換え
9© 2017 Embarcadero Technologies, Inc. All rights reserved. Proprietary and confidential. #embtwebi_jp
BDEの移行先として:「FireDAC」
 最新データベースミドルウエア・アクセスコンポーネント
• BDEのコンポーネントに対応するコンポーネントを実装
• Delphi / C++Builder 10.2 Tokyoで利用可※
• 多数かつ最新のデータベース対応
• VCLのまま使える
• 移行ツールあり
• マルチデバイス対応 (FireMonkey利用時)
※ローカルデータベースアクセスはPro版以上、リモートデータベースアクセスは Pro版 + FireDAC Add-on Pack以上
10© 2017 Embarcadero Technologies, Inc. All rights reserved. Proprietary and confidential. #embtwebi_jp
BDEとFireDACの親和性
 親和性の高い対応コンポーネント
BDE
TDataBase
TSession
TTable
TQuery
TStoredProc
TUpdateSQL
TBatchMove
TDatabase
TQuery
TTable
TDataSource
TFDConnection
TFDQuery
TFTable
TFDConnection
TFDManager
TFDTable
TFDQuery
TFDStoredProc
TFDUpdateSQL
TFDDataMove
TFDPhysXXXXDriveLink
TFDGUIxWaitCursor
TDBGrid
11© 2017 Embarcadero Technologies, Inc. All rights reserved. Proprietary and confidential. #embtwebi_jp
DBMS
FireDAC
Delphi/C++Builder
FireDACの構成
FireMonkey および VCL
非ビジュアルコンポーネント[Comp] ビジュアルコンポーネント/フォーム [GUIx]
ローカルストレージ [DatS]
データアダプタ [DApt]
デバッグ/パフォーマンスモニタ
[Moni]
ネイティブドライバ [Phys] ブリッジドライバ [Phys]
Oracle DB2
MS
SQL
InterBase
Firebird
PG
SQL
My
SQL
Sybase
ASA
SQLite
MS
Access
ODBC dbExp
DBMSクライアントソフトウエア
Oracle DB2
MS
SQL
InterBase
Firebird
PG
SQL
My
SQL
Sybase
ASA
SQLite
MS
Access
Sybase
ASE
Informix …
ODBCODBCdbExpress
ドライバ
ODBCODBCODBC
ドライバ
FireDACがDBへのアクセスをコンポーネントとして提供
12© 2017 Embarcadero Technologies, Inc. All rights reserved. Proprietary and confidential. #embtwebi_jp
 reFind
• 無料
• コマンドラインツール
 Delphi Parser
• GUI付
• 有料
• 変更ルールをカスタマイズ
BDE to FireDAC 移行ツール
© 2016 Embarcadero Technologies, Inc. All rights reserved. Proprietary and confidential. 13
ReFind:
BDEコンポーネントを
FireDACコンポーネントに
移行する実践
14© 2017 Embarcadero Technologies, Inc. All rights reserved. Proprietary and confidential. #embtwebi_jp
BDEの移行に必要となる主な手順
 デモのポイント
 ツールで一括変換
 BDEプロジェクト→FireDACで動作
 エンバカデロで公開しているDocWiki掲載の
FireDACへのBDEアプリケーションの移行を
もとに紹介
BDE to FireDAC : コンポーネント変換
データベースマッピングの調整
データベース接続設定プロパティの更新
非使用コンポーネントコードの削除・変更
新規コンポーネントの追加 (ドライバ、Wait)
互換性のないプロパティの調整
API・クエリの更新
※全実施手順参考はブログに掲載
https://community.embarcadero.com/blogs/entry/delphi-c-builder-bde-japan
15© 2017 Embarcadero Technologies, Inc. All rights reserved. Proprietary and confidential. #embtwebi_jp
デモ 参考:Delphi 6 での BDE使用画面
 参考となる資料:DockWiki「FireDACへのBDEアプリケーションの移行」
http://docwiki.embarcadero.com/RADStudio/Berlin/ja/FireDAC_への_BDE_アプリケーションの移行
 デモサンプルコードでは
データモジュールに多数の
BDEコンポーネントを使用
16© 2017 Embarcadero Technologies, Inc. All rights reserved. Proprietary and confidential. #embtwebi_jp
FireDAC データマッピング
 参考Dockwiki - データ型マッピング :
http://docwiki.embarcadero.com/RADStudio/Berlin/ja/データ型マッピング(FireDAC)
プロパティ 説明
PrecMin/PrecMax ソース データ型の数値精度の範囲を定義します。
ScaleMin/ScaleMax ソース データ型の数値スケールの範囲を定義します。
SizeMin/SizeMax ソース データ型の文字列長の範囲を定義します。
SourceDataType ソース(変換元)データ型
TargetDataType ターゲット(変換先)データ型
NameMask 列名マスク
TypeMask 列のデータ型マスク
 FireDACのデータマッピングを使って、BDE時代のデータ型と互換性を持たせることが可能
• TFDConnectionの接続エディタのオプションで設定
17© 2017 Embarcadero Technologies, Inc. All rights reserved. Proprietary and confidential. #embtwebi_jp
FireDAC移行後は
 FireDACの機能を生かそう
• DML配列機能
• マクロ…
 三層への対応
• リモートデータベース化
• 中間サーバーの構築
• ブラウザアクセス化
 マルチデバイス開発と対応
• 中間サーバーへのモバイルデバイス接続
• クロスプラットフォーム開発
18© 2017 Embarcadero Technologies, Inc. All rights reserved. Proprietary and confidential. #embtwebi_jp
資産として生かす
 過去に作り上げたプロジェクト・プログラム
• VCLで構築
• ANSI文字列
• デスクトップDBやクラサバで動作
 いま取り掛からなければならない課題
• クライアント側、サーバ側OSのサポート終了、新OSの対応
• DBのバージョンアップ
• ハードウエアの老朽化…
 将来に実現したいビジネスモデル
• モバイルデバイスの利用、マルチOS対応
• クラウドの対応
• IOTを使ったビジネス
19© 2017 Embarcadero Technologies, Inc. All rights reserved. Proprietary and confidential. #embtwebi_jp
RDBMS
デスクトップ
アプリケーション
デスクトップDB
アプリケーション
クライアントサーバー
アプリケーション
Windowsデスクトップ Windowsデスクトップ Windowsクライアント
デスクトップDB
20© 2017 Embarcadero Technologies, Inc. All rights reserved. Proprietary and confidential. #embtwebi_jp
RDBMS
デスクトップ
アプリケーション
デスクトップDB
アプリケーション
Windowsデスクトップ
クライアントサーバー
アプリケーション
macOSデスクトップ
Windowsデスクトップ
macOSデスクトップ
Windowsクライアント
macOSクライアント
64-bit
Unicode
64-bit
Unicode
64-bit
Unicode
21© 2017 Embarcadero Technologies, Inc. All rights reserved. Proprietary and confidential. #embtwebi_jp
RDBMS
クライアントサーバー
アプリケーション
Windowsクライアント
macOSクライアント
64-bit
Unicode
22© 2017 Embarcadero Technologies, Inc. All rights reserved. Proprietary and confidential. #embtwebi_jp
クライアントサーバーアプリケーション + 中間サーバー
InterBase
中間サーバー
モバイル
クライアント
RDBMS
RAD Server
DataSnap
Windowsクライアント
macOSクライアント
64-bit
Unicode
23© 2017 Embarcadero Technologies, Inc. All rights reserved. Proprietary and confidential. #embtwebi_jp
中間サーバー
IoTデバイス
モバイル
クライアント
ビッグデータ
デスクトップクライアント
HTTP(S)
REST
JSON HTTP(S)
REST
JSON
HTTP(S)
REST
JSON
クラウドサービス
RAD Server
将来的なビジネスモデル例
レガシーシステム
独自のプロトコルで接続
RDBMS
Windowsクライアント
典型的なC/Sシステム
24© 2017 Embarcadero Technologies, Inc. All rights reserved. Proprietary and confidential. #embtwebi_jp
「BDEを使った業務アプリを移行ツールで最新化」まとめ
セミナー対象:BDEを使用中のコード資産をお持ちの方
時間: 約50分
• BDEと取り巻く環境
• 既存のコードは財産
• 移行ツールと移行手順実践
• 移行後の広がりと最新化
25© 2017 Embarcadero Technologies, Inc. All rights reserved. Proprietary and confidential. #embtwebi_jp
FireDAC : 参考となる資料
 Embarcadero DockWiki
• FireDAC
http://docwiki.embarcadero.com/RADStudio/Berlin/ja/FireDAC
• FireDAC への BDE アプリケーションの移行
http://docwiki.embarcadero.com/RADStudio/Berlin/ja/FireDAC_への_BDE_アプリケーションの移行
• データ型マッピング(FireDAC)
http://docwiki.embarcadero.com/RADStudio/Berlin/ja/データ型マッピング(FireDAC)
 28thデベロッパーキャンプにおけるFireDACの紹介
• はじめてのFireDAC : PDF
http://edn.embarcadero.com/article/images/43368/a2.pdf
• YouTube
https://www.youtube.com/watch?v=lDD6z4NuGEo
https://www.youtube.com/watch?v=ZcLu6yq3wHE
26© 2017 Embarcadero Technologies, Inc. All rights reserved. Proprietary and confidential. #embtwebi_jp
移行 : 参考となる資料
 エンバカデロ Webサイト
• RAD Studioマイグレーションセンター
http://www.embarcadero.com/jp/rad-in-action/migration-upgrade-center
 エンバカデロ ホワイトペーパーダウンロード
• RAD Studio / Delphi / C++Builder 旧バージョンからの移行
http://forms.embarcadero.com/rad-migration-papers
 エンバカデロ デベロッパーズ ネットワーク
• BDE から FireDAC への移行 - Paradox から InterBase の場合
http://edn.embarcadero.com/jp/article/42974
 エンバカデロ 日本人ブログ
• BDEを使った業務アプリを移行ツールで最新化
https://community.embarcadero.com/blogs/entry/delphi-c-builder-bde-japan
27© 2017 Embarcadero Technologies, Inc. All rights reserved. Proprietary and confidential. #embtwebi_jp
移行ツール: 参考となる資料
 reFind
• http://docwiki.embarcadero.com/RADStudio/Berlin/ja/Perl_RegEx_式を使
用する検索および置換ユーティリティ:_reFind.exe
 Delphi Parser
• https://delphiparser.com/
先日のセミナー内容を
弊社ブログに掲載
© 2016 Embarcadero Technologies, Inc. All rights reserved. Proprietary and confidential. 28
THANKS!
www.embarcadero.com/jp

More Related Content

PPTX
データベースアプリケーション開発セミナー・最新のデータベースとアプリケーション開発の関係
PPTX
【U-22】Delphi / C++Builder / RAD Studio 概要
PPTX
Delphi / C++Builder 業務アプリケーション 刷新実践法: BDEを使った業務アプリを 移行ツールで最新化
PPTX
移行セミナー BDE to FireDAC 20161018
PDF
.NET Conf 2017 Japan Keynote ".NET Everywhere!"
PPTX
20220409 AWS BLEA 開発にあたって検討したこと
PPTX
(Live Tokyo) 米GEのIoT基盤「Predix」を支えるNoSQL Couchbaseモバイルソリューション
PDF
CODT2020 ビジネスプラットフォームを支えるCI/CDパイプライン ~エンタープライズのDevOpsを加速させる運用改善Tips~
データベースアプリケーション開発セミナー・最新のデータベースとアプリケーション開発の関係
【U-22】Delphi / C++Builder / RAD Studio 概要
Delphi / C++Builder 業務アプリケーション 刷新実践法: BDEを使った業務アプリを 移行ツールで最新化
移行セミナー BDE to FireDAC 20161018
.NET Conf 2017 Japan Keynote ".NET Everywhere!"
20220409 AWS BLEA 開発にあたって検討したこと
(Live Tokyo) 米GEのIoT基盤「Predix」を支えるNoSQL Couchbaseモバイルソリューション
CODT2020 ビジネスプラットフォームを支えるCI/CDパイプライン ~エンタープライズのDevOpsを加速させる運用改善Tips~

What's hot (20)

PDF
Docker Desktop WSL2 Backendで捗るWindows PCのコンテナ開発環境
PDF
C# における Redis 徹底活用
PDF
de:code 2019 DT06 vs-show どっちのVSショー
PDF
[AWS DevDay] Cognito / Amplify で加速するエンタープライズのアプリケーション開発
PPTX
DeNA private cloudのその後 #denatechcon
PDF
Angular ユーザーなら押さえておきたい! TypeScript と Visual Studio Code の基礎と活用
PDF
MongoDB社の製品紹介 2019-MongoDB EA&Atlas
PDF
.NET 6の期待の新機能とアップデート
PDF
6万行の TypeScript 移行とその後
PPTX
Hacktoberfest 概要、Node-REDプロジェクト貢献手順
PDF
.NET の過去、現在、そして未来 ~ .NET 最新アップデート
PDF
デモで楽しむ Visual Studio 2022 & .NET 6 最新アップデート
PDF
IBM Cloudant の細かすぎて伝わりにくい機能(その2) データの変更履歴が自動管理できるらしい
PDF
JSUG 2018/02/05 SpringOnePlatform2017参加報告 プラットフォーム関連のお話
PDF
[OracleCodeTokyo2019] Kubernetesで実現する運用自動化の新しいアプローチとは
PDF
Cloud から IoT まで、なんでもおまかせ ~ .NET 5 正式リリース!
PPTX
オートモーティブ領域における 位置情報関連アルゴリズムあれこれ
PDF
Node-REDのノード開発容易化ツール Node generator
PDF
TypeScript製フレームワーク「Nest」のご紹介
PDF
Building simple-app-using-.net 6 asp.net core web api-blazor web assembly-ela...
Docker Desktop WSL2 Backendで捗るWindows PCのコンテナ開発環境
C# における Redis 徹底活用
de:code 2019 DT06 vs-show どっちのVSショー
[AWS DevDay] Cognito / Amplify で加速するエンタープライズのアプリケーション開発
DeNA private cloudのその後 #denatechcon
Angular ユーザーなら押さえておきたい! TypeScript と Visual Studio Code の基礎と活用
MongoDB社の製品紹介 2019-MongoDB EA&Atlas
.NET 6の期待の新機能とアップデート
6万行の TypeScript 移行とその後
Hacktoberfest 概要、Node-REDプロジェクト貢献手順
.NET の過去、現在、そして未来 ~ .NET 最新アップデート
デモで楽しむ Visual Studio 2022 & .NET 6 最新アップデート
IBM Cloudant の細かすぎて伝わりにくい機能(その2) データの変更履歴が自動管理できるらしい
JSUG 2018/02/05 SpringOnePlatform2017参加報告 プラットフォーム関連のお話
[OracleCodeTokyo2019] Kubernetesで実現する運用自動化の新しいアプローチとは
Cloud から IoT まで、なんでもおまかせ ~ .NET 5 正式リリース!
オートモーティブ領域における 位置情報関連アルゴリズムあれこれ
Node-REDのノード開発容易化ツール Node generator
TypeScript製フレームワーク「Nest」のご紹介
Building simple-app-using-.net 6 asp.net core web api-blazor web assembly-ela...
Ad

Viewers also liked (7)

PPTX
【DELPHI / C++BUILDER STARTER チュートリアルシリーズ】 シーズン2 Delphi の部 第7回 「オブジェクト指向 」
PPTX
【DELPHI / C++BUILDER STARTER チュートリアルシリーズ】 シーズン2 Delphi の部 第4回 「Function と Pro...
PPTX
Webセミナー「RAD Studio 10.1 Berlin Update 2 Anniversary Edition 新機能ガイド」
PPTX
【DELPHI / C++BUILDER STARTER チュートリアルシリーズ】 シーズン2 Delphi の部 第2回 ‟変数と型„
PPTX
DELPHI BOOT CAMP / DELPHIでビジュアル開発に挑戦しよう ◆ DAY1: Delphiで作るはじめてのアプリケーション
PPTX
DELPHI BOOT CAMP / DELPHIでビジュアル開発に挑戦しよう ◆ DAY2: DELPHIでUI設計のポイントを学ぼう
PPTX
【DELPHI / C++BUILDER STARTER チュートリアルシリーズ】 シーズン2 Delphi の部 第5回 「配列 と レコード 」
【DELPHI / C++BUILDER STARTER チュートリアルシリーズ】 シーズン2 Delphi の部 第7回 「オブジェクト指向 」
【DELPHI / C++BUILDER STARTER チュートリアルシリーズ】 シーズン2 Delphi の部 第4回 「Function と Pro...
Webセミナー「RAD Studio 10.1 Berlin Update 2 Anniversary Edition 新機能ガイド」
【DELPHI / C++BUILDER STARTER チュートリアルシリーズ】 シーズン2 Delphi の部 第2回 ‟変数と型„
DELPHI BOOT CAMP / DELPHIでビジュアル開発に挑戦しよう ◆ DAY1: Delphiで作るはじめてのアプリケーション
DELPHI BOOT CAMP / DELPHIでビジュアル開発に挑戦しよう ◆ DAY2: DELPHIでUI設計のポイントを学ぼう
【DELPHI / C++BUILDER STARTER チュートリアルシリーズ】 シーズン2 Delphi の部 第5回 「配列 と レコード 」
Ad

Similar to BDEを使った業務アプリを移行ツールで最新化(2017年4月14日開催) (20)

PDF
【16-D-4】3分ではじめるスマホアプリのビジュアル開発
PDF
OpenSpan_PreMarketing
PPTX
dstn交流会_DataSpider のソーシャルとの融合、手組との融合
PDF
New Integration "X" 新インテグレーションソリューション
PDF
「Delphiのマイグレーションを行うのであれば、これだけは知っておこう!」
PDF
「今さら聞けない!? FireDAC入門 ~ オンメモリーデータベース編」
PDF
世界No.1ダウンロードのOSSデータ統合製品 「Talend」の機能と活用事例(配布用)
PDF
【17-E-2】分散されたデータをいかに統合するのか 
PDF
[INSIGHT OUT 2011] C26 ミッションクリティカルを実現する国産データベースHiRDBの技術(hara)
PDF
ドメイン駆動設計 の 実践 Part3 DDD
PDF
Sql server 2012 の新機能を 3 つの視点でご紹介(大阪版)
PPTX
Cloud impact on IT industry (in Japanese)
PDF
Daisukei vsug ef
PDF
Web sphere2002 0624
PDF
Intalio japan special cloud workshop
PDF
DBTS2016 Data as Code - Delphix
PDF
なぜ、現状の基幹業務システムは、ビジネス環境の変化に迅速に対応できないのか? ~超高速開発ツールの導入が必然である理由~
PPTX
Beginning Java EE 6 勉強会(1) #bje_study
PPTX
Mobile Application Development by XPages
PPTX
Javaアプリケーションの モダナイゼーションアプローチ
【16-D-4】3分ではじめるスマホアプリのビジュアル開発
OpenSpan_PreMarketing
dstn交流会_DataSpider のソーシャルとの融合、手組との融合
New Integration "X" 新インテグレーションソリューション
「Delphiのマイグレーションを行うのであれば、これだけは知っておこう!」
「今さら聞けない!? FireDAC入門 ~ オンメモリーデータベース編」
世界No.1ダウンロードのOSSデータ統合製品 「Talend」の機能と活用事例(配布用)
【17-E-2】分散されたデータをいかに統合するのか 
[INSIGHT OUT 2011] C26 ミッションクリティカルを実現する国産データベースHiRDBの技術(hara)
ドメイン駆動設計 の 実践 Part3 DDD
Sql server 2012 の新機能を 3 つの視点でご紹介(大阪版)
Cloud impact on IT industry (in Japanese)
Daisukei vsug ef
Web sphere2002 0624
Intalio japan special cloud workshop
DBTS2016 Data as Code - Delphix
なぜ、現状の基幹業務システムは、ビジネス環境の変化に迅速に対応できないのか? ~超高速開発ツールの導入が必然である理由~
Beginning Java EE 6 勉強会(1) #bje_study
Mobile Application Development by XPages
Javaアプリケーションの モダナイゼーションアプローチ

BDEを使った業務アプリを移行ツールで最新化(2017年4月14日開催)

  • 1. © 2017 Embarcadero Technologies, Inc. All rights reserved. Proprietary and confidential. BDEを使った業務アプリを 移行ツールで最新化 Delphi / C++Builder 業務アプリケーション 刷新実践法 2017年4月14日(金) 14:00~17:00
  • 2. © 2017 Embarcadero Technologies, Inc. All rights reserved. Proprietary and confidential. BDEを使った業務アプリを 移行ツールで最新化
  • 3. 3© 2017 Embarcadero Technologies, Inc. All rights reserved. Proprietary and confidential. #embtwebi_jp 「BDEを使った業務アプリを移行ツールで最新化」アジェンダ セミナー対象:BDEを使用中のコード資産をお持ちの方 時間: 約50分 • BDEと取り巻く環境 • 既存のコードは財産 • 移行ツールと移行手順実践 • 移行後の広がりと最新化
  • 4. 4© 2017 Embarcadero Technologies, Inc. All rights reserved. Proprietary and confidential. #embtwebi_jp BDEとは  Borland Database Engine • Delphi 6以前 にバンドル • 最新バージョンversion 5.2  優れたデータベース・ミドルウエア • dBase やParadox, Microsoft Access などに特殊ドライバなしでアクセス • InterBase, SQL Server, Oracle, DB2などにSQL Linkドライバでアクセス  データベースにビジュアルコンポーネントでアクセス • TTable, TQuery, TStroedProc, TDataBase, TSession, TUpdateSQL…
  • 5. 5© 2017 Embarcadero Technologies, Inc. All rights reserved. Proprietary and confidential. #embtwebi_jp 2017年におけるBDEの現状  Borland Database Engine… • Delphi6以前 (2001年)に付属 :Windows XP 発表年 • 最終バージョンversion 5.2 :2002 年以降アップデートしていない • 製品のライフサイクル :サポートは継続していない • Desktop DBのため、dBASE, Paradoxが主たるターゲット • 対応データベースが最新ではない • マルチデバイス・クロスプラットフォーム開発に対応していない • Unicodeに対応していない • 16bit / 32bitの開発まで  Windows XPが最終サポート対象OS • ユーザーアカウントコントロールの考慮をしていない • Windows XP自体のサポートが終了
  • 6. 6© 2017 Embarcadero Technologies, Inc. All rights reserved. Proprietary and confidential. #embtwebi_jp BDEサポート範囲のままではマイナスの資産?  Windows XPのまま運用 • セキュリティリスク  デスクトップDBで運用 • マルチデバイス運用に対し接続の壁  新データベース接続の壁 • 古いクライアントドライバのみ • Unicodeデータベース採用時の壁  サーバー、ハードウエアの老朽化 • 古いServer OS、相対的なパフォーマンスの低下  開発した資産が重荷へ… • 多数のC/Sプロジェクト、FAアプリケーション
  • 7. 7© 2017 Embarcadero Technologies, Inc. All rights reserved. Proprietary and confidential. #embtwebi_jp 移行で古いプロジェクトをプラスの資産に  既存のコードを生かして最新環境へ • 少ない労力で旧BDEから最新FireDACへ更新可能 • FireDACへ更新で最新環境へ接続が可能に  移行によってプロジェクトをリフレッシュ • 新データベースへの移行 • 新サーバーへの移行 • 新OSの適用
  • 8. 8© 2017 Embarcadero Technologies, Inc. All rights reserved. Proprietary and confidential. #embtwebi_jp 移行においてのポイントとなる点  OSの更新、64bit化が必要 • 32bit → 64bit、User Account Control を考慮に入れつつ改変  サードパーティ ライブラリ、コンポーネントの移行 • 古い帳票ツールの移行:FastReportの利用、QuickReport 最新版の利用 を  使用文字コードをUnicode対応に • Ansi (SJIS → UTF-8,UTF-16) : Charのサイズ、ポインタの取り扱い, File I/Oの際の留意  旧サーバーの更新はデータベースの更新を伴う • デスクトップDB: Paradox から InterBase, Oracle 8 、さらに Oracle11g等最新化  データベース接続ミドルウェアの更新 • BDE → FireDACへ更新、コンポーネントの書換え
  • 9. 9© 2017 Embarcadero Technologies, Inc. All rights reserved. Proprietary and confidential. #embtwebi_jp BDEの移行先として:「FireDAC」  最新データベースミドルウエア・アクセスコンポーネント • BDEのコンポーネントに対応するコンポーネントを実装 • Delphi / C++Builder 10.2 Tokyoで利用可※ • 多数かつ最新のデータベース対応 • VCLのまま使える • 移行ツールあり • マルチデバイス対応 (FireMonkey利用時) ※ローカルデータベースアクセスはPro版以上、リモートデータベースアクセスは Pro版 + FireDAC Add-on Pack以上
  • 10. 10© 2017 Embarcadero Technologies, Inc. All rights reserved. Proprietary and confidential. #embtwebi_jp BDEとFireDACの親和性  親和性の高い対応コンポーネント BDE TDataBase TSession TTable TQuery TStoredProc TUpdateSQL TBatchMove TDatabase TQuery TTable TDataSource TFDConnection TFDQuery TFTable TFDConnection TFDManager TFDTable TFDQuery TFDStoredProc TFDUpdateSQL TFDDataMove TFDPhysXXXXDriveLink TFDGUIxWaitCursor TDBGrid
  • 11. 11© 2017 Embarcadero Technologies, Inc. All rights reserved. Proprietary and confidential. #embtwebi_jp DBMS FireDAC Delphi/C++Builder FireDACの構成 FireMonkey および VCL 非ビジュアルコンポーネント[Comp] ビジュアルコンポーネント/フォーム [GUIx] ローカルストレージ [DatS] データアダプタ [DApt] デバッグ/パフォーマンスモニタ [Moni] ネイティブドライバ [Phys] ブリッジドライバ [Phys] Oracle DB2 MS SQL InterBase Firebird PG SQL My SQL Sybase ASA SQLite MS Access ODBC dbExp DBMSクライアントソフトウエア Oracle DB2 MS SQL InterBase Firebird PG SQL My SQL Sybase ASA SQLite MS Access Sybase ASE Informix … ODBCODBCdbExpress ドライバ ODBCODBCODBC ドライバ FireDACがDBへのアクセスをコンポーネントとして提供
  • 12. 12© 2017 Embarcadero Technologies, Inc. All rights reserved. Proprietary and confidential. #embtwebi_jp  reFind • 無料 • コマンドラインツール  Delphi Parser • GUI付 • 有料 • 変更ルールをカスタマイズ BDE to FireDAC 移行ツール
  • 13. © 2016 Embarcadero Technologies, Inc. All rights reserved. Proprietary and confidential. 13 ReFind: BDEコンポーネントを FireDACコンポーネントに 移行する実践
  • 14. 14© 2017 Embarcadero Technologies, Inc. All rights reserved. Proprietary and confidential. #embtwebi_jp BDEの移行に必要となる主な手順  デモのポイント  ツールで一括変換  BDEプロジェクト→FireDACで動作  エンバカデロで公開しているDocWiki掲載の FireDACへのBDEアプリケーションの移行を もとに紹介 BDE to FireDAC : コンポーネント変換 データベースマッピングの調整 データベース接続設定プロパティの更新 非使用コンポーネントコードの削除・変更 新規コンポーネントの追加 (ドライバ、Wait) 互換性のないプロパティの調整 API・クエリの更新 ※全実施手順参考はブログに掲載 https://community.embarcadero.com/blogs/entry/delphi-c-builder-bde-japan
  • 15. 15© 2017 Embarcadero Technologies, Inc. All rights reserved. Proprietary and confidential. #embtwebi_jp デモ 参考:Delphi 6 での BDE使用画面  参考となる資料:DockWiki「FireDACへのBDEアプリケーションの移行」 http://docwiki.embarcadero.com/RADStudio/Berlin/ja/FireDAC_への_BDE_アプリケーションの移行  デモサンプルコードでは データモジュールに多数の BDEコンポーネントを使用
  • 16. 16© 2017 Embarcadero Technologies, Inc. All rights reserved. Proprietary and confidential. #embtwebi_jp FireDAC データマッピング  参考Dockwiki - データ型マッピング : http://docwiki.embarcadero.com/RADStudio/Berlin/ja/データ型マッピング(FireDAC) プロパティ 説明 PrecMin/PrecMax ソース データ型の数値精度の範囲を定義します。 ScaleMin/ScaleMax ソース データ型の数値スケールの範囲を定義します。 SizeMin/SizeMax ソース データ型の文字列長の範囲を定義します。 SourceDataType ソース(変換元)データ型 TargetDataType ターゲット(変換先)データ型 NameMask 列名マスク TypeMask 列のデータ型マスク  FireDACのデータマッピングを使って、BDE時代のデータ型と互換性を持たせることが可能 • TFDConnectionの接続エディタのオプションで設定
  • 17. 17© 2017 Embarcadero Technologies, Inc. All rights reserved. Proprietary and confidential. #embtwebi_jp FireDAC移行後は  FireDACの機能を生かそう • DML配列機能 • マクロ…  三層への対応 • リモートデータベース化 • 中間サーバーの構築 • ブラウザアクセス化  マルチデバイス開発と対応 • 中間サーバーへのモバイルデバイス接続 • クロスプラットフォーム開発
  • 18. 18© 2017 Embarcadero Technologies, Inc. All rights reserved. Proprietary and confidential. #embtwebi_jp 資産として生かす  過去に作り上げたプロジェクト・プログラム • VCLで構築 • ANSI文字列 • デスクトップDBやクラサバで動作  いま取り掛からなければならない課題 • クライアント側、サーバ側OSのサポート終了、新OSの対応 • DBのバージョンアップ • ハードウエアの老朽化…  将来に実現したいビジネスモデル • モバイルデバイスの利用、マルチOS対応 • クラウドの対応 • IOTを使ったビジネス
  • 19. 19© 2017 Embarcadero Technologies, Inc. All rights reserved. Proprietary and confidential. #embtwebi_jp RDBMS デスクトップ アプリケーション デスクトップDB アプリケーション クライアントサーバー アプリケーション Windowsデスクトップ Windowsデスクトップ Windowsクライアント デスクトップDB
  • 20. 20© 2017 Embarcadero Technologies, Inc. All rights reserved. Proprietary and confidential. #embtwebi_jp RDBMS デスクトップ アプリケーション デスクトップDB アプリケーション Windowsデスクトップ クライアントサーバー アプリケーション macOSデスクトップ Windowsデスクトップ macOSデスクトップ Windowsクライアント macOSクライアント 64-bit Unicode 64-bit Unicode 64-bit Unicode
  • 21. 21© 2017 Embarcadero Technologies, Inc. All rights reserved. Proprietary and confidential. #embtwebi_jp RDBMS クライアントサーバー アプリケーション Windowsクライアント macOSクライアント 64-bit Unicode
  • 22. 22© 2017 Embarcadero Technologies, Inc. All rights reserved. Proprietary and confidential. #embtwebi_jp クライアントサーバーアプリケーション + 中間サーバー InterBase 中間サーバー モバイル クライアント RDBMS RAD Server DataSnap Windowsクライアント macOSクライアント 64-bit Unicode
  • 23. 23© 2017 Embarcadero Technologies, Inc. All rights reserved. Proprietary and confidential. #embtwebi_jp 中間サーバー IoTデバイス モバイル クライアント ビッグデータ デスクトップクライアント HTTP(S) REST JSON HTTP(S) REST JSON HTTP(S) REST JSON クラウドサービス RAD Server 将来的なビジネスモデル例 レガシーシステム 独自のプロトコルで接続 RDBMS Windowsクライアント 典型的なC/Sシステム
  • 24. 24© 2017 Embarcadero Technologies, Inc. All rights reserved. Proprietary and confidential. #embtwebi_jp 「BDEを使った業務アプリを移行ツールで最新化」まとめ セミナー対象:BDEを使用中のコード資産をお持ちの方 時間: 約50分 • BDEと取り巻く環境 • 既存のコードは財産 • 移行ツールと移行手順実践 • 移行後の広がりと最新化
  • 25. 25© 2017 Embarcadero Technologies, Inc. All rights reserved. Proprietary and confidential. #embtwebi_jp FireDAC : 参考となる資料  Embarcadero DockWiki • FireDAC http://docwiki.embarcadero.com/RADStudio/Berlin/ja/FireDAC • FireDAC への BDE アプリケーションの移行 http://docwiki.embarcadero.com/RADStudio/Berlin/ja/FireDAC_への_BDE_アプリケーションの移行 • データ型マッピング(FireDAC) http://docwiki.embarcadero.com/RADStudio/Berlin/ja/データ型マッピング(FireDAC)  28thデベロッパーキャンプにおけるFireDACの紹介 • はじめてのFireDAC : PDF http://edn.embarcadero.com/article/images/43368/a2.pdf • YouTube https://www.youtube.com/watch?v=lDD6z4NuGEo https://www.youtube.com/watch?v=ZcLu6yq3wHE
  • 26. 26© 2017 Embarcadero Technologies, Inc. All rights reserved. Proprietary and confidential. #embtwebi_jp 移行 : 参考となる資料  エンバカデロ Webサイト • RAD Studioマイグレーションセンター http://www.embarcadero.com/jp/rad-in-action/migration-upgrade-center  エンバカデロ ホワイトペーパーダウンロード • RAD Studio / Delphi / C++Builder 旧バージョンからの移行 http://forms.embarcadero.com/rad-migration-papers  エンバカデロ デベロッパーズ ネットワーク • BDE から FireDAC への移行 - Paradox から InterBase の場合 http://edn.embarcadero.com/jp/article/42974  エンバカデロ 日本人ブログ • BDEを使った業務アプリを移行ツールで最新化 https://community.embarcadero.com/blogs/entry/delphi-c-builder-bde-japan
  • 27. 27© 2017 Embarcadero Technologies, Inc. All rights reserved. Proprietary and confidential. #embtwebi_jp 移行ツール: 参考となる資料  reFind • http://docwiki.embarcadero.com/RADStudio/Berlin/ja/Perl_RegEx_式を使 用する検索および置換ユーティリティ:_reFind.exe  Delphi Parser • https://delphiparser.com/ 先日のセミナー内容を 弊社ブログに掲載
  • 28. © 2016 Embarcadero Technologies, Inc. All rights reserved. Proprietary and confidential. 28 THANKS! www.embarcadero.com/jp