Question: I want to retrieve the value of label field by clicking on link button. it has to be fired only in onclick event only. i have tried with this , but it is giving null value.

```
protected void verifycount_Click(object sender, EventArgs e)
{
      GridViewRow link = ((LinkButton)sender).NamingContainer as GridViewRow;                
      Label qrcode = (Label)link.FindControl("lblqrcode");       
      string result=qrcode.text;
}

```

pls help do solve this

Answer: 
You don't need to keep around your old migration files in a Rails app, because your database schema should be captured either in schema.rb or an equivalent SQL file that can be used to regenerate your schema.

Migrations are not the authoritative source for your database schema. That role falls to either db/schema.rb or an SQL file which Active Record generates by examining the database. They are not designed to be edited, they just represent the current state of the database.

There is no need (and it is error prone) to deploy a new instance of an app by replaying the entire migration history. It is much simpler and faster to just load into the database a description of the current schema, which is in schema.rb or the SQL file.  

This file should be versioned and kept in source control.

To set up automatic schema.rb generation, modify config/application.rb by the `config.active_record.schema_format` setting, which may be :ruby or :sql.
If :ruby is selected then the schema is stored in db/schema.rb.
If :sql is selected, the schema is dumped out in native SQL format of
your database.
here is what I did, I found the last version migrated on production `ActiveRecord::SchemaMigration.last.version` and deleted all the migrations before that in my source code.

not the best way but I did `find db/migrate -type f`, copied the list of files before the last version and `pbpaste | rm` (macos).