[Tex/LaTex] Question mark instead of number for reference

bibtex

I an new to Latex, and I am trying to use 'bibtex' to create a reference, I was working in pdfLaTeX+MakeIndex+BibTex.

Here is my sample code:

\documentclass[12pt]{article}

\usepackage{cite}

\begin {document}
$$ x_i$$

\section{Introduction}

According to \cite{2006} 

\bibliographystyle{IEEEtran}

\bibliography{my_bibtex}

\end{document}

Edit:

Here is the .bib file that I am using.

@article{2006,
     jstor_articletype = {research-article},
     title = {The Cross-Section of Volatility and Expected Returns},
     author = {Ang, Andrew and Hodrick, Robert J. and Xing, Yuhang and Zhang, Xiaoyan},
     journal = {The Journal of Finance},
     jstor_issuetitle = {},
     volume = {61},
     number = {1},
     jstor_formatteddate = {Feb., 2006},
     pages = {pp. 259-299},
     url = {http://www.jstor.org/stable/3699341},
     ISSN = {00221082},
     abstract = {We examine the pricing of aggregate volatility risk in the cross-section of stock returns. Consistent with theory, we find that stocks with high sensitivities to innovations in aggregate volatility have low average returns. Stocks with high idiosyncratic volatility relative to the Fama and French (1993, Journal of Financial Economics 25, 2349) model have abysmally low average returns. This phenomenon cannot be explained by exposure to aggregate volatility risk. Size, book-to-market, momentum, and liquidity effects cannot account for either the low average returns earned by stocks with high exposure to systematic volatility risk or for the low average returns of stocks with high idiosyncratic volatility.},
     language = {English},
     year = {2006},
     publisher = {Blackwell Publishing for the American Finance Association},
     copyright = {Copyright © 2006 American Finance Association},
    }

However, instead of expected [1] for reference, I am getting [?], an nothing is listed under references, though the word "References" does show up.

In the youtube tutorial that I was following this case is described. The tutorial did say that sometimes there might this be an issue with creating a reference. To which the author suggest to work in BibTeX only, then move to pdfLaTeX and then click run a couple of times, and things should work. I did the above, but nothing works for me.

Any ideas how to get my code to work?

Edit:

Here are the contents of my .bbl file:

% Generated by IEEEtran.bst, version: 1.13 (2008/09/30)
\begin{thebibliography}{}
\providecommand{\url}[1]{#1}
\csname url@samestyle\endcsname
\providecommand{\newblock}{\relax}
\providecommand{\bibinfo}[2]{#2}
\providecommand{\BIBentrySTDinterwordspacing}{\spaceskip=0pt\relax}
\providecommand{\BIBentryALTinterwordstretchfactor}{4}
\providecommand{\BIBentryALTinterwordspacing}{\spaceskip=\fontdimen2\font plus
\BIBentryALTinterwordstretchfactor\fontdimen3\font minus
  \fontdimen4\font\relax}
\providecommand{\BIBforeignlanguage}[2]{{%
\expandafter\ifx\csname l@#1\endcsname\relax
\typeout{** WARNING: IEEEtran.bst: No hyphenation pattern has been}%
\typeout{** loaded for the language `#1'. Using the pattern for}%
\typeout{** the default language instead.}%
\else
\language=\csname l@#1\endcsname
\fi
#2}}
\providecommand{\BIBdecl}{\relax}
\BIBdecl

Edit:

Here are contents of my .blg file.

This is BibTeX, Version 0.99dThe top-level auxiliary file: newfile.aux
The style file: IEEEtran.bst
I couldn't open database file my_bibtex.bib
---line 4 of file newfile.aux
 : \bibdata{my_bibtex
 :                   }
I'm skipping whatever remains of this command
I found no database files---while reading file newfile.aux
Warning--I didn't find a database entry for "2006"
-- IEEEtran.bst version 1.13 (2008/09/30) by Michael Shell.
-- http://www.michaelshell.org/tex/ieeetran/bibtex/
-- See the "IEEEtran_bst_HOWTO.pdf" manual for usage information.

Done.
(There were 2 error messages)

Thank You in Advance

Best Answer

Make sure that you have assigned the key “2006” in your my_bibtex.bib. Let's assume your TeX file is named test.tex. Then you should have ran bibtex test. Check that it did not print any error messages.

To further pin down your problem you should add \nocite{*} to your TeX file. (I always put it right before \bibliography.) This makes bibtex print all entries in your bibliography, even those which are not explicitly cited in the document.

So this is still about https://tex.stackexchange.com/questions/61301/creating-a-reference-with-bibtex-beginner. Another guess could have been, that a bibtex key can not start with a digit, but I just tried that and it is not a problem.

With the bibtex file from the other post I tried to build it and I got this error from bibtex:

This is BibTeX, Version 0.99d (TeX Live 2011)
The top-level auxiliary file: test10.aux
I couldn't open style file IEEEtran.bst
---line 3 of file test10.aux
 : \bibstyle{IEEEtran
 :                   }

I.e. I don't have that bibtex style. So you should also check if that style is a valid one which is installed on your system!

...

I can not really believe that you don't get any error messages. After I have downloaded the IEEEtran.bst file, everything worked ok. Note that for compiling you need to do

pdflatex first_try.tex
bibtex first_try
pdflatex first_try.tex
pdflatex first_try.tex

In the first run, pdflatex creates the first_try.aux file which contains the information about used bibliographies. With that given, bibtex can construct the first_try.bbl file with the assembled bibliography data. Then pdflatex will include it in the document. But as that happens mostly after the point it is referenced, another run of pdflatex is required to get a correct reference.

If you still can't solve the problem, please post the output of those commands.