Is CODE a reserved word: SQL 2000?

  • Or is this problem more related to JDBC?

    I have a this field name: 'code'. This is the error message i get when i call a stored procedure:

    java.sql.SQLException: [Microsoft][SQLServer 2000 Driver for JDBC]Invalid column name: code

  • Look at "Reserved Keywords" in BOL I don't see it.

    But place in brackets should get around as long as is a column name.

  • I ran

    create table t(code varchar(10))

    select code from t

    through a jdbc driver without any problems.

    However, when I did

    select code2 from t

    I get your error message. Thus 'code' doesn't seem to be a reserved word.

  • must be in JDBC, because query analyzer doesn't have any problem with it.

    ----------------------------------------------------------------------------------
    Your lack of planning does not constitute an emergency on my part...unless you're my manager...or a director and above...or a really loud-spoken end-user..All right - what was my emergency again?

Viewing 4 posts - 1 through 3 (of 3 total)

You must be logged in to reply to this topic. Login to reply