I have an app that includes a datasource created from an existing Cloud SQL table. A column has since been added to the Cloud SQL table (outside of App Maker).
How do I get the App Maker datasource to reflect the new table schema?
You need to go to Settings -> Database and click Check button:
App Maker will show you a dialog with multiple choices. You can opt to import changes from database:
In other words, App Maker supports both Database First and kinda Code First development approaches.
Related
I can't delete this table using the interface of NoSQL Workbench after clicking Delete button nothing happened.
ScreenShot
I click on delete but nothing happened I was expecting the table will be deleted
Not sure if this is a table used only for modelling or one that you have created as an actual table. If it's an actual table, ensure you have DeleteTable permissions for the role being used in workbench.
If this is just a modelling table locally, send feedback to the NoSQL Workbench team via the button on the main dashboard.
My preview works and has data but my deployment has no data. I'm using the (Recommended) DEFAULT CLOUD SQL database configuration.
Note: This is only day 4 with Google App Maker. Finding answers to App Maker-specific questions has been super difficult, but I'm making rapid progress on my application, so overall tired but good. :{)
As written in the documentation,
App Maker deployments can use the same Cloud SQL instance, but have separate databases on that instance. Data that you had in preview mode is not available in other deployments. You have a few options for how to handle this situation:
To use data from the preview instance in your published deployment, export the deployment data from the preview instance and import it to the published deployment.
To share a database across all deployments (preview and published), use a custom Cloud SQL database.
When you deploy your app, AppMaker create a new database in your google cloud SQL instance for the deployment. All the data create in previews is in another database.
To use the same database as the preview mode you have to go in the settings of your app in the tab "DATABASE" and copy the Database Key. Then go to your cloud sql instance in google cloud platforme and on the details of the instance in the overview tab just copy the instance connexion name.
then edit your deployments and select "Use Custom Cloud SQL database" and copy with the format
"instanceConnexionName/DatabaseKey" then save and appmaker should ask you to enter you username and password of your google cloud sql insatnce.
On app settings, database page you should see
Databas key: iTIJQaCj491a4111
(Actually this is the name of the mySQL instance)
In GCP console, go to SQL, click on Instance ID, and on the Instance ID overview page is the instance connection name, e.g., MyProject-123456:us-central1:instancename
Back in app settings
Select Switch to custom database and enter the full connection string
projectname:instancename/schema as
MyProject-123456:us-central1:instancename/iTIJQaCj491a4111
Provide username and password
and follow the steps to confirm existing database
Turns out the issue is when you publish it doesn't push the data, you have to manually re-upload the data into the live version. This is actually a good thing, but I wish it'd been explicitly documented. I found it, after figuring it out on my own, in some early release notes from a few years back. I guess I wasn't the only one this stupid.
what changed in appmaker?
Some time ago i could do:
Select a table from the list on the next page and click Import to
create your model. You can import any table that's not a join table.
based on information: https://developers.google.com/appmaker/models/cloudsql#connect_your_app_to_an_existing_custom_google_cloud_sql_database - on Connect your app to an existing custom Google Cloud SQL database
Now this option is not available, only is available:
Create a new table is a SQL database managed by App Maker.
This is not the option i want, i have already all my tables in DB.
The only option i see here is use Calculated SQL or delete all tables from DB and create from the app.
There is any workaround for this and do what i have done until now: using the import option?
Regards
https://developers.google.com/appmaker/release-notes
"With today's release, you no longer can create new Drive Table data models. Your apps can continue to use existing Drive Tables. However, we recommend you upgrade those models to Cloud SQL as soon as possible."
I have deployed the 1st version of my wp8 in wp store and now i want to deploy the update version of it. Though I know the process of update deployment, but my concern is the sqlite file which doesn't get updated.
Here is the scenario, I have sqlite file in the app where user can store config and setting, in new version I added extra tables and I want to these tables should be reflected in the the update without affecting user settings and config.
What points I should consider to take care of this issue?
Thanks!
Assuming the data in the sqlite database is static you can give the database a new name and submit it with the updated app. One first run copy the new database to isolated storage and delete the old version of the database to save space.
If the user is inputting data into the database you will have to include code to modify the database structure on the first run and insert any records into the new table
I am making a contact book application in Qt.
I want my application to automatically create an QSQLITE database when it first runs and then access this database in future?
Is there a way to do this?
Ya you can create sqlite database at its first run and can make it progressive. Just do it in the constructor of your App and check for the existence of db before cerating it, else don't create. You can access database in subsequent runs of your same App or different App.
Use db.setDatabaseName("databasename.db"); instead of db.setDatabaseName(":memory:");, now your database will be persistent.