What is Tally query language? - tally

What is Tally query language? I searched online but I didn't get anything on TQL. I got something about Tally definition language. Is there any difference between Tally query language and Tally definition language?

Tally query language:-
it's another name is Natural Query Language acts as an interface between the user and a company connected to Tally Software Services (TSS). Natural Query Language uses queries composed of basic, non-technical, English words.
Tally definition language:-
it's including working with different Units of Measures.it's the application development language of Tally and using the application is build than generate a TCP extension file. That file copy-paste in install location of tally erp 9.

Natural Query Language acts as an interface between the user and a company connected to Tally Software Services (TSS). It is a way of communicating in normal words, following the grammar or syntax of a spoken language. Natural Query Language uses queries composed with basic, non-technical, English words.
To retrieve information from a company connected to Tally[.]net, the user types a query on the mobile phone and sends it to a designated number. Tally.ERP 9 converts the query to a format which the database understands and extracts the required information from the company. The user receives a response with information in a simple format.
Example:
1.Working Capital ( Returns Working Capital)
2.Ledger Kotak Bank Address / Closing Balance / Account Name ( Returns Detailed Ledger of Kotak Bank)

It's called Natural Query Language, and has documentation available here.
Natural Query Language acts as an interface between the user and a company connected to Tally Software Services (TSS). It is a way of communicating in normal words, following the grammar or syntax of a spoken language. Natural Query Language uses queries composed with basic, non-technical, English words.
How It Works
To retrieve information from a company connected to Tally.NET, the user types a query on the mobile phone and sends it to a designated number. Tally.ERP 9 converts the query to a format which the database understands and extracts the required information from the company. The user receives a response with information in a simple format.

Related

What are some strategies to implement search functionality to filter out data in an application (Frontend)?

I've built a RESTful API that fetches employees from the database, Now I want to implement search functionality that filters employees by name and then fetches it. In the frontend, I've fetched employees and then based on user input I'm converting both user input and result from db to lowercase and then matching for similarity? Do you think this problem can be approached in a different way? any other strategies? thanks
Yes, let the database do the comparison for you in SQL. Less resources will be used throughout the entire stack. One of the main features for databases is searching for specific data. Also SQL is case insensitive so no need to do a toLowerCase.
SELECT *
FROM Employees
WHERE name LIKE '%SearchValue%'
Only select the columns you need.

RESTful query API design

I want to ask what is the most RESTful way for queries, I have this existing API
/entities/users?skip=0&limit=100&queries={"$find":{"$minus":{"$find":{"username":"markzu"}}}}
Easily the first parts of the query, skip and limit are easily identifiable however I find the "queries" part quite confusing for others. What the query means is to
Find every User minus Find User entities with username 'markzu'
The reason it is defined this way is due to the internal database query behavior.
Meaning in the NoSQL database we use, the resource run two transactional queries, first is to find everything in the User table minus a find User with a username that was specified (similar to SQL) -- boolean operations. So in other words, the query means, "fetch every User except username 'markzu' "
What is the proper way to define this in RESTful way, based on standards?
What is the proper way to define this in RESTful way, based on standards?
REST doesn't care what spelling you use for resource identifiers, so long as your choice is consistent with the production rules defined in RFC 3986.
However, we do have a standard for URI Templates
A URI Template is a compact sequence of characters for describing a range of Uniform Resource Identifiers through variable expansion.
You are already aware of the most familiar form of URI template -- key-value pairs encoded in the query string.
?skip=0&limit=100&username=markzu
That's often a convenient choice, because HTML understands how to process forms into url encoded queries.
It doesn't look like you need any other parameters, you just need to be able this query from others. So a perfectly reasonable choice might be
/every-user-except?skip=0&limit=100&username=markzu
It may help to think "prepared statement", rather than "query".
The underlying details of the implementation really shouldn't enter into the calculation at all. Your REST API is a facade that makes your app look like an HTTP aware key value store.

REST API Design for systems with multiple companies or organizations

