#10 Database module

Open
opened 4 years ago by maxime-alves · 1 comments

Écrire le module de connection à la base de donnée.

Écrire le module de connection à la base de donnée.
maxime-alves added the
database
label 4 years ago
maxime-alves started working 4 years ago
maxime-alves stopped working 4 years ago
8min 18s
maxime-alves commented 4 years ago
Collaborator

Utiliser les requêtes préparées (prepared statement) en SQLite.


# Larger example that inserts many records at a time
purchases = [('2006-03-28', 'BUY', 'IBM', 1000, 45.00),
             ('2006-04-05', 'BUY', 'MSFT', 1000, 72.00),
             ('2006-04-06', 'SELL', 'IBM', 500, 53.00),
            ]
c.executemany('INSERT INTO stocks VALUES (?,?,?,?,?)', purchases)

Utiliser les requêtes préparées (prepared statement) en SQLite. ``` # Larger example that inserts many records at a time purchases = [('2006-03-28', 'BUY', 'IBM', 1000, 45.00), ('2006-04-05', 'BUY', 'MSFT', 1000, 72.00), ('2006-04-06', 'SELL', 'IBM', 500, 53.00), ] c.executemany('INSERT INTO stocks VALUES (?,?,?,?,?)', purchases) ```
Sign in to join this conversation.
No Milestone
No Assignees
1 Participants
Total Time Spent: 8min 18s
Due Date

No due date set.

Dependencies

This issue currently doesn't have any dependencies.

Loading…
Cancel
Save
There is no content yet.