1

How do I get rid of this situation?

enter image description here

The code for creating the table is :

\documentclass{IEEEtran}
\begin{document}
\begin{table}[htbp]
  \centering
  \caption{LCS Grammar for the Web Portal}
    \begin{tabular}{rrr}
    \toprule
    \textbf{GRAMMAR} & \textbf{EXPLANATION } & \textbf{CHANGE REQUEST} \\
    \midrule
    L→(S1.S2).((S3.S4)*S5) & S1 = Login & \multicolumn{1}{c}{} \\
    S1→OP1 & S2 = Pay Landline Bills & \multicolumn{1}{c}{} \\
    S2→OP2 & S3 = Register For New Services & \multicolumn{1}{c}{} \\
    S3→OP3 & S4 = Get Status & \multicolumn{1}{c}{} \\
    S4→OP4 & S5 = View Bills & \multicolumn{1}{c}{} \\
    S5→OP5 & OP1=get\_credentials & \multicolumn{1}{c}{(op1.op2).((op3.op4)*op6)} \\
    S6→OP6 & OP2= get\_card details &  \\
          & OP3=get\_custdetails &  \\
          & OP4=get\_notification &  \\
          & OP5=get\_bill &  \\
          & OP6=get\_usage &  \\
          &       &  \\
    \bottomrule
    \end{tabular}%
  \label{tab:lcsgrammar}%
\end{table}%
\end{document}
2
  • 2
    ! Undefined control sequence. l.7 \toprule Please, at least try to compile your MWE before asking a question!
    – yo'
    Mar 8, 2015 at 16:20
  • 1
    Use \begin{table*} instead of \begin{table}[htbp] and \end{table*} instead of \end{table}: your table doesn't fit in a column, so you have to use a double column float.
    – egreg
    Mar 8, 2015 at 16:22

1 Answer 1

4

There is no chance that table fits in one column. Use the table* two column float type.

I have also changed the alignments to left.

\documentclass{IEEEtran}
\usepackage[utf8]{inputenc}
\usepackage{newunicodechar}
\usepackage{booktabs}
\usepackage{lipsum}

\newunicodechar{→}{$\to$}

\begin{document}

\lipsum[2]

\begin{table*}
\centering

\caption{LCS Grammar for the Web Portal}
\label{tab:lcsgrammar}

\begin{tabular}{lll}
\toprule
\textbf{GRAMMAR} & \textbf{EXPLANATION } & \textbf{CHANGE REQUEST} \\
\midrule
L→(S1.S2).((S3.S4)*S5) & S1 = Login & \\
S1→OP1 & S2 = Pay Landline Bills & \\
S2→OP2 & S3 = Register For New Services & \\
S3→OP3 & S4 = Get Status & \\
S4→OP4 & S5 = View Bills & \\
S5→OP5 & OP1 = get\_credentials & \multicolumn{1}{c}{(op1.op2).((op3.op4)*op6)} \\
S6→OP6 & OP2 = get\_card details &  \\
       & OP3 = get\_custdetails &  \\
       & OP4 = get\_notification &  \\
       & OP5 = get\_bill &  \\
       & OP6 = get\_usage &  \\
\bottomrule
\end{tabular}

\end{table*}

\lipsum[1-40]

\end{document}

enter image description here

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .