Commit ef3d2f5
committed
Pdo\Pgsql: optimize calls to foreach(columns of the same table) getColumnMeta()
- each call queried the DB to know the name associated with the table's OID:
cache the result between two calls
- make pdo_pgsql_translate_oid_to_table higher-level,
with the last parameter being the handle instead of the raw connection;
thus the statement is cleaner, letting the handle do all memory handling on the table oid-to-name translation cache
(which by the way is a driver feature more than a statement one)1 parent 55e8ebe commit ef3d2f5
File tree
3 files changed
+23
-4
lines changed- ext/pdo_pgsql
3 files changed
+23
-4
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
252 | 252 | | |
253 | 253 | | |
254 | 254 | | |
| 255 | + | |
| 256 | + | |
| 257 | + | |
| 258 | + | |
255 | 259 | | |
256 | 260 | | |
257 | 261 | | |
| |||
1445 | 1449 | | |
1446 | 1450 | | |
1447 | 1451 | | |
| 1452 | + | |
1448 | 1453 | | |
1449 | 1454 | | |
1450 | 1455 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
702 | 702 | | |
703 | 703 | | |
704 | 704 | | |
705 | | - | |
| 705 | + | |
706 | 706 | | |
| 707 | + | |
707 | 708 | | |
708 | 709 | | |
709 | 710 | | |
710 | 711 | | |
| 712 | + | |
| 713 | + | |
| 714 | + | |
| 715 | + | |
| 716 | + | |
| 717 | + | |
| 718 | + | |
| 719 | + | |
| 720 | + | |
| 721 | + | |
711 | 722 | | |
712 | 723 | | |
713 | 724 | | |
| |||
724 | 735 | | |
725 | 736 | | |
726 | 737 | | |
| 738 | + | |
| 739 | + | |
727 | 740 | | |
728 | 741 | | |
729 | 742 | | |
| |||
752 | 765 | | |
753 | 766 | | |
754 | 767 | | |
755 | | - | |
| 768 | + | |
756 | 769 | | |
757 | | - | |
758 | | - | |
| 770 | + | |
759 | 771 | | |
760 | 772 | | |
761 | 773 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
43 | 43 | | |
44 | 44 | | |
45 | 45 | | |
| 46 | + | |
| 47 | + | |
46 | 48 | | |
47 | 49 | | |
48 | 50 | | |
| |||
0 commit comments