Questions tagged [calculated-columns]

A calculated column is calculated from an expression that can use other columns in the same table

A calculated column is calculated from an expression that can use other columns in the same table. The expression can be a noncomputed column name, constant, function, and any combination of these connected by one or more operators. The expression cannot be a subquery.

2235 questions
0
votes
1 answer

Computed column if statement "Divide"

I have a row which pulls back a Decimal if (row["Time"] and I need an statement which divides the output by 60. Still quite a novice do apologies.
Adam
  • 19
  • 1
  • 8
0
votes
1 answer

SharePoint calculated column text with data from another list?

I have two lists in SharePoint, each with two columns: List A Column 1-----------Column 2 Bob-------------------Apple Joe-------------------Orange Jane------------------Banana List B Column 3-----------Column 4 Column 3 in List B is a lookup from…
0
votes
3 answers

Powerbi Calculate column to return totals for each category only once

I will do my best to explain this correctly: I have a list - by store, by fruit type. I need to create a new column where I have one line of total by store and by fruit (yellow column). In Excel, I can do a formula that does that but I cannot figure…
sara
  • 39
  • 6
0
votes
1 answer

SQL Server Computed Column: how to set it to NOT NULL, without persistence

I am adding a computed column, which should be NOT NULL on an existing table. Both my source column for the computed value are NOT NULL of course. I would like to make the computed column not persistent, to save space, but I fail to do so: ALTER…
Marcel
  • 15,039
  • 20
  • 92
  • 150
0
votes
1 answer

Finding occupancy rate

I am looking at a dataset where I got companies, and what there prices are for several weeks. If the value is blank/empty it is due to the house is booked and therefore there is no price available. I have this code which is working, but I want to do…
0
votes
1 answer

Preserve formatting of ColumnCalculations while downloading pdf from tabulator

Issue: While downloading through tabulator all the column formatting is removed. I am aware of using accessors to reformat the data before downloading. This way I can define formatting for individual columns. However, for column calculations, I am…
0
votes
3 answers

SQL - Calculating third column from previous two

I have just started SQL and have some difficulties in terms of thinking in this language. I have now a task where I need to create a new column in a table with values from previous columns. This calculation is based on few conditions. Is this even…
0
votes
2 answers

Generalize column-range in R code for unknown number of column

I would like to run this code in a generalised way. I have TN type variables in columns from 12 to 25 in my df. I would like to keep all my data and calculate the sum of the valid chr type of values of TN type variables by rows in a new variable…
Malna
  • 59
  • 6
0
votes
1 answer

If it is possible, how do I create a custom field containing a document number on NetSuite in a saved search?

In NetSuite, I am setting up a new (currently untitled) saved search that is meant to display three columns simultaneously: Invoice document number, Sales Order document number and Item Fulfillment document number. I have configured my transaction…
0
votes
1 answer

Building a column2 with column1 based on something like func( condition( rowN,rowN+1),...., condition(rowN,rowN, rowN+7)

I have a data.table like below and i need to build a V2 column with the (ratio number of (V1[Day+1:Day+7] < value1)) _______date________|_V1__|V2_to_build row1:2019-01-01_____|.10...| 2/7 row2:2019-01-02_____|...5...| 0/7 …
Pascal
  • 23
  • 3
0
votes
0 answers

replicate a SQL report in powerbi - create 2 queries and merge them to get result

I am trying to create a report in power BI where I have to create one query which creates 30 calculated columns, then merge it with another query with left outer join to get my results. I am using measures to do my calculations to create the 30…
0
votes
1 answer

How to update a table and ignore a computed column if it is computed but update it if it is not computed

I have different versions of SQL Server databases: in DB 1, column 'IsReadOnly' is a computed column in DB 2, column 'IsReadOnly' is a NON computed column I need to create a standard script which will work on both versions: IF EXISTS (SELECT 1…
user2216540
  • 73
  • 1
  • 10
0
votes
0 answers

How to ensure that information in calculated column can be restored after dropping?

I want to alter a column,A, that has datatype nvarchar(20) to nvarchar(40). But I have another column, B, that is computed with respect to column A. According to my research, at first I need to drop my calculated column B ,then alter column A and…
DDemirci
  • 5
  • 3
0
votes
1 answer

SharePoint 2010 List, Calculated Column, If-statement modification not working

I had a formula in a calculated column that worked just fine. I tried to revised the formula, reusing part of what worked before (in bold), but it keeps taking me to syntax error screen. The new formula is much simpler. I've looked online, but can't…
0
votes
0 answers

FluentNhibernate - boolean flag based on count from another table

I have seen a few questions like this on SO, but I still cannot get this to work in my code, despite my code looking like the accepted answers. First, my mapping (condensed) public SiteMap() { Table("SiteDetail"); Id(x => x.SiteId,…
Josh
  • 16,286
  • 25
  • 113
  • 158
1 2 3
99
100