Volusion API - How to retrieve orders by date - volusion

I am making a call to the volusion api generic order export and I want to be able to only get orders for a single day however the date it is being compared to is a full timestamp stored in the volusion database so you'd have to have the entire timestamp and not just d/mm/yyyy. Seems like it is impossible to pull orders by date via the api. If anyone has experience with the generic orders export with the Volusion api your help would be much appreciated.

You cannot do this directly via the Volusion API as you have already stated.
You can however run a stored SQL query. The method to do this is explained here...
https://stackoverflow.com/a/29134928/357034
You just have to create your specific SQL query which returns the data you require.

For other who might come along later... I had the same error and I believe I solved the problem by switching the user to SuperAdmin rights.

Related

DynamoDB AWS best way to retrieve data in a recurring way

So as the question states, I have a dynamoDB setup from which I am fetching data. My User end is configured in iOS, hence I am using the AWS iOS SDK. Although the documentation is alright, but its outdated a lot, and going through the documentations, many classes are deprecated.
I have 2 questions -
I have to fetch the latest entry from the DB always, so I am doing this by setting the scanforward = false and limit = 1 . Now I am calling query method from the dynamoDBObjectMapper, but there is also load method which also can be configured to do the same. My first question is that what is the difference between query and load if I have to fetch only the latest entry in the DB. Also what is the correct way to retrieve it?
I have to fetch this data in the most instantaneous way possible. I know about DynamoDBStream, but that is NOT an option. Basically I have to implement a long polling kind of feature, where I will get a call? whenever any data is changed OR continuously fetch data from the dynamoDB at a particular interval. Shall i use NSTimer and the same method call (load vs query) to fetch the latest entry in the DB?
Any help is greatly appreciated. Also if any developer working in Amazon can see this question, please remove the old documentation from AWS console and keep the latest ones. There are 5 documentation on the same thing, and all of them are outdated and deprecated.
Thanks for pointing that out. Can you give the links of the documentation that has deprecated classes? We will try to keep the latest ones and remove if there are any redundant deprecated references.
load() API is used to retrieve an item: Using an object's primary key load the corresponding item from the database. Look for an example here: http://docs.aws.amazon.com/mobile/sdkforios/developerguide/dynamodb-object-mapper.html under "Retrieve an item" section.
query() API can be used to return any number of records that match the query. The query API enables you to query a table or a secondary index.
To answer your question, if you know the primary key of the record that you are trying to retrieve, you can use load() API, otherwise use query() API.
DynamoDBStreams work well for your use case. Otherwise you can intgerate AWS Lambda with DynamoDB table to do polling which will be cleaner than a timer based approach. This question is partially answered here: Hooks for AWS DynamoDB streams

Surveymonkey: Get all responses from a single day on a single transaction

Is there a way to get ALL the responses for a single day in one transaction for a specific survey? on the API doc, I know there is the /surveys/{id}/responses/bulk option, and even I can send the start_created_at variable.
But I think that the API response has a max number of records/data it can send, it that case, what could the solution be? Paging through the results?
I'm using the .net API, found at this site, but I can build my own wrapper if necessary.
Reference link to API doc: /Surveys/SURVEY_ID/responses/bulk
Yes you're right the /surveys/{id}/responses/bulk endpoint is what you're looking for, and you can use the start_created_at and end_created_at to filter data to a date range.
The SurveyMonkey API doesn't allow a full dump of all your data, it will always be paginated. By default it'll paginate 50 at a time, but you can change that by using the per_page GET parameter.
That max per_page varies by endpoint, for responses BULK it is 100. So you'll have to fetch 100 at a time, looping through the pages to get all your data.
One alternative is to use webhooks and set up a subscriber, that way you can get new responses in real time and fetch them one by one. That way you can keep your data updated on your side as new responses come in, rather than running a script or endpoint to bulk dump all your data. But this depends on your use case, if you're building something like an export feature, then you'll have to go through the paginated route.

Tracking search query parameters

My rails application revolves around searching for 1 specific record given various filters. I'm trying to figure out what's the best way to keep track of search queries so in the future we can either do reporting or a dashboard. Basically I need insight into what users are looking for.
This is what a search query would look like:
http://localhost:3000/s?utf8=%E2%9C%93&location=New+York%2C+NY%2C+United+States&activity=Figure+Skating&start_time=Nov+13th+2015&end_time=Dec+25th+2015&period=morning&geolocation=%5B40.7127837%2C-74.00594130000002%5D
cleaner:
http://localhost:3000/s?utf8=%E2%9C%93&location=&activity=&start_time=&end_time=&geolocation=
You can add a hook in your search controller method that stores the params used in every search. Perhaps you can create a new model called Analytics, where every time someone searches for something the Analytics stores all the values of the search... that way you can have all the information stored in your db and you can analyze it.
The easiest way would be to track this via the Google Analytics:
https://support.google.com/analytics/answer/1012264?hl=en

When using databasedotcom ruby gem to access salesforce, how do I get the ActivityHistory for a particular User (or Account)

For most sobjects, they support queries such as find_by_... etc. However,
client.materialize("ActivityHistory")
returns a class that does not support query.
When I try to run ActivityHistory.query("anything")
I get...
Databasedotcom::SalesForceError: entity type ActivityHistory does not support query
I'm trying to extract the ActivityHistory for the last 30 days, and find out the account it lies in, and the user that created it.
Help, please!
I know this is late, putting it here for future reference.
Unfortunately the ActivtyHistory table is not directly accessible, it has to be queried through a relationship e.g. Account. For more info.. https://salesforce.stackexchange.com/questions/8327/accessing-email-sent-in-activity-history-via-api

Timesheet reporting in FogBugz?

Currently it's a big PITA to create timesheet report for say a week or month in FogBugz... maybe someone knows about a plugin to that for you?
This question is kind of old so I am assuming you were using FB6, but if you are now using FB7 to do exactly this: ClarkKent.
If you have FogBugz hosted on your own server, you can query the database manually and get timesheet results that way. If its hosted by FogBugz, then you can download the database, do the same query, or, use the API to get all the time entries. Some programs already exists for that, one of them is TimeSprite, but its not free.

Resources