Posts Tagged ‘partition’

I had a HDD taken out of my NAS – it was the “My Book World Edition II (White Light)”. Although the HDD was fine but the NAS was loosing its connectivity capabilities day by day and eventually stopped working one day.

I successfully took the HDD  out by following the instructions in the below link:


Using varieties of free software from within Windows 10 I discovered that it was partitioned with Linux file format (Ext4 and RAW file formats). I have tried more software but I was not being able to see my folders and files but rather some other folders and files that I did not recognise (these were the files and folders used by the NAS).

After much looking further I stumbled upon http://www.reclaime.com/.

I tried the trial software and within a few clicks I could see all my files and folders. I was amazed to able to browse the folders and files that belonged to me. I was also really amazed at how easy it was to use the software.

I went ahead and bought the software. Although it was pricey (£190.93) it exactly did what it said on the tin.


Read Full Post »

/* My explation

Think of partition as the number of groups you want the ranking for.
Therefore it will assign a row number starting from 1 to the columns of which the same values appear in the columns specified in the partition section

So if you just have one column there it will count each and every row
If you have two columns it will start the count of rows from 1 for each time the columns values are different.
In other workds: if you have two columns it will count the ranks for two groups.

Let me explain:
Say you have a table with two fields.
In there you store names of fruits in one column and the colour in another:

Mango orange
Mango green
Mango yello

Melon orange
Melon greeen
Melon yellow

If you just use any one of the column to partintion it will give your the rank from 1 -6 (total number of rows = 6).
If you put both the names of the columnns then you have rank for both the groups from (1-3)

declare @a table
n varchar(50)
, c varchar(50)

SELECT 'Mango', 'Orange'
SELECT 'Mango', 'Green'
SELECT 'Mango', 'Yellow'
SELECT 'Melon', 'Orange'
SELECT 'Melon', 'Green'
SELECT 'Melon', 'Yellow'
order by 1, 2

select *
,row_number() OVER (PARTITION BY n ORDER BY n) NameOccurance
,row_number() OVER (PARTITION BY c ORDER BY c) ColourOccurance
,row_number() OVER (PARTITION BY n, c ORDER BY n) BothOccurance
from @a a
order by 1, 3

-- thik of partition as group
-- in plain english for every mango get the colour ranking ordered by the name mango

Read Full Post »