I think I figured it out:
select count(u.scode)
from unit u,
(select * from tenant where status in ('Past', 'Future')) t
where u.hmy = t.hunit (+) and nvl(u.exclude, 0) = 0
I have unit and tenant tables. One unit can have 0 or 1 tenant. I have to extract all units with either no tenants or with tenants of particular status codes like 'Past' and 'Future'. I cannot apply OR operator on tenant.status as tenant is optional table for join.
Following query doesn't...
Thank you guys - I greatly appreciate your feedback!
I tried to change my approach and used the array formula - still no luck
Dim charges As Range
Set charges = Range(Cells(chargeMin, transColumn), Cells(chargeMax, transColumn))
Range("J1").Select 'selecting cell R1C10
Selection.FormulaArray =...
Following code counts something now. I realised count() is only for number or date values so I am using countA() now. But now the count is one extra. I think it has something to do with the column/list header.
Range(Cells(rowMin, col), _
Cells(rowMax, col)).Select...
Thanks PH for the quick reponse. I tried this function. It seems to count the number of rows within each group. And then it adds all rows in the end. My requirement is to count number of groups. For example:
count(1,1,2,2,3,3,2) should give 3.
right now subtotal gives something like this...
I am using following code to get a distinct count of column values:
Range(Cells(rowMin, col), _
Cells(rowMax, col)).Select
ActiveWorkbook.Names.Add Name:="myName", RefersTo:="='" _
& ActiveSheet.Name & "'!" & Selection.Address
Selection.AdvancedFilter Action:=xlFilterCopy...
2. When all logs will be written for the first time - the above mentioned loop will work. But what about finding next log candidate when all logs are created and they are full. Program wants to write more. It will loop back and make another cycle starting with the first log. In this case all log...
Any generic text viewer should be able to open these log files. At least Notepad I would say.
I had no idea that text viewer will put a limit on the file size.
I am creating a log system where I will have say 5 log files named like <whatever>.1.log, <whatever>.2.log, ..., <whatever>.5.log
I will start writing into first log and subsequent info gets appended into the log file till it is full to the capacity. Then I will open up second log and so on...
Yes thats one solution. But I want to avoid the loop. Like how it happens in formula - where we can specify the cell range. The only problem is my cell range is determined at run time and I cannot harcode something like sum(A2:A8). Whatever I have is in variables.
I need to add a number of cells. They all are in the same column. I have row numbers and column number values stored in integer variables. I want to store their sum in a new variable, say total. Following does not work - please advise how should I do it
total = SUM(cells(rowStart, col)...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.