Related to earlier questions about "unexpected token"
I get the following error
UCAExc:::3.0.3.1 unexpected token: $BRANDRAP
When I run the code below in the NB IDE
try { Class.forName("net.ucanaccess.jdbc.UcanaccessDriver");
Connection conn = DriverManager.getConnection("jdbc:ucanaccess://E:/DEV05/AmexDW/$TPMAIN.MDB");
Statement s = conn.createStatement();
ResultSet rs = s.executeQuery("SELECT [l BL Item Headers].[BL Counter], [l BL Item Headers].[BL A/C], [l BL Item Headers].[BL Entry] FROM [l BL Item Headers]");
while (rs.next())
{
System.out.print(rs.getString(2));
System.out.print(" : ");
System.out.print(rs.getString(3));
System.out.print(" : ");
System.out.print(rs.getString(4));
System.out.print("\n");
}
}
catch (SQLException e)
{
System.out.println(e.getMessage());
return;
}
catch (ClassNotFoundException nf)
{
System.out.println(nf.getMessage());
return;
}
NB. $BRANDRAP is a table in the $TPMAIN.MDB database but I'm SELECTING from the table [l BL Header Items]