ox-it / ords

Automatically exported from code.google.com/p/ords
0 stars 0 forks source link

Field names containing spaces are treated differently on App and Staging #769

Closed MerielP closed 8 years ago

MerielP commented 8 years ago

I've just uploaded exactly the same database file to Staging and to App. The database is an Access file I've used many times for testing, and includes spaces and capital letters in some of the field names.

When the database is uploaded to App, it appears that the names are being converted to lower case, and spaces replaced with underscores:

database schema - no spaces or capitals

When exactly the same file is uploaded to Staging, no such changes are made (though as noted in issue #767, the primary keys are missing):

database schema - no primary keys

I am not quite sure why this conversion is happening on App, as we've been telling people since before the ORDS service went live that spaces in field names were fine (and until very recently, spaces didn't seem to be causing any problems). But if this conversion is needed for some reason, then it's problematic for it to have disappeared from Staging.

Can someone clarify what should actually be happening here?

thestoat commented 8 years ago

I believe initially the code had been written to remove spaces and upper casing from the table names since that was causing problems with processing the tables. That code has since been improved so that difference should dissapear once the Staging code hits app... unless you see it different on Dev?

MerielP commented 8 years ago

I've just checked, and Dev and Staging seem to be behaving the same way here.

When you say the code has been improved, do you mean that improvements have been made so we no longer need to removed spaces and upper case letters, and that hence this isn't actually a bug? Or are you saying this is a bug, but one that should disappear of its own accord?

Unfortunately, it does look as though upper case and spaces are still causing problems. I'm wondering if the problem with primary keys not being indicated in the version uploaded to Staging (logged as issue #767) was caused by the fact that the primary key field names include capital letters, and (as noted in issue #772), ORDS doesn't seem able to handle primary keys which aren't all lower case.

thestoat commented 8 years ago

I have just checked dev and staging with the db and I believe things are handled correctly. Here are screen shots showing this ...

image

image

Let me know if this is not what you expect or if you don't see this...

MerielP commented 8 years ago

Those screenshots still show the problems logged as issue #767 - the primary key fields aren't indicated. If my hunch that this is being caused by issue #772 is correct, it may be that this bug will disappear when that one is fixed - but for the moment, it still looks to me as though there's a problem.

thestoat commented 8 years ago

Yes, there is a problem, but that is described in issue 767. The issue that this bug was raised to fix has now been fixed. Why have two issues open about the same problem?

thestoat commented 8 years ago

I'm assigning back to you because the bug this issue reports has been fixed. If there is still a problem with field names containing spaces (or capitals) then please re-raise this issue. If you see a new problem then please raise a new issue. If you are looking at the problem described in issue 767 then please report any matters arising against issue 767

MerielP commented 8 years ago

OK - closing this issue for now.