Skip to content

Categorize the total amounts

I have a query that gave me a list of store names and its respective amounts. However I would like to sum and categorize the amounts like this: Store Name | $0-$50 | $50 – $100 | $100 – $500 | $500+ Based on the following screenshot: Here is my condition: Here is my basic query for the above snaps…

List count for last 12 months broken down by month

I have a query that can get a total active count of products until a specified date @POINT Output for @POINT “01/01/2021” is From a table like How would I remake this query so that I can have a list of points (last 12 months) like in one query? I don’t want to create a separate table of date…

SQL data types for AnyLogic

I am saving the output of my AnyLogic model into an SQL server database. For non-AnyLogic aficionados, AnyLogic is based on Java. However, I am not sure what data types I need to specify for my columns in the database. So far I am using these: double in AnyLogic : float in SQL string in AnyLogic : varchar in …

SQL – sum column for every date

This seemed like a very easy thing to do but I got stuck. I have a query like this: select op.date, count(p.numberofoutstanding) from people p left join outstandingpunches op on p.fullname = op….