If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > Database Server Software > DB2 > ODBC connection with MS Access

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 11-22-05, 01:52
Mehico12 Mehico12 is offline
Registered User
 
Join Date: Nov 2005
Posts: 1
ODBC connection with MS Access

Hi everyone,

I am trying to export an MS Access table into DB2. I am not sure if I have done it right. I have selected ODBC as export option in Access and finally I am able to see my exported table (Exporttable) when issuing the command
>> db2 list tables
in DB2. (Same schema [MYUSERNAME] and type as the other tables, yet it is a bit strange that the table is not shown in uppercase letters 'EXPORTTABLE' as all the other tables but as 'Exporttable'' instead)
I am not able to access this table from db2 at all. Executing a command like:

>> db2 select * from Exporttable

I get the following error message

>> SQL0204N "MYUSERNAME.TARGET" is an undefined name. SQLSTATE=42704

Thanks for any help...
Reply With Quote
  #2 (permalink)  
Old 11-22-05, 03:48
przytula przytula is offline
Registered User
 
Join Date: Nov 2004
Posts: 374
mix case

as tablename is in mix case, the name has to be protected from translation
select * from "tablename"
same applies to column names
__________________
Best Regards, Guy Przytula
DB2/ORA/SQL Services
DB2 DBA & Advanced DBA Certified
DB2 Dprop Certified
http://users.skynet.be/przytula/dbss.html
Reply With Quote
  #3 (permalink)  
Old 11-22-05, 09:02
Cougar8000 Cougar8000 is offline
Registered User
 
Join Date: Nov 2005
Location: IL
Posts: 554
Quote:
Originally Posted by Mehico12
>> db2 select * from Exporttable

I get the following error message

>> SQL0204N "MYUSERNAME.TARGET" is an undefined name. SQLSTATE=42704

Thanks for any help...
Table name consist of two parts. Schema + tabname. reffer to it as such to avoid this in the future. It is a good practice to do so for many reasons. Runs this command to see what schema was this table created in and then post here. db2 list tables for all | grep -i tabname tabname is your table name.
__________________
--
IBM Certified DBA on DB2 for Linux, UNIX, and Windows

DB2 v9.1.0.2 os 5.3.0.0

Last edited by Cougar8000; 11-22-05 at 09:04.
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On