SlideShare a Scribd company logo
Belajar PHP dengan database Firebird oleh Ali Muntaha
Jikakitatau aplikasi ZahirAccounting,makakitaakantau database yangdigunakanyaitufirebird.
Disini kitaakancoba memplejarari firebirddenganmenggunakanPHP.
Persiapan:
Firebirdbisadi downloaddi wesbsiteresminya http://www.firebirdsql.org/en/server-packagespilih
sesuaikandenganOSanda.
Untuk database managernyakitadapatmenggunakanEMS SQL Manager lite (Free) forfirebirddi
website resminyahttp://www.sqlmanager.net/en/products/ibfb/manager.
Untuk referensifunctiondi phpyangdigunakankitadapatbukawebsite resminyaPHP
http://www.php.net/manual/en/ref.ibase.php
Setelahfirebird,sqlmanagersudahdiinstal kitacobamembuatdatabase denganbantuansqlmanager
klikicon kemudianisikan kolomusername‘SYSDBA’dan kolompassword‘masterkey’
Gambar 1
Mendaftarkan host
Gambar 2
Arahkan path binary firebird
Gambar 3
Mambuat database langkah 1
Gambar 4
Membuat database langkah 2
Gambar 5
Membuat database langkah 3
Gambar 6
Membuat database langkah 4
Gambar 7
Membuat database langkah 5
Gambar 8
Daftar database yang ada di localhost
Gambar 10
Koneksi database yang ada di localhost
Gambar 11
Berhasil Koneksi database
Gambar 12
Membuat tabel langkah 1
Gambar 13
Membuat table langkah 2
Gambar 14
Membuat table lagkah 3
Gambar 15
Membuat table langkah 4
Gambar 16
Membuat table langkah 5
Gambar 17
Membuat table langkah 6
Gambar 18
Membuat table langkah 7
Gambar 19
Membuat table langkah 8
Gambar 20
Membuat table langkah 9
Langkah registerHost,membuatdatabase,membuattable sudahselesaisekarangcobakitaisi
denganmeigisi database tersebutdenganrecorddatadenganklikicon yangberadadi tab data.
Setelahdatadisi klikicon untukmenyimpandata.
Gambar 21
Isi record data
Gambar 22
Isi record yang sudah disimpan
Setelahsemualangkah-langkahdiatasdiselesaikan kitasekarangmembuatscriptPHPuntukkonek
ke database firebirdyangsudahkitabuatdenganlangkah-langkahdiatas.
Buka php.ini cari extensioninterbaseuntukdiaktifkan:
extension=php_interbase.dll
<?php
//scriptkoneksi
$host = 'localhost:D:ALIWEBFILEWEBwwwlatihanfirebirdLAT_FB_DB.GDB';
$username='SYSDBA';
$password='masterkey';
$dbh = ibase_connect($host,$username,$password);
//script untukquerydata
$stmt = 'SELECT * FROMmst_barang';
$sth = ibase_query($dbh,$stmt);
while ($row= ibase_fetch_object($sth)) {
$no=$no+1;
echo $no.'.'.$row->NAMA,"</br>";
}
ibase_free_result($sth);
ibase_close($dbh);
?>
Setelahskripphpdiatasdi tulissimpandengannamalat_con_fb.php kemudianaksesfileyangada
difolderlatihan/lat_con_fb.php(folderdisesuaikansendiri). MakaakanNampakhasil sebagai
berikut:
Gambar 23
Hasil dari latihan script php menggunakan database firebird
Akhirnyaselesai sudahpanduanpenggunaandatabase firebirddenganPHP.Selamatmencobadan
megembangakansendiri.
More Information about article please
contact:
MrAli Muntaha, ST
081333024950
alimuntaha@ymail.com
Lampiran:
Firebird/InterBase Functions
http://www.php.net/manual/en/ref.ibase.php
 ibase_add_user— Add a userto a security database
 ibase_affected_rows — Return the number of rows that were affected by the previous query
 ibase_backup — Initiates a backup task in the service manager and returns immediately
 ibase_blob_add — Add data into a newly created blob
 ibase_blob_cancel— Cancel creating blob
 ibase_blob_close — Close blob
 ibase_blob_create — Create a new blob for adding data
 ibase_blob_echo — Output blob contents to browser
 ibase_blob_get — Get len bytes data from open blob
 ibase_blob_import — Create blob, copy file in it, and close it
 ibase_blob_info — Return blob length and other useful info
 ibase_blob_open — Open blob for retrieving data parts
 ibase_close — Close a connection to an InterBase database
 ibase_commit_ret — Commit a transaction without closing it
 ibase_commit — Commit a transaction
 ibase_connect — Open a connection to a database
 ibase_db_info — Request statistics about a database
 ibase_delete_user— Delete a user from a security database
 ibase_drop_db — Drops a database
 ibase_errcode — Return an error code
 ibase_errmsg — Return error messages
 ibase_execute — Execute a previously prepared query
 ibase_fetch_assoc — Fetch a result row from a query as an associative array
 ibase_fetch_object — Get an object from a InterBase database
 ibase_fetch_row— Fetch a row from an InterBase database
 ibase_field_info — Get information about a field
 ibase_free_event_handler — Cancels a registered event handler
 ibase_free_query — Free memory allocated by a prepared query
 ibase_free_result — Free a result set
 ibase_gen_id — Increments the named generatorand returns its new value
 ibase_maintain_db — Execute a maintenance command on the database server
 ibase_modify_user — Modify a user to a security database
 ibase_name_result — Assigns a name to a result set
 ibase_num_fields — Get the number of fields in a result set
 ibase_num_params — Return the number of parameters in a prepared query
 ibase_param_info — Return information about a parameter in a prepared query
 ibase_pconnect — Open a persistent connection to an InterBase database
 ibase_prepare — Prepare a query for later binding of parameter placeholders and execution
 ibase_query — Execute a query on an InterBase database
 ibase_restore — Initiates a restore taskin the service manager and returns immediately
 ibase_rollback_ret — Roll back a transaction without closing it
 ibase_rollback — Roll back a transaction
 ibase_server_info — Request information about a database server
 ibase_service_attach — Connect to the service manager
 ibase_service_detach — Disconnect from the service manager
 ibase_set_event_handler— Register a callback function to be called when events are posted
 ibase_trans — Begin a transaction
 ibase_wait_event — Wait for an event to be posted by the database

