Unanswered: AS/400 Query File With Period(.) In Name
I have a question and finding an answer for it seems to be quite difficult. Maybe I'm not looking in the right place. So I thought I better ask here as you guys have been quite helpful in the past.
I am writing a Java app that runs an SQL query on a DB2 table in our AS/400. This query works excellent so I know my formatting is not wrong and my connection exists. But it only works on a copy of the original table. The reason for this is that the original table's name has a period in it. (ex. Y2K.NAME). I can't change it's name as it's used in a few hundred RPG programs on the 400.
I'm just wondering if anyone knows how to query a table with a period in the name via SQL. I've tried replacing the period with several different characters, putting the name in quotes ("Y2K.NAME"), etc. But each time my program fails to find the file. I'm thinking the answer is simple, I just don't know it. So if anyone knows how to access a file with a period in the name with SQL (via Java), your help would be greatly appreciated.
Hello, thanks for your responses; I appreciate them. Sorry I didn't get back sooner. I found the solution by accident. I was putting double quotes around both the file name and the schema. When I had a basic select run via RAD, it would give me
select * from "qs36f"."y2k.name" <--Which would work for RAD, but not me!
So I removed the quotes from qs36f and forgot to remove them from y2k.name. I ran the simple select again:
select * from qs36f."y2k.name"
Results!! Why it was so picky, I don't know. But it's working now so Woo Hoo!!