Support Forum

Ask questions and get help from MobileTogether experts.
MobileTogether Product Information
Welcome Guest! To enable all features please Login or Register.

Notification

Icon
Error

Options
View
Go to last post Go to first unread
dpr  
#1 Posted : Tuesday, January 29, 2019 5:18:07 PM(UTC)
dpr

Rank: Member

Groups: Registered
Joined: 1/25/2019(UTC)
Posts: 20
Ireland

Thanks: 4 times
I am looking to create a database driven inspection / check sheet type application. To that end the UI is some what driven by a template of the checks to perform each inspection based on the particular item being inspected, i.e. item A has a different list of things to check from item B. Added to that, the list of checks to perform for the mobile user could mean the UI needs to be be a boolean check box, numeric value, photo, text etc. etc. Essentially the UI would be defined in one table, and the results of the check / test would be stored in another. Could this type of dynamic UI and results be done in MobileTogether, and is there any example I could follow?
bbv  
#2 Posted : Tuesday, January 29, 2019 6:22:59 PM(UTC)
bbv

Rank: Administration

Groups: Registered, Administrators
Joined: 7/21/2014(UTC)
Posts: 385

Was thanked: 65 time(s) in 65 post(s)
>Could this type of dynamic UI and results be done in MobileTogether

Yes, definitely

I would recommend to look at the App Services offer. You will get some initial implementation for free if you provide a clear definition of your task

https://www.altova.com/mobiletogether/app-services
dpr  
#3 Posted : Tuesday, January 29, 2019 6:50:12 PM(UTC)
dpr

Rank: Member

Groups: Registered
Joined: 1/25/2019(UTC)
Posts: 20
Ireland

Thanks: 4 times
That proposal sounds interesting.

We have been evaluating lots of mobile app based forms applications over the past few weeks, but I have to say, MobileTogether is the only one that is ticking the boxes that lies between a no programming tool and writting an app from scratch in native code. It seems very easy and simple to create a mobile UI for an existing on premise database, whether you are a software developer like use looking to create a mobile app for an existing software package for customers, or a company who's IT department is looking to create a mobile app for some corporate database.

MobileTogether is the Microsoft Access for Mobile App development!
dpr  
#4 Posted : Wednesday, January 30, 2019 4:59:36 PM(UTC)
dpr

Rank: Member

Groups: Registered
Joined: 1/25/2019(UTC)
Posts: 20
Ireland

Thanks: 4 times
Before I put together a submission to App Services, I want to try to get a better understanding of what I can and can't do so that the submission is relevant and not just things that could be solved by some simple questions.

I have followed the video tutorials and I am now creating a simple app with a MS SQL database to enter new records. I can edit existing records fine, however, it is failing to insert new rows as the table contains lots of fields I am not entering data for, and although the database allow nulls for those fields, the app seems to be trying to put empty strings into all the fields I have not specified values for and it then fails when it comes across a fields that are a different data tyle, like a date field. Any ideas or pointers as to what I am doing wrong or should be doing, or should I give you a sample project?
bbv  
#5 Posted : Wednesday, January 30, 2019 5:08:39 PM(UTC)
bbv

Rank: Administration

Groups: Registered, Administrators
Joined: 7/21/2014(UTC)
Posts: 385

Was thanked: 65 time(s) in 65 post(s)
Yes, a NULL in the database corresponds to a missing field. Whereas an existing field with no value inside will generate an attempt to insert empty string.

You have therefore two possibilities:

1. Make sure not to create empty fields at all and/or to delete empty ones before inserting into database

2. Probably more convenient one: in the Save operation click the All Columns button and check the boxes for fields, where empty values will be saved as NULL instead.
https://www.altova.com/m...dactions_pgsrcs_save.htm
thanks 1 user thanked bbv for this useful post.
dpr on 1/30/2019(UTC)
dpr  
#6 Posted : Wednesday, January 30, 2019 5:18:23 PM(UTC)
dpr