Most of the examples I see implement REST URL patterns like http://www.app.com/books/1 to access a book with ID 1 or http://www.app.com/books to access all the books.
That's great, but commonly I work on applications that support multiple companies. For example, Company ABC has 2 users and Company DEF has 2 users. A user from company ABC creates a book with id 100. Now when a RESTful call comes in from a user at company DEF:
http://www.app.com/books/100
there would need to be an Access exception, or
http://www.app.com/books
would only list all books belonging to DEF (not the new book with id 100). For many entities, like Book, the company ID is part of the table, but for other entities that may not be the case. For example, if there was a REST operation for one chapter in a book, http://www.app.com/chapter/333 the chapter table would have a foreign key reference to the book but not the company.
What would best practices be for managing access to this resource? If somebody from DEF tried to access a chapter from ABC I would have to construct a query to join the chapter to the book to verify the company id was valid.
I'm using Grails 3.x where most of this logic is abstracted and thinks happen "automagically". So a URL that comes in for a specific book ID is returned automatically and the request to list all returns every book in the database. It seems that to proceed I would have to override most of this automatic functionality and implement my own security, perhaps in the service layer where the company id would be a required parameter for every operation. Does that sound reasonable?
Is there an established best practice for this sort of thing?
Don't know if it fits your needs but it's interesting to know there is an ACL plugin written by Burt Beckwith :
Spring Security ACL Plugin

REST Webservices - GET but for multiple objects

I have already gone through this
How best to design a REST API with multiple filters?
This does help when you have say 3 or 4 filtering criteria and you can accomodate that in the query String.
However let's take this example
You want to get call details about 20 telephone numbers, between a certain startdate and enddate.
Now I do agree ideally one should be advised to make individual queries for each number and then on the client side collate all data.
However for certain Live systems that would mean 20 rounds of queries on the switches or cdr databases. That is 20 request-response cycles plus the client having to collate and order them again based on time. While in the database level it would have been a simple single query that can return an ordered data and transformed back into a REST xml response that the client can embed on their system.
If we are to use GET the query string will get really confusing and has a limit as well.
Any suggestions to get around this issue.
Of course we can send a POST request with an xml having all numbers in it but that is against REST Get principles.
In case of GET use OData queries. For example when your start and end dates represented as numbers (unix time) URI could look like:
GET http://operatorcalls.com/Calls/Details?$filter=Date le 1342699200 and Date gt 1342526400
What you seem to be missing is an important concept of REST, caching. This can be done, as an example, in the browser, for a single client. Or it can be done as a shared cache between all the clients and the live production system (whatever it may be). Thus reducing queries against a live production system, or in your example, actual switches.
You should really take some time to read Fieldings thesis, and understand that REST is an architectural style.
I found a solution here Handling multiple parameters in a URI (RESTfully) in Java
but not quite happy with it.
So in effect we will end up using /cdr?numbers=number1,number2,number3 ...
However not too pleased with it as there is a limit to Query String in the url and also doesn't really seem to be an elegant solution. Anyone found any solution to this in their own implementation?
Basically not using POST for this kind of Fetch requests and also not using cumbresome and lengthy Query Strings.
We are using Jersey but also open to using CXF or Spring REST

how can I use active Record queries with salesforce as the data-store?

I am connecting to Salesforce.com as a data-store and accessing their REST API's.
Currently, to do a query, have to use SOQL, which is a query language.
How can I use ActiveRecord type 'where' queries instead?
You don't have to use SOQL to retrieve records via the Salesforce.com REST API, if you are retrieving by the Id of the record. To do this, you can just use the following syntax:
/vXX.X/sobjects/SObjectName/id/
To retrieve records that meet a specific clause other than ID, I don't believe there is an alternative to SOQL at this point directly in the REST API.
However, if you are using Ruby, there is a Ruby Toolkit for salesforce that does support using active record style syntax. This is an open source project and you can find out more about it here:
http://quintonwall.com/wp-content/uploads/2011/02/RubyToolkit-gettingstarted.pdf
Here are a couple of examples from the above document:
There are toolkits for other languages, but I am not sure of their support for Active Record style record access.