Update database after creating entitys - spring

I'm having a problem. Every time I update the JDL file by adding some entity or relationship, the database is not updated. And I think this is what causes that when I go to make a GET request, I get an "Internal Server Error". What I want is that every time I import the JDL file and run the gradlew command, the database is updated. How can I do it?

Related

GraphQL Elixir/Phoenix API: Socket hang up with large json response

New to Elixir/Phoenix and GraphQL. I have created a simple API that retrieves "drawings" from a PostgreSQL database. The table consists of an "id" (uuid) and "drawing_json" (text). In the table is one row with a json string of about 77Kb. My schema and queries are defined using Absinthe. I have 1 query called "all_drawings" which resolves and reaches out to the Repo and pulls in all drawings. When using postman to call this API, the following query works fine:
{
allDrawings
{
id
}
}
However, when I try to return the json field as well the postman request times out and I get a "socket hang up" error.
Looking at the Debug Console in Visual Studio Code, I can see the query gets the data from the db just fine and almost immediately. Something seems to be happening though in returning it to the client that I can't detect. No errors are thrown. Any ideas? Not sure what information will help but happy to provide more.
A colleague helped me find the fix. Not sure why this is (maybe someone can elaborate), but the issue was with trying to run it in Visual Studio Code. Previously, I set up the run task in launch.json and would click the run button to start debugging my application. This would cause the aforementioned crash every time. When I went to the terminal and ran the "mix phx.server" command, everything worked fine. Not sure if the hang up is with Visual Studio Code or the ElixirLS extension when using the IDE to debug. But starting the application through the command line allowed me to use postman to hit the api and retrieve the data just fine. I'm very new to the Elixir/Phoenix world so I'm unable to draw a more intelligent conclusion as to why this happens.

Validation Failed exception Liquibase

I am newbie in using liquibase for database management. I am getting the following error while doing mvn install. I am not able to know where exactly i went wrong. Could someone please help me with the solution
Caused by: liquibase.exception.ValidationFailedException: Validation Failed:
1 changes have validation failures
'sql' is required, db/changelog/changes/v0001.sql::raw::includeAll
db.changelog-master.yaml
databaseChangeLog:
- includeAll:
path: db/changelog/changes/
liquibase folder structure
In liquibase whenever a migration is run it creates a hash value for each of the change log written in migration file. When the application is run for the first time entry is created for each change log with its hash values in the DatabaseChangelog Table.If a change is made to the existing change log which has been run once the hash value changes and a validation error is generated.
To fix this issue
you can revert the changes made to the change log after it was run for
the first time and create a new change log to accommodate the change
OR
delete the entries in the DatabaseChangeLog table for the particular
change log giving error along with the change associated with the
change log and rerun your migration.
I forgot to add query altogether. Just added the changeset!
The error you mentioned appears if you define changeset with empty SQL tag like this:
<changeSet id="test_users" author="test" dbms="h2">
<sql>
</sql>
</changeSet>
To fix it just remove this incomplete changeset or finish it by adding some SQL script you originally intended.

Laravel migration on correct DB, but data retrieve on wrong DB

I just recently put a project of mine into bitbucket as my start project. Now I cloned this project into another folder. I did the composer install command.
I created a new database for this new project and changed the variables in .env to match the new DB. When I do a 'php artisan migrate' all the tables get built in my new DB, however when I retrieve data, for example posts, it gets the posts from the other DB (used with my other project). I also checked if in the database file it was not set manually to the old DB. So I have no clue what causes this behavior.
Can anyone explain what may be the cause of this?
Thanks

Synonym returning ORA-00904 error

I'm at my wits' end with this error.
I have a view which uses a function contained in a package in another schema. I've created a synonym to said package, and on my local dev DB, the view compiles correctly. On the build server, the view gives compilation errors.
When I run the select of the view manually, Oracle throws an ORA-00904 error on the synonym in the query. I just can't understand why it works in one place and not the other. The code on both servers is identical, as it's coming from our source control repository.
As phlogratos suggested, it was a privileges issue. As the user didn't have execute permissions on the package in the separate schema, it was causing this error.
The underlying problem was an issue with our script that applies grants, but it's good to know that references like this without permissions fail in this manner.

CRM data import error 0x80040265

I try to upload new Account with the data import wizard via a csv file, the only column is the Account Name. I always received the error code 0x80040265 with no log on the server. I do the same thing for Contact with more columns and it works without errors.
Someone have this problem?
After searching a lot, a plugin crashed for each account record into the csv file, it's not normal that there are no log...

Resources