Hi all I have a page that I’m trying to ADD to a list and save it with viewmodel and SQL. but my list is empty Can you tell me where am I wrong?? on my Xaml (Page1): my Model (Energypage): And on my EnergyViewModel: I did bond my page1 to Energyviewmodel, and it works find when I didn’t use
Tag: sql
Create a new column for a table with select data from another table
I have a SQL table that shows the date and time information of a topic. FirstTable looks like this: id DateP TimeP 1 1397/01/02 01:30 2 1398/05/09 05:30 3 1398/06/07 05:10 4 1398/08/09 06:12 5 1399/02/01 07:15 I want to create columns for another table that are the result of selecting the DateP column and the…
TimescaleDB – how get timestamp differences between rows?
Say you need to know how long something was ‘active’ in a time range – (with timestamp in minutes, as an example) – For a 0-15min bucket, the answer would be 6.8-3.5 + 15-9.3 = 9.0mins. (ie the first active state lasts 6.8-3.5mins, the next one goes from 9.3mins to the 15min barrier). …
TSQL – join two tables with TotalCounter and Pagination
I’m trying to join 2 tables (one to many relation) that include all the columns from first table and only the number of rows from the second one. Use case: one Service has many Reviews. The query looks like: The error is I need to include either average or group by clause but how would that look like I …
how to get start date of latest dept in which working
I’m trying to get the record of emp current working dept with start date Data, in below data Grp column is I’ve derived to get the 3rd last record, which is the correct result. query tried so far Am not able to think ahead, that how can I use Grp now to get 3rd last record as a output. Data
How to use multiple count distinct in the same query with other columns in Druid SQL?
I’m trying to use three projections in same query like below in a Druid environment: But instead I get an error saying – Unknown exception / Cannot build plan for query It seems to work perfectly fine when I put just one count(distinct) in the query. How can this be resolved? Answer As the Druid d…
Get first and last Order and the highest value Item in each order for each Customer, all of which are separate tables
I need to find the first and last Order for each Customer by OrderDate, and the name and SKU of the item with the highest business volume in each of those orders. For reference, the Customer table has >150k records, and Orders and OrderDetails (these are the Items) a lot more. Note: Both Orders and their r…
How to replace a column result if null with another column result in BIRT
I would really appreciate some help with a computed column using an expression in Birt. I have two columns which are giving results, one gives email addresses and one gives contact numbers: telephone, mobile.. When the email result is null then the contact number column shows a number, these are separate comm…
SSMS – get DDL of all views in a schema
I have a SQL Server database with several schemas, each of them contains several views. I need to create the same views in other databases so I would like to get the DDL of all the views in a script, generated through SQL. In Oracle it was quite easy, accessing ALL_VIEWS and referencing the QUERY column. How …
How to aggregate and group by in each column?
I have this table: I’d like to summarize major and minor columns to get this result: Is there any way to achieve this? I tried: But it didn’t count each number. Answer You may achieve this using window functions. major minor major_count minor_count A a 3 2 A b 3 1 B c 2 1 B d 2 1 View