More Related Content

PPT
O Mundo Do Mainframe
PDF
Storage Event: HP 3PAR live erleben
PDF
Kursus ASP.Net
PDF
Structure query language
PDF
Membuka program melalui command prompt do solfa info
PPTX
Pengenalan Dasar NodeJS
PPT
Dos commad. by ammar nawab ppt
PPT
Architecting cloud
O Mundo Do Mainframe
Storage Event: HP 3PAR live erleben
Kursus ASP.Net
Structure query language
Membuka program melalui command prompt do solfa info
Pengenalan Dasar NodeJS
Dos commad. by ammar nawab ppt
Architecting cloud

Similar to Belajar php dengan database firebird (20)

PDF
Best Practices: Migrating a Postgres Production Database to the Cloud
 
PPTX
MySQL database
DOCX
Upgrading mysql version 5.5.30 to 5.6.10
DOC
Pre Install Databases
PPT
8.replication
PDF
Security features In MySQL 8.0
PDF
MySQL database replication
DOC
Pre Install Databases
PPTX
Mobile Application Development (local database) class-07
ODP
MySQL 101 PHPTek 2017
PDF
DBMS LAB FILE1 task 1 , task 2, task3 and many more.pdf
DOC
How to implement “multiple database(db) connection” in rails3
PPTX
Share point rbs in depth englisch
PPTX
SpringBootCompleteBootcamp.pptx
PPTX
Database Change Management as a Service
PDF
Restore MySQL database from mysqlbackup
PDF
MySQL User Group NL - MySQL 8
PPT
Iis it-slideshares.blogspot.com
PPTX
Serverless and Servicefull Applications - Where Microservices complements Ser...
PPTX
PHP FUNCTIONS
Best Practices: Migrating a Postgres Production Database to the Cloud
 
MySQL database
Upgrading mysql version 5.5.30 to 5.6.10
Pre Install Databases
8.replication
Security features In MySQL 8.0
MySQL database replication
Pre Install Databases
Mobile Application Development (local database) class-07
MySQL 101 PHPTek 2017
DBMS LAB FILE1 task 1 , task 2, task3 and many more.pdf
How to implement “multiple database(db) connection” in rails3
Share point rbs in depth englisch
SpringBootCompleteBootcamp.pptx
Database Change Management as a Service
Restore MySQL database from mysqlbackup
MySQL User Group NL - MySQL 8
Iis it-slideshares.blogspot.com
Serverless and Servicefull Applications - Where Microservices complements Ser...
PHP FUNCTIONS
Ad

More from Ali Muntaha (16)

