Page 1 of 2

So hard...

Posted: Sat Nov 10, 2012 8:02 pm
by RichardGolko

I'm about to flat out give up on Tiggzi because it's so hard to do anything with the database. The documentation is sparse and when I ask for help through support or this board I get one-line answers with usually a link to some worthless documentation that I don't understand. This product seriously needs more detailed documentation on many things, primarily working with the database and massaging data you get back from it and put into the db.

I'm using the Tiggzi database.
In the database designer I put this in the query box for one f my collections:
{'StationID':'508985aae4b06210489f7e3c'}

It works fine. I get the correct records back.
I designed a REST service -- actually generated it from the Add Service... Database... option and in the supplied WHERE clause put this same query:
{'StationID':'508985aae4b06210489f7e3c'}
and that works when pressing the Test Button.

Since the 508 etc. has to be supplied dynamically, I delete that query from the REST designer and save the REST service...

I then add that service to a screen I did, which displays the records just fine using a grid when I do NOT add anything to the where clause in the mapping for that REST service on that specific screen...all records are displayed...

But when I put that same query {'StationID':'508985aae4b06210489f7e3c'} into the where clause of the where query, and run the test, NO RECORDS ARE RETURNED.

I've double checked the number I put in for the StatoinID, it's exactly correct.

Now I've spent another 5 hours trying to get one simple screen to work... not good.

NEXT, without the query I run all records and it works fine...
But I want to massage the data... so if there is a value in a specific field for one of the records in the grid, I want it to display the data. If not, I want to display the words "closed' since there is no data.

So I search the community area here and found a related discussion and I try some code that 'works' there and it doesn't work at all for me. Here's the code I put in the Javascript popup for the screen control (a label) that I mapped a db field to.

var x = Tiggzi('OpenTimeLabel').text();
alert(x);
if (x == null || x.length==0)
{
Tiggzi('OpenTimeLabel').text("closed");
}

The alert always shows absolutely nothing for each record returned even though there is data there for all but one of the fields (the one I want to display 'closed').
A new alert pops up each record and x is nothing.

Another 2 hours wasted trying to find answers to a simple question and not finding one.

I think it would be good for the community and your sales and client retention rate if you hired somebody to do some thorough documentation on these things.

You should also put a warning in red letters: Unless you know Mango DB and Javascrpt and JQuery, don't attempt to use this software. You will kill yourself in frustration trying to get anything done in a reasonable about of time.


So hard...

Posted: Sun Nov 11, 2012 12:57 am
by Agon Bina

I definitely agree with you. I think there either MUST be a live chat to ask questions or a documentation about EVERY single thing that is on Tiggzi.

If tiggzi plans on becoming a long term solution, you guys have to work on the "customer service" side a little more.


So hard...

Posted: Sun Nov 11, 2012 1:38 am
by Emmz

[quote:]You should also put a warning in red letters: Unless you know Mango DB and Javascrpt and JQuery, don't attempt to use this software. You will kill yourself in frustration trying to get anything done in a reasonable about of time.[/quote]

I couldn't agree more...
Support used to be good for Pro account.
Now Its just fustrating to even ask a question...
Hope they get their new version running soon and can spend more time on Documentation and support.


So hard...

Posted: Sun Nov 11, 2012 2:25 am
by maxkatz

@Richard: if you can share your database structure, I will help you setup the query. Just {'StationID':'508985aae4b06210489f7e3c'} -- is not enough.

We will be launching a new docs site very soon.

Tiggzi makes a lot of things very simple and fast such as building the UI, setting up a REST service, mapping and much more. But, you are absolutely right, Tiggzi does require at least some knowledge of JavaScript, jQuery, jQuery Mobile, etc.


So hard...

Posted: Sun Nov 11, 2012 2:41 am
by Agon Bina

That's great to hear Max. I am also waiting for the new jquery mobile version to be added to the builder so I can use the new popup which seems to function much faster. The current one is really slow and I use pop ups quite a bit in my app.


So hard...

Posted: Sun Nov 11, 2012 5:28 pm
by RichardGolko

Thanks Max,
There are three issues I'm having. I've been in touch about the first one many times already and it is still not resolved. That one is trying to query the Users table for a specific userID. My query returns all records.

The second is the same with a different table so let's look at that and I might be able to fix the first issue too.

My table structure:
Table: BusinessHours
Day (string)
OpenTime (string)
CloseTime (string)
Closed (boolean)
Notes (string)
StationID (string) -- I WANT TO QUERY BY THIS FIELD
DisplayOrder (number)
_createdAt
_updatedAt
ACL

a StationID in the database already is: 508985aae4b06210489f7e3c

I'm using Tiggzi database not parse.

I added a new REST service to the project and selected the 'from database' option (however it was worded)... and selected the BusinessHours table. So it generated my ServiceCenter_BusinessHoursQueryService REST service. I see it has a Where clause. That's what I'm trying to use.

I tried this: {'StationID':'508985aae4b06210489f7e3c'} but it returns nothing.
That's the exact format used in the documentation that I based this on.

I tried that just to test the service because I actually need to use a localStorage variable for the actual StaitonID -- it can't be hard coded.

I tried this for using the variable:
var x = localStorage.getItem("stationID")' (case is correct)
if (x !=null && x.length0)
{
return {'StationID':"'" + x + "'"};
}

which also returned nothing.
My project has already been shared
http://project.tiggzi.com/project/e3d...

______________________________________________________________ ______________________________________________________________

The NEXT problem I have is when the data gets returned, I want
As stated in my above post...

i put the follwoing on the JavaScript button next to my OpenTimeLabel label control in the Mapping for the service I'm trying to add the query to above.

var x = Tiggzi('OpenTimeLabel').text();
alert(x);
if (x == null || x.length==0)
{
Tiggzi('OpenTimeLabel').text("closed");
}

The alert on the 2nd line always shows absolutely nothing for each record returned even though there is data there for all but one of the fields (the one I want to display 'closed').

A new alert pops up each record and x is nothing.

How -- specifically with working code sample if possible -- 'intercept' the data returned so I can 'massage' it before displaying it? Lots of times we need to analyze what we get back and decide how to display it instead of mapping it directly to controls.

Thanks for your help.


So hard...

Posted: Mon Nov 12, 2012 1:05 pm
by Maryna Brodina

Hello! You should use JS on mapping - send request parameter with "where". Inside that parameter should be where={"\StationID\":\""id\""} which should be wrapped in encodeURIComponent()"


So hard...

Posted: Mon Nov 12, 2012 8:13 pm
by RichardGolko

Thanks for your answer.
It doesn't work.

What do I put (exactly) in the Where here...
Image


So hard...

Posted: Mon Nov 12, 2012 8:14 pm
by RichardGolko

You also totally ignored my question on how to massage the data before displaying it.


So hard...

Posted: Tue Nov 13, 2012 12:58 am
by maxkatz

Can you try using double quotes (") for the query:

Image

Let me know if that works.