Notifications
Clear all

[Solved] How to fix "Column Does Not Exist on Table Error" when the column does exist in the database schema

2 Posts
2 Users
0 Reactions
5,486 Views
0
Topic starter

I am currently trying to insert a record into a model and am receiving the error "Column does not exist on table". I have checked the database schema and in this example, the column "TITLE" does exist within the HPEC_BOOK table. Why am I receiving this error even though the column exists?

I have also tried building the module and it has not fixed the issue.

image
1 Answer
0
Topic starter

 This can happen if the DAO object wasn't regenerated after the attribute was added. This means the database was updated to include the column, but the DAO object did not get created.

The solution to solve the issue is to make a change to your model, in this example HPEC.Book, then build the module. Because we have edited the model, when you next build the module, it will generate a new DAO object, which should solve the issue.

Andrew Brits 2025-02-17 19:13:07

@jcourter You need only touch the file itself to update the last modified date on the file - so opening it up in a text editor, adding a space, removing the space and saving (for example) will do the trick.