number of rows inside a div using jquery

number of rows inside a div using jquery

Hi Guys,

I wanted to find number of rows used inside a div. I used below code but it is not working.

Jquery Code
===========

    $(function() {
    var addDiv = $('#bkup_docs');
    var i = $('#bkup_docs tr').length + 1;
    alert(i); 
    });

HTML
====

    <div id="bkup_docs">
    <tr>
    <td align="right"></td>
    </tr>
    <tr>
    <td>&nbsp;</td>
    </tr>
    </div>

Here I am getting output as 1,actually it should be two.

AM I missing something or I cannot do like this.

Your help is well appreciated.

Thanks in advance.