Rank: Member

Groups: Registered
Joined: 1/25/2019(UTC)
Posts: 20
Ireland

Thanks: 4 times
Can I create a RowSet that only contains the fields from the database table I want to use, or delete them from the imported schema from the DB source in Page Sources view? At the minute when I select a database table it imports all columns from the table and I can't seems to change or delete what I don't want.
bbv  
#7 Posted : Wednesday, January 30, 2019 5:20:06 PM(UTC)
bbv

Rank: Administration

Groups: Registered, Administrators
Joined: 7/21/2014(UTC)
Posts: 385

Was thanked: 65 time(s) in 65 post(s)
Please see the 2nd bullet which I've just added - it could be much more easier for you to use.

And yes, of course, you can create a RowSet with any amount of fields you want
dpr  
#8 Posted : Wednesday, January 30, 2019 5:45:01 PM(UTC)
dpr

Rank: Member

Groups: Registered
Joined: 1/25/2019(UTC)
Posts: 20
Ireland

Thanks: 4 times
Using the Save operation and only checking the fields I wanted to save worked ok.

How do I create the RowSet in the first place with only fields I want? At the minute when I select a database table it imports all columns from the table and I can't seems to change or delete fields/attributes that I don't want from the schema.

I tried to use a Select statement to specify the columns I wanted, but I get an error in the project:
The table name could not be acquired from the select statement SELECT_For_Case which is needed for auto save.

The table name is "Case"
bbv  
#9 Posted : Wednesday, January 30, 2019 5:58:55 PM(UTC)
bbv

Rank: Administration

Groups: Registered, Administrators
Joined: 7/21/2014(UTC)
Posts: 385

Was thanked: 65 time(s) in 65 post(s)
Yes, your approach was correct - simply write a select statement with the fields you want. I guess you simply have some syntax error. If you believe that you are doing everything correctly, please send your design file for review.

If the table name is indeed CASE, which is a reserved word in SQL, then you need to quote it (for SQL Server this means put into brackets) like this:

SELECT field1, field2 FROM [case]
dpr  
#10 Posted : Wednesday, January 30, 2019 6:04:16 PM(UTC)
dpr

Rank: Member

Groups: Registered
Joined: 1/25/2019(UTC)
Posts: 20
Ireland

Thanks: 4 times
I could create a database view to match the fields I wanted in the UI, but I would prefer not to do that.

Sorry, only seeing your last post there now anout the Select statement. I will try that now
bbv  
#11 Posted : Wednesday, January 30, 2019 6:05:32 PM(UTC)
bbv

Rank: Administration

Groups: Registered, Administrators
Joined: 7/21/2014(UTC)
Posts: 385

Was thanked: 65 time(s) in 65 post(s)
You surely don't need to create views
dpr  
#12 Posted : Wednesday, January 30, 2019 6:24:28 PM(UTC)
dpr

Rank: Member

Groups: Registered
Joined: 1/25/2019(UTC)
Posts: 20
Ireland

Thanks: 4 times
The Select statement is working now and my RowSet only contains the fields I need
dpr  
#13 Posted : Wednesday, January 30, 2019 6:27:53 PM(UTC)
dpr

Rank: Member

Groups: Registered
Joined: 1/25/2019(UTC)
Posts: 20
Ireland

Thanks: 4 times
Small issue with the Primary key field. It is a GUID and requires a value and I have been trying to use the generate-guid() function for either the Ensure Exists on load, or updating the node for the primary key on Page Load. generate-guid() does not seem to generate a GUID
dpr  
#14 Posted : Wednesday, January 30, 2019 7:26:52 PM(UTC)
dpr

Rank: Member

Groups: Registered
Joined: 1/25/2019(UTC)
Posts: 20
Ireland

Thanks: 4 times
Scratch that last comment about the GUID.

I was trying to set it on page load before calling Append node with mt-get-page-source-structure. I needed to update the Guid field after that was called. Working now.
Users browsing this topic
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.