Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.misc -> [q] : Table info using ODBC
Hi all,
I am using ODBC to connect to Oracle 7.3 server running on Solaris. I would like to have answer for two questions.
First the question mentioned in subject : I use SQLTables() to retrieve table information. The procedure looks like this.
retcode = SQLTables( hstmt,
NULL, 0, NULL, 0, tablePattern, strlen(tablePattern), (UCHAR FAR *)"TABLE,VIEW", 10 );
I logged in as user who had DBA rights on the database. It returned me some unknown tables names ( I suppose they are system tables. e.g. COLLECTION, EVENT, FACILITY, ITEM , PROCESS, etc.. )
I am able to get these tables' column information like column size, data type, index information, foreign key info using SQLColAttributes(). But I am not able to view their data, by executing "select * from " + tableName.
Anyhow I am not interested in viewing these table's data. But my program takes a lot of time in getting these unwanted table's information. DO I have to restrict the user rights ? Or did I miss something ?
Second question :
Oracle ODBC Drivers doesn't seem to behave uniformly. For instance I found subtle difference between drivers provided by Oracle, Visigenic and Intersolv. And again Intersolv was the best one.
Oracle ODBC Drivers ( for 7.x.x ) did not allow me to get more than one row at a time. Even when I used SQLExtendedFetch() after setting SQLSetStmtOption( SQL_ROWSET_SIZE,... ), I only got one row.
Oracle 8 ODBC Drivers seem to give some other problem(s). I was not able to get the table info using SQLTables() as documented in ODBC Manual. It said "Driver not capable".
Now .. how do I write a generic program that does not depend on any specific Driver ? My application does not stick to any specific ODBC Driver. I allow user to install any ODBC Driver.
Thanx for any help
shiv
vihs_at_rocketmail.com
-------------------==== Posted via Deja News ====----------------------- http://www.dejanews.com/ Search, Read, Post to UsenetReceived on Wed Jan 21 1998 - 00:00:00 CST