PPTX
PPT_DMS_untuk_trafo_tiang_dan_trafo_gantung_via_LoRa.pptx
PDF
User manual DAS48P series
PPTX
Presentasi Digital Alert System
PDF
Smart home proposal
DOCX
Product knowledge
PDF
Jadikan rumah anda menjadi smart(sementara) sd
PDF
Contoh Lap labarugi 30/11/2016_29/12/2016
PDF
Contoh Lap penjualan periode 30/11/16_sd_29/12/16
PDF
Php dan MySQL 4
PDF
Mengenal script php 3
PDF
Mengenal script html 2
PDF
Apache web server 1
DOCX
Beberapa screenshot dari aplikasi sistem informasi database wilayah polres u...
DOCX
0023 arec 100_2011_proposal_ke_kab_lombok_barat
PPT
Membuat website frontpage
DOC
Pengenalan internet
PPT_DMS_untuk_trafo_tiang_dan_trafo_gantung_via_LoRa.pptx
User manual DAS48P series
Presentasi Digital Alert System
Smart home proposal
Product knowledge
Jadikan rumah anda menjadi smart(sementara) sd
Contoh Lap labarugi 30/11/2016_29/12/2016
Contoh Lap penjualan periode 30/11/16_sd_29/12/16
Php dan MySQL 4
Mengenal script php 3
Mengenal script html 2
Apache web server 1
Beberapa screenshot dari aplikasi sistem informasi database wilayah polres u...
0023 arec 100_2011_proposal_ke_kab_lombok_barat
Membuat website frontpage
Pengenalan internet
Ad

Recently uploaded (20)

PDF
NewMind AI Weekly Chronicles - August'25-Week II
PDF
Getting Started with Data Integration: FME Form 101
PPTX
A Presentation on Artificial Intelligence
PDF
Dropbox Q2 2025 Financial Results & Investor Presentation
PPTX
Tartificialntelligence_presentation.pptx
PDF
MIND Revenue Release Quarter 2 2025 Press Release
PDF
Video forgery: An extensive analysis of inter-and intra-frame manipulation al...
PPTX
Programs and apps: productivity, graphics, security and other tools
PPTX
SOPHOS-XG Firewall Administrator PPT.pptx
PPTX
Machine Learning_overview_presentation.pptx
PDF
Assigned Numbers - 2025 - Bluetooth® Document
PDF
Reach Out and Touch Someone: Haptics and Empathic Computing
PPT
Teaching material agriculture food technology
PDF
Accuracy of neural networks in brain wave diagnosis of schizophrenia
PDF
TokAI - TikTok AI Agent : The First AI Application That Analyzes 10,000+ Vira...
PPTX
KOM of Painting work and Equipment Insulation REV00 update 25-dec.pptx
PDF
Empathic Computing: Creating Shared Understanding
PDF
Advanced methodologies resolving dimensionality complications for autism neur...
PDF
Machine learning based COVID-19 study performance prediction
PPTX
Big Data Technologies - Introduction.pptx
NewMind AI Weekly Chronicles - August'25-Week II
Getting Started with Data Integration: FME Form 101
A Presentation on Artificial Intelligence
Dropbox Q2 2025 Financial Results & Investor Presentation
Tartificialntelligence_presentation.pptx
MIND Revenue Release Quarter 2 2025 Press Release
Video forgery: An extensive analysis of inter-and intra-frame manipulation al...
Programs and apps: productivity, graphics, security and other tools
SOPHOS-XG Firewall Administrator PPT.pptx
Machine Learning_overview_presentation.pptx
Assigned Numbers - 2025 - Bluetooth® Document
Reach Out and Touch Someone: Haptics and Empathic Computing
Teaching material agriculture food technology
Accuracy of neural networks in brain wave diagnosis of schizophrenia
TokAI - TikTok AI Agent : The First AI Application That Analyzes 10,000+ Vira...
KOM of Painting work and Equipment Insulation REV00 update 25-dec.pptx
Empathic Computing: Creating Shared Understanding
Advanced methodologies resolving dimensionality complications for autism neur...
Machine learning based COVID-19 study performance prediction
Big Data Technologies - Introduction.pptx

