Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2000 Forums
 SQL Server Development (2000)
 How do I reference a

Author  Topic 

AskSQLTeam
Ask SQLTeam Question

0 Posts

Posted - 2001-05-03 : 09:30:44
Bob writes "I need to present the contents of a column (60 bytes wide) on my web interface. Most of the pertinent information is in the first 25 bytes of the column. I want to use the left function in SQL to trim back the data. The sql is as follows:

set rsMenu = db.execute("select left(d.material_desc_1,25) d.material_code from ORDER_DETAIL d, order_open o where d.contract_nmbr = o.contract_nmbr")

How do I reference the first column selected in a subsequent value clause? I understand that without the "left" function, I can use:

<input type=submit value="= rsMenu("material_desc_1") ">

How do I reference left(material_desc_1,25)?"
   

- Advertisement -