DB FIELD NAME
Posted: Tue Nov 23, 2004 10:17 am
I am using PHP and MSSQL.
My problem is regarding column name in mssql.
Is there a function or a way to be able to display the name of a column whatever the case of this DB field.
I explain.
My Colum in MSSQL is called CompanyID (note Capital C and ID).
If I try to display the content of this column like $row["companyid"] I will not return any result.
But If respect the case of this fields as $row["CompanyID"] the right record will be display.
My database contain lots of fields that are Upper/Lower case, I am trying to find a way to convert everything to lower case without having to do it manually on the db.
Thanks
S
My problem is regarding column name in mssql.
Is there a function or a way to be able to display the name of a column whatever the case of this DB field.
I explain.
My Colum in MSSQL is called CompanyID (note Capital C and ID).
If I try to display the content of this column like $row["companyid"] I will not return any result.
But If respect the case of this fields as $row["CompanyID"] the right record will be display.
My database contain lots of fields that are Upper/Lower case, I am trying to find a way to convert everything to lower case without having to do it manually on the db.
Thanks
S