Belajar php dengan database firebird

  • 1. Belajar PHP dengan database Firebird oleh Ali Muntaha Jikakitatau aplikasi ZahirAccounting,makakitaakantau database yangdigunakanyaitufirebird. Disini kitaakancoba memplejarari firebirddenganmenggunakanPHP. Persiapan: Firebirdbisadi downloaddi wesbsiteresminya http://www.firebirdsql.org/en/server-packagespilih sesuaikandenganOSanda. Untuk database managernyakitadapatmenggunakanEMS SQL Manager lite (Free) forfirebirddi website resminyahttp://www.sqlmanager.net/en/products/ibfb/manager. Untuk referensifunctiondi phpyangdigunakankitadapatbukawebsite resminyaPHP http://www.php.net/manual/en/ref.ibase.php Setelahfirebird,sqlmanagersudahdiinstal kitacobamembuatdatabase denganbantuansqlmanager klikicon kemudianisikan kolomusername‘SYSDBA’dan kolompassword‘masterkey’ Gambar 1 Mendaftarkan host
  • 2. Gambar 2 Arahkan path binary firebird
  • 8. Gambar 8 Daftar database yang ada di localhost
  • 9. Gambar 10 Koneksi database yang ada di localhost Gambar 11 Berhasil Koneksi database
  • 10. Gambar 12 Membuat tabel langkah 1 Gambar 13 Membuat table langkah 2
  • 11. Gambar 14 Membuat table lagkah 3 Gambar 15 Membuat table langkah 4
  • 13. Gambar 17 Membuat table langkah 6 Gambar 18 Membuat table langkah 7
  • 14. Gambar 19 Membuat table langkah 8 Gambar 20 Membuat table langkah 9
  • 15. Langkah registerHost,membuatdatabase,membuattable sudahselesaisekarangcobakitaisi denganmeigisi database tersebutdenganrecorddatadenganklikicon yangberadadi tab data. Setelahdatadisi klikicon untukmenyimpandata. Gambar 21 Isi record data Gambar 22 Isi record yang sudah disimpan
  • 16. Setelahsemualangkah-langkahdiatasdiselesaikan kitasekarangmembuatscriptPHPuntukkonek ke database firebirdyangsudahkitabuatdenganlangkah-langkahdiatas. Buka php.ini cari extensioninterbaseuntukdiaktifkan: extension=php_interbase.dll <?php //scriptkoneksi $host = 'localhost:D:ALIWEBFILEWEBwwwlatihanfirebirdLAT_FB_DB.GDB'; $username='SYSDBA'; $password='masterkey'; $dbh = ibase_connect($host,$username,$password); //script untukquerydata $stmt = 'SELECT * FROMmst_barang'; $sth = ibase_query($dbh,$stmt); while ($row= ibase_fetch_object($sth)) { $no=$no+1; echo $no.'.'.$row->NAMA,"</br>"; } ibase_free_result($sth); ibase_close($dbh); ?> Setelahskripphpdiatasdi tulissimpandengannamalat_con_fb.php kemudianaksesfileyangada difolderlatihan/lat_con_fb.php(folderdisesuaikansendiri). MakaakanNampakhasil sebagai berikut: Gambar 23 Hasil dari latihan script php menggunakan database firebird
  • 17. Akhirnyaselesai sudahpanduanpenggunaandatabase firebirddenganPHP.Selamatmencobadan megembangakansendiri. More Information about article please contact: MrAli Muntaha, ST 081333024950 alimuntaha@ymail.com
  • 18. Lampiran: Firebird/InterBase Functions http://www.php.net/manual/en/ref.ibase.php  ibase_add_user— Add a userto a security database  ibase_affected_rows — Return the number of rows that were affected by the previous query  ibase_backup — Initiates a backup task in the service manager and returns immediately  ibase_blob_add — Add data into a newly created blob  ibase_blob_cancel— Cancel creating blob  ibase_blob_close — Close blob  ibase_blob_create — Create a new blob for adding data  ibase_blob_echo — Output blob contents to browser  ibase_blob_get — Get len bytes data from open blob  ibase_blob_import — Create blob, copy file in it, and close it  ibase_blob_info — Return blob length and other useful info  ibase_blob_open — Open blob for retrieving data parts  ibase_close — Close a connection to an InterBase database  ibase_commit_ret — Commit a transaction without closing it  ibase_commit — Commit a transaction  ibase_connect — Open a connection to a database  ibase_db_info — Request statistics about a database  ibase_delete_user— Delete a user from a security database  ibase_drop_db — Drops a database  ibase_errcode — Return an error code  ibase_errmsg — Return error messages  ibase_execute — Execute a previously prepared query  ibase_fetch_assoc — Fetch a result row from a query as an associative array  ibase_fetch_object — Get an object from a InterBase database  ibase_fetch_row— Fetch a row from an InterBase database  ibase_field_info — Get information about a field  ibase_free_event_handler — Cancels a registered event handler  ibase_free_query — Free memory allocated by a prepared query  ibase_free_result — Free a result set  ibase_gen_id — Increments the named generatorand returns its new value  ibase_maintain_db — Execute a maintenance command on the database server  ibase_modify_user — Modify a user to a security database  ibase_name_result — Assigns a name to a result set  ibase_num_fields — Get the number of fields in a result set  ibase_num_params — Return the number of parameters in a prepared query  ibase_param_info — Return information about a parameter in a prepared query  ibase_pconnect — Open a persistent connection to an InterBase database  ibase_prepare — Prepare a query for later binding of parameter placeholders and execution  ibase_query — Execute a query on an InterBase database  ibase_restore — Initiates a restore taskin the service manager and returns immediately  ibase_rollback_ret — Roll back a transaction without closing it  ibase_rollback — Roll back a transaction  ibase_server_info — Request information about a database server  ibase_service_attach — Connect to the service manager  ibase_service_detach — Disconnect from the service manager  ibase_set_event_handler— Register a callback function to be called when events are posted  ibase_trans — Begin a transaction  ibase_wait_event — Wait for an event to be posted by the database