Categories:
.NET (357)
C (330)
C++ (183)
CSS (84)
DBA (2)
General (7)
HTML (4)
Java (574)
JavaScript (106)
JSP (66)
Oracle (114)
Perl (46)
Perl (1)
PHP (1)
PL/SQL (1)
RSS (51)
Software QA (13)
SQL Server (1)
Windows (1)
XHTML (173)
Other Resources:
How To Create a Table for Transaction Testing
How To Create a Table for Transaction Testing? - MySQL FAQs - Transaction Management: Commit or Rollback
✍: FYIcenter.com
If you want to learn transaction management, you should create a table with the InnoDB storage engine. The default storage engine MyISAM does not support the transaction concept. The tutorial exercise below shows you a good example of creating a new table with the InnoDB storage engine:
>\mysql\bin\mysql -u dev -piyf fyi mysql> DROP TABLE fyi_links; mysql> CREATE TABLE fyi_links (id INTEGER PRIMARY KEY, url VARCHAR(16) NOT NULL, notes VARCHAR(16), counts INTEGER, created TIMESTAMP DEFAULT CURRENT_TIMESTAMP()) ENGINE = InnoDB; Query OK, 0 rows affected (0.25 sec) mysql> SHOW CREATE TABLE fyi_links; CREATE TABLE `fyi_links` ( `id` int(11) NOT NULL, `url` varchar(16) NOT NULL, `notes` varchar(16) default NULL, `counts` int(11) default NULL, `created` timestamp NOT NULL default CURRENT_TIMESTAMP, PRIMARY KEY (`id`) ) ENGINE=InnoDB DEFAULT CHARSET=latin1 1 row in set (0.05 sec)
You should keep this table for to practice other tutorial exercises presented in this collection.
2007-05-11, 5366👍, 0💬
Popular Posts:
Can you tell me how to check whether a linked list is circular? Create two pointers, and set both to...
What will be printed as the result of the operation below: main() { int x=10, y=15; x = x++; y = ++y...
What's the output of the following program? And why? #include main() { typedef union { int a; char b...
What's wrong with this initialization? char *p = malloc(10); My compiler is complaining about an ``i...
How will you freeze the requirement in this case? What will be your requirement satisfaction criteri...