Jan 8, 2011 - Tabel yang rusak akan muncul seperti pada Gambar dibawah: Terlihat. Kemampuan dari spesifikasi Visual Foxpro 6. Walaupun program. Contoh Naskah Drama Singkat Untuk 12 Orang ~ DIGITAL. Pemrograman Microsoft Visual Foxpro 6.0 merupakan bagian dari pemrograman Visual Studio. The National Merit Scholarship Program is a United States academic scholarship.
Arrays are zero-based in Servoy! See the samples.
Servoy code example Empty array var myArray = new Array; Short array declaration for two elements var myArray = 'a', 'b'; Array with a specified number of elements var myArray = new Array(2); myArray0 = 'a'; //normal braces don't work! MyArray1 = 'b'; //elements are zero-based Shorter version of the same array var myArray = new Array('a', 'b'); Two-dimensional array Sorry, no can do (or I didn't find out how) Named array elements var myCustomer = new Array; myCustomer'firstname' = 'John'; myCustomer'lastname' = 'Smith'; Conclusion I can live with these changes. Pitty: no multi-dimensional arrays. Cool: named array elements.
External resources: VisualFoxpro.com © 2010-2012. All rights reserved.
Contact: [email protected].
Memperbaiki header tabel dbf (foxpro) yang rusak. Provides information about setting environment options, accessibility features, and configuration.
Discusses how to get started, including information about installing, upgrading, and customizing Visual FoxPro to create state-of-the-art enterprise database solutions. Lists the new features and enhancements made to this version of Microsoft Visual FoxPro. Provides links to information on Visual FoxPro programming features that are designed to improve developer productivity, including Access and Assign methods, support for more graphic file formats, and language to simplify programming tasks.
Includes conceptual information about how to develop Visual FoxPro applications, instructions for creating databases and the user interface, and other tasks needed to create Visual FoxPro applications. Discusses how to access the full power of Visual FoxPro by creating applications. Understanding object-oriented programming techniques and the event-driven model can maximize your programming productivity. Cara Menggunakan Cain&Abel:. Penggunaan program ini jauh lebih mudah dan simple daripada menggunakan wireshark, tetapi bila anda menginginkan semua packet yang sudah keluar dan masuk disarankan anda menggunakan program wireshark. Buka program Cain anda. Klik pada bagian configure.
Pada bagian “Sniffer” pilih ethernet card yang akan anda gunakan. Pada bagian “HTTP Fields” anda harus menambahkan username fields dan password fields nya apabila yang anda inginkan tidak ada di daftar. Sebagai contoh saya akan beritahukan bahwa kalo anda mau hack password Friendster anda harus menambahkan di username fields dan passworsd fields kata name, untuk yang lain anda bisa mencarinya dengan menekan klik kanan view source dan anda harus mencari variabel input dari login dan password website tersebut. Yang sudah ada di defaultnya rasanyan sudah cukup lengkap, anda dapat mencuri pass yang ada di klubmentari tanpa menambah apapun. DELETE - SQL Command Example The following example opens the customer table in the testdata database. DELETE - SQL is used to mark all records for deletion where the country field contains USA.
All the records marked for deletion are displayed. RECALL ALL is used to unmark all the records marked for deletion. CLOSE DATABASES CLEAR OPEN DATABASE SYS(2004)+'samples data testdata' USE customer && Open Customer table DELETE FROM customer WHERE country = 'USA' && Mark for deletion CLEAR LIST FIELDS company, country FOR DELETED( ) && List marked records.
If the file were packed at this point the records would be deleted WAIT WINDOW 'Records currently marked for deletion'+CHR(13) +; 'Press any key to revert.' . Unmark all records marked for deletion RECALL ALL CLEAR.
Verify reverted records COUNT FOR DELETED( )=.T. TO nDeleted. Convert nDeleted to a character string and display information WAIT WINDOW ALLTRIM(STR(nDeleted)) + ' records marked for deletion.' INSERT - SQL Command Examples The following example opens the employee table and adds one record. USE employee INSERT INTO employee (empno, fname, lname, officeno); VALUES (3022, 'John', 'Smith', 2101) The following example opens the customer table in the testdata database. The contents of the current record are scattered to variables, and the table’s structure is copied to a new table named cust2. INSERT - SQL is used to insert a new record in the cust2 table, and BROWSE is issued to display the new record.
CLOSE DATABASES CLEAR OPEN DATABASE SYS(2004) + 'samples data testdata' USE Customer && Open customer table. Scatter current record to memory variables SCATTER MEMVAR. Copy structure of current table to example table COPY STRUCTURE TO cust2. Insert record from memory variable INSERT INTO cust2 FROM MEMVAR SELECT CUST2 BROWSE. Close and delete example table USE DELETE FILE cust2.dbf. Obstart Digunakan untuk menghidupkan output buffering.
Jika Output Buffering sudah aktif maka tidak ada output yang dikirimkan dari script PHPmu melainkan disimpan dalam internal buffer. Obgetcontents Digunakan untuk mengambil isi dari internal buffer. Fungsi ini tidak menghapus isi dari internal buffer obendclean Digunakan untuk menghapus internal buffer dan mendisable Output Buffering. Contoh: Buatlah satu file PHP bernama buffering.php dengan isi seperti berikut ini: Keterangan: Skrip diatas tidak akan mengeluarkan tulisan “Belajar Ouput Buffering” pada browsermu. Muncul Pertanyaan: tulisan “Belajar Ouput Buffering” tidak tampil pada browser? Jawaban: Karena pada script diatas kita meletakkan kode echo “Belajar Output Buffering” diantara kode obstart dan obendclean, yang berarti bahwa setelah kode obstart; maka output dari kode PHPmu disimpan ke internal buffer, lalu obendclean digunakan untuk menghapus internal buffer sehingga tidak ada output yang akan ditampilkan ke browser.
Muncul Pertanyaan: Lalu bagaimana caranya agar kita dapat mengambil isi dari internal buffer agar kita bisa menampilkannya ke browser? Jawaban: Kita dapat menggunakan fungsi obgetcontents seperti skrip dibawah ini.
TABLEREVERT( ) Function Example The following example demonstrates how you can use TABLEREVERT( ) to discard changes made to a buffered table. MULTILOCKS is set to ON, a requirement for table buffering.
The customer table in the testdata database is opened, and CURSORSETPROP( ) is then used to set the buffering mode to optimistic table buffering (5). The value of the custid field is displayed and then the custid field is modified with REPLACE. The new value of the custid field is displayed. TABLEREVERT( ) is then used to return the table to its original state (TABLEUPDATE( ) could be issued instead to commit the changes). The reverted value of the custid field is then displayed. CLOSE DATABASES SET MULTILOCKS ON && Must be on for table buffering SET PATH TO (HOME( ) + 'samples data ') && Sets path to database OPEN DATABASE testdata && Open testdata database USE Customer && Open customer table = CURSORSETPROP('Buffering', 5, 'customer') && Enable table buffering CLEAR?
'Original custid value: '?? Custid && Displays current custid value REPLACE custid WITH '.' && Changes field contents?
'New custid value: '?? Custid && Displays new custid value = TABLEREVERT(.T.) && Discard all table changes? 'Reverted custid value: '??
Custid && Displays reverted custid value. TABLEUPDATE( ) Function Example The following example demonstrates how you can use TABLEUPDATE( ) to commit changes made to a buffered table. A table named employees is created and INSERT - SQL is used insert the value “Smith” into the cLastName field. MULTILOCKS is set to ON, a requirement for table buffering.
CURSORSETPROP( ) is used to set the buffering mode to optimistic table buffering (5). The original value of the cLastName field (Smith) is displayed and then the cLastName field is modified with REPLACE. The new value of the cLastName field (Jones) is displayed. TABLEUPDATE( ) is then used to commit changes to the table (TABLEREVERT( ) could be issued instead to discard the changes).
The updated value of the cLastName field (Jones) is then displayed. CLOSE DATABASES CREATE TABLE employee (cLastName C(10)) SET MULTILOCKS ON && Must be on for table buffering = CURSORSETPROP('Buffering', 5, 'employee' ) && Enable table buffering INSERT INTO employee (cLastName) VALUES ('Smith') CLEAR? 'Original cLastName value: '??
CLastName && Displays current cLastName value (Smith) REPLACE cLastName WITH 'Jones'? 'New cLastName value: '?? CLastName && Displays new cLastName value (Jones) = TABLEUPDATE(.T.) && Commits changes? 'Updated cLastName value: '??
CLastName && Displays current cLastName value (Jones). Normalisasi adalah teknik untuk mengoptimalkan rancangan database relasional dan membebaskan rancangan tersebut dari keganjilan dan persoalan yang potensial. Normalisasi melibatkan pemecahan data dalam tabel ke dalam tabel yang lebih kecil (decomposition).
(H.S Suryadi D., Bunawan, 1996) Normalisasi terdiri dari beberapa tahap, yaitu: 10 1. Bentuk Normal Tahap Pertama (First Normal Form/1NF), terpenuhi jika sebuah tabel tidak memiliki atribut bernilai banyak (multivalued attribute) atau lebih dari satu atribut dengan nilai yang sama.
Bentuk Normal Tahap Kedua (Second Normal Form/2NF), terpenuhi jika pada sebuah tabel semua atribut yang tidak termasuk pada key primer memiliki Ketergantungan Fungsional (KF) pada key primer secara utuh. Bentuk Tahap Ketiga (Third Normal Form/3NF), terpenuhi jika untuk setiap KF dengan notasi X A, dimana A meakili semua atribut tunggal di dalam tabel yang tidak ada di dalam X, maka: a.
X haruslah super key pada tabel tersebut. Atau A merupakan bagian key primer pada tabel tersebut. Boyce Codd Normal Form (BCNF), terpenuhi jika semua KF dengan notasi X Y, maka X harus merupakan super key pada tabel tersebut, jika tidak demikian maka tabel tersebut harus didekomposisi berdasarkan KF yang ada, sedemikian sehingga X menjadi super key dari tabel-tabel hasil dekomposisi.
1NF ( First normal Form ) 1.Menghilangkan semua pengulangan field 2 Definisikan primary keys. 3 PK nya harus Uniq 4 Setiap field selain PK harus tergantung pada PK 5 Setiap field harus terisi 1 nilai 6 Buat tabel baru untuk memindahkan pengulangan field dari table sebelumnya 2NF ( Second Normal Form ) Definisi: Semua field harus tergantung pada primary key 3rd NF ( third Normal form ) Menghilangkan field yg sama sekali tidak berhubungan dengan PK tapi bergantung pada field lainnya Catatn: Normalisasi akan meningkatkan data integrity tetapi akan juga meningkatkan Query complexity. Sebaliknya Denormalisasi akan mengurangi data integrity dan juga mengurangi Query Compexity Bagi yang pernah coba Crystal Report/Reporting Tool lainya tentu merasakan dampak negatif dari Normalisasi, mengapa? Karena performance untuk reporting yg melibatkan banyak tabel menjadi lebih lambat dibanding Denormalized form. CURSORSETPROP( ) Function Example The following example demonstrates how you can enable optimistic table buffering with CURSORSETPROP( ). MULTILOCKS is set to ON, a requirement for table buffering. The customer table in the testdata database is opened, and CURSORSETPROP( ) is then used to set the buffering mode to optimistic table buffering (5).
A message box is displayed showing the result of the operation. CLOSE DATABASES CLEAR SET MULTILOCKS ON OPEN DATABASE SYS(2004)+'samples data testdata' USE customer && Open customer table. Set buffering mode and store logical result lSuccess=CURSORSETPROP('Buffering', 5, 'customer') IF lSuccess =.T.
=MESSAGEBOX('Operation successful!' ,0,'Operation Status') ELSE =MESSAGEBOX('Operation NOT successful!' ,0,'Operation Status') ENDIF. FLOCK( ) Function Example CLOSE DATABASES OPEN DATABASE (HOME( ) + 'samples data testdata') USE products && Opens products table SET REPROCESS TO 3 SECONDS SELECT. FROM products INTO TABLE newprods IF FLOCK( ).
New product initialization. REPLACE ALL instock WITH 0.00 REPLACE ALL onorder WITH 0.00 WAIT 'Initialization Complete' WINDOW NOWAIT ELSE. File is locked, warn user. WAIT WINDOW 'Unable to open products file; try again later!'
NOWAIT ENDIF BROWSE FIELDS instock, onorder && Displays newprods table USE ERASE newprods.dbf. String comparisons SET NEAR on Specifies that Visual FoxPro positions the record pointer on the closest matching record after an unsuccessful FIND or SEEK command.
This option corresponds to the SET NEAR command. SET EXACT on Specifies that Visual FoxPro uses the full length of both string expressions (except for trailing blanks) when using the comparison operator (=). If you clear this option, Visual FoxPro stops comparing two strings when the end of the expression on the right side of the comparison operator (=) is reached. This option corresponds to the SET EXACT command. Note This setting has no effect on the results of the = operator. SET ANSI on Specifies whether Visual FoxPro pads strings when comparing them with the SQL = operator, which compares character by character until the shorter string is finished.
If you choose this option, Visual FoxPro pads the shorter string with spaces, so a SQL comparison fails (“Tommy” is not equivalent to “Tom ”). If you clear this option, the shorter string is not padded, so strings of unequal length can be equivalent (“Tommy” is equivalent to “Tom”). This option corresponds to the SET ANSI command. Locking and buffering Automatic file locking Specifies that Visual FoxPro automatically locks files for certain commands that do not change data including AVERAGE, COPY TO, INDEX, REPORT, SORT, and TOTAL. If you clear this option, the file is not locked during these commands, and other users can change records while your command is being executed.
This option corresponds to the SET LOCK command. Multiple record locks Specifies whether Visual FoxPro locks multiple records concurrently. If you clear this option, Visual FoxPro clears all current locks and allows you to lock only one record at a time; the current record is unlocked when you lock the next one. This option corresponds to the SET MULTILOCKS command. Buffering Specifies for multi-user environments whether to buffer record changes locally, and if so, whether to do so optimistically or pessimistically.
Buffering can improve performance and provide greater concurrency control. You must choose the Multiple Record Locks option for this option to have effect. It corresponds to the CURSORSETPROP( ) function. Options are: Off Changes are not buffered, and record updates are made immediately to disk. This mode is recommended only when working in a single-user environment. Record (Pessimistic) The current record is locked when the user makes a change to it, and changes are buffered. Other users can read but not change the record on disk.
When the record pointer moves to another record, the current record is written back automatically from the buffer to the source table, and then unlocked. Pessimistic record locking is useful for interactive editing in a table subject to many updates by other users. Record (Optimistic) Changes for a single record are buffered but not locked when the user moves the record pointer to the record.
Other users can read and change the record on disk. When the user moves the record pointer to another record, Visual FoxPro checks changes in the current record against the record on disk. If the record on disk has been changed, Visual FoxPro offers options to discard current changes or overwrite the record on disk. Optimistic record buffering is recommended primarily when updating tables in which there is little activity. Table (Pessimistic) Record changes are buffered and locked when the user moves the record pointer to them, and remain so until TABLEUPDATE( ) is called. Pessimistic table buffering is the safest mode for updating multiple records in a table, but because it locks every changed record, it can limit other users’ access to the data. It is therefore recommended only to help speed data entry when users will be entering new records in batches, or when it is essential for the application that all currently-used records be held exclusively by the application.
Note When using table buffering, you must issue TABLEUPDATE( ) to write buffered record changes to the disk. If you don’t, the changed records are discarded when the user quits Visual FoxPro.
Table (Optimistic) Record changes are buffered, but not locked, when the user moves the record pointer to the record. Other users can read and change the records on disk. When TABLEUPDATE( ) is issued, Visual FoxPro checks for changes in each record as the record is written to disk; records that have changed are not written.
Optimistic table buffering is useful for optimizing update performance in tables in which there is little activity. When using this option, issue TABLEUPDATE( ) often so that the chances of buffered records changing on disk is minimized. Note When using table buffering, you must issue TABLEUPDATE( ) to write buffered record changes to the disk. If you don’t, the changed records are discarded when the user quits Visual FoxPro. Reprocessing Specifies how many times or for how long Visual FoxPro attempts to lock a record or table that is already locked by another user.
This option corresponds to the SET REPROCESS command. Choices are: Attempt Lock (Default).
Attempts to lock one time only. Attempt Lock (Automatic). Continues to attempt the lock until successful or until the user cancels the attempt by pressing ESC. Equivalent to SET REPROCESS TO AUTO.
Wait for Lock. Continues to attempt a lock until the record becomes available. This option does not provide a way for the user to stop trying to lock the record. Equivalent to SET REPROCESS TO -1. Retry Attempts. Attempts to lock the record or table the specified number of times. If the lock is still unsuccessful, an error message is displayed.
SET REPROCESS TO n, where n is the number of retry attempts. Retry Seconds. Attempts to lock the record or table for the specified number of seconds. If the lock is still unsuccessful, an error message is displayed. SET REPROCESS TO n SECONDS, where n is the number of seconds to retry.