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)
 updation

Author  Topic 

purushotham216
Starting Member

14 Posts

Posted - 2008-05-09 : 07:12:27
hi i have 40 seats ,40 status(all are n varchar) with bus no

it is one line bus ticket booking..

it display all information on user wrt database info

suppose user selects one or more than one seat,it updates status of selected seats to 'FALSE'

my table is like this ..
busno s1 s2,s3..... s40, st1, st2, .... st40
A0001 1 2 3 ... 40 true false ... true

so,if user selects seats 1 and 40 ..i want to update st1,st40 to FALSE
how i have to write column names of st1,st40 dynamically

pootle_flump

1064 Posts

Posted - 2008-05-09 : 08:17:28
Much easier is to design your table appropriately. You are violating first normal form - this problem you are having now will be the start of your problems if you keep this design. Have a read of the below - it will really help you understand relational database design:
http://www.tonymarston.net/php-mysql/database-design.html
Go to Top of Page
   

- Advertisement -