ElevateDB and RemoteDB (Aurelius)


In ElevateDB I have created a database with one table (Drivers; 2 records).

This table must be acccessible via webbrowser so the XData Server wizard has been used.

However after setting the DefaultEntitySetPermissions the following error comes up.

Code:                    "DatabaseError"
Message:            "Database name 'Customers' already exists"

Does XData Server tries to build the database structure? Could there be an issue with XData ElevateDB driver?

Using a SQLite database gives data from the table.

Also using a similar setup with RemoteDB gives the same error.

Any idea what could cause this?

Correction: subject should be ElevateDB and XData (Aurelius)

Hi Michael,

ElevateDB doesn’t allow two TEDBDatabase components with same name. Here is what you should do:

  1. Set the DatabaseName of the TEDBDatabase component to empty string
  2. In the BeforeConnect event, check if it’s empty and if it is, change it to an unique name. For example:
procedure TDataModule1.EDBDatabase1BeforeConnect(Sender: TObject);
  if TEDBDatabase(Sender).DatabaseName = ‘’ then
    TEDBDatabase(Sender).DatabaseName := IntToStr(NativeInt(TEDBDatabase(Sender)));

Thank you. Problem is solved.