@@ -2539,30 +2539,30 @@ public java.sql.ResultSet getIndexInfo(String catalog, String schema, String tab
2539
2539
2540
2540
// ** JDBC 2 Extensions **
2541
2541
2542
+ /**
2543
+ * New in 7.1 - we don't support deletes so this must be false!
2544
+ */
2542
2545
public boolean deletesAreDetected (int i ) throws SQLException
2543
2546
{
2544
- throw org . postgresql . Driver . notImplemented () ;
2547
+ return false ;
2545
2548
}
2546
2549
2550
+ /**
2551
+ * New in 7.1 - we don't support deletes so this must be false!
2552
+ */
2547
2553
public boolean othersDeletesAreVisible (int i ) throws SQLException
2548
2554
{
2549
- throw org .postgresql .Driver .notImplemented ();
2550
- }
2551
-
2552
- public Class getClass (String catalog ,
2553
- String schema ,
2554
- String table ,
2555
- String columnNamePattern
2556
- ) throws SQLException
2557
- {
2558
- throw org .postgresql .Driver .notImplemented ();
2555
+ return false ;
2559
2556
}
2560
2557
2561
2558
public java .sql .Connection getConnection () throws SQLException
2562
2559
{
2563
2560
return (java .sql .Connection )connection ;
2564
2561
}
2565
2562
2563
+ /**
2564
+ * Return user defined types in a schema
2565
+ */
2566
2566
public java .sql .ResultSet getUDTs (String catalog ,
2567
2567
String schemaPattern ,
2568
2568
String typeNamePattern ,
@@ -2572,66 +2572,90 @@ public java.sql.ResultSet getUDTs(String catalog,
2572
2572
throw org .postgresql .Driver .notImplemented ();
2573
2573
}
2574
2574
2575
+ /**
2576
+ * New in 7.1 - we don't support visible inserts so this must be false!
2577
+ */
2575
2578
public boolean othersInsertsAreVisible (int type ) throws SQLException
2576
2579
{
2577
- throw org . postgresql . Driver . notImplemented () ;
2580
+ return false ;
2578
2581
}
2579
2582
2583
+ /**
2584
+ * New in 7.1 - we don't support visible updates so this must be false!
2585
+ */
2580
2586
public boolean updatesAreDetected (int type ) throws SQLException
2581
2587
{
2582
- throw org . postgresql . Driver . notImplemented () ;
2588
+ return false ;
2583
2589
}
2584
2590
2591
+ /**
2592
+ * New in 7.1 - we don't support visible updates so this must be false!
2593
+ */
2585
2594
public boolean othersUpdatesAreVisible (int type ) throws SQLException
2586
2595
{
2587
- throw org . postgresql . Driver . notImplemented () ;
2596
+ return false ;
2588
2597
}
2589
2598
2590
2599
public boolean ownUpdatesAreVisible (int type ) throws SQLException
2591
2600
{
2592
- throw org . postgresql . Driver . notImplemented () ;
2601
+ return false ;
2593
2602
}
2594
2603
2595
2604
public boolean ownInsertsAreVisible (int type ) throws SQLException
2596
2605
{
2597
- throw org . postgresql . Driver . notImplemented () ;
2606
+ return false ;
2598
2607
}
2599
2608
2600
2609
public boolean insertsAreDetected (int type ) throws SQLException
2601
2610
{
2602
- throw org . postgresql . Driver . notImplemented () ;
2611
+ return false ;
2603
2612
}
2604
2613
2605
2614
public boolean ownDeletesAreVisible (int type ) throws SQLException
2606
2615
{
2607
- throw org . postgresql . Driver . notImplemented () ;
2616
+ return false ;
2608
2617
}
2609
2618
2610
2619
public boolean rowChangesAreDetected (int type ) throws SQLException
2611
2620
{
2612
- throw org . postgresql . Driver . notImplemented () ;
2621
+ return false ;
2613
2622
}
2614
2623
2615
2624
public boolean rowChangesAreVisible (int type ) throws SQLException
2616
2625
{
2617
- throw org . postgresql . Driver . notImplemented () ;
2626
+ return false ;
2618
2627
}
2619
2628
2629
+ /**
2630
+ * New in 7.1 - If this is for PreparedStatement yes, ResultSet no
2631
+ */
2620
2632
public boolean supportsBatchUpdates () throws SQLException
2621
2633
{
2622
- throw org . postgresql . Driver . notImplemented () ;
2634
+ return true ;
2623
2635
}
2624
2636
2637
+ /**
2638
+ * New in 7.1
2639
+ */
2625
2640
public boolean supportsResultSetConcurrency (int type ,int concurrency ) throws SQLException
2626
2641
{
2627
- throw org .postgresql .Driver .notImplemented ();
2642
+ // These combinations are not supported!
2643
+ if (type ==java .sql .ResultSet .TYPE_SCROLL_SENSITIVE )
2644
+ return false ;
2645
+
2646
+ // We don't yet support Updateable ResultSets
2647
+ if (concurrency ==java .sql .ResultSet .CONCUR_UPDATABLE )
2648
+ return false ;
2649
+
2650
+ // Everything else we do
2651
+ return true ;
2628
2652
}
2629
2653
2630
2654
public boolean supportsResultSetType (int type ) throws SQLException
2631
2655
{
2632
- throw org .postgresql .Driver .notImplemented ();
2656
+ // The only type we don't support
2657
+ return type !=java .sql .ResultSet .TYPE_SCROLL_SENSITIVE ;
2633
2658
}
2634
2659
2635
-
2636
2660
}
2637
2661
0 commit comments