Featured
-
How Regression Testing Detects Integral Errors In Business Processes
Humans are forever changing and evolving and so to
by kristina.rigina -
Get Display Banner Advertising Opportunity on FindNerd Platform
“Do you have a product or service that nee
by manoj.rawat -
Android O Released with Top 7 New Features for App Developers
Android was founded by Andy Rubin, Rich Miner, Nic
by sudhanshu.tripathi -
Top 5 Features That Make Laravel the Best PHP Framework for Development
Laravel is a free open source Web Framework of PHP
by abhishek.tiwari.458 -
Objective C or Swift - Which Technology to Learn for iOS Development?
Swift programming language is completely based on
by siddharth.sindhi
Tags
Active Records for Adding, Removing or Changing a column
When we create a web application we generally create models which are referred to as tables in the database. Sometimes we need to add a column to the existing table or remove an unused column from the table or just change the column. The way to d...
Hash Conditions in Active Records (Rails)
Hash Conditions in Active Records (Rails)
Active records allows us to to pass in array conditions to our query to fetch a single record or all the records matching
the key value pair. In these hash conditions we pass the key as the na...
Adding, Removing or Changing a column through Active Records in Rails
While creating a web application we create models in our application which act as tables in the database. Sometimes when the development of the application moves further, the need arises to add a column to our existing table or removing a column ...
Finding or Building a New Object In Rails Through Active Records
Finding or Building a New Object In Rails Through Active Records
Active records provide us with some methods which we can use in our database
to find or create objects automatically without having to fire two queries.
These methods run 2...
Select Vs Pluck in Rails
In this tutorial we will see how we can use pluck and select in rails active record queries.
Select is used to fetch records with specific attributes. It returns ActiveRecord::Relation object.
Project.select(:id)
Project...
Transaction in Rails
To maintain the data integrity sometimes we need the changes to database to occur when all of the actions have successfully finished. One of the examples is funds transfer from one account to another. One account should be debited and anoth...
Active record rails
Earlier when programmer used to build a web application, they required the skills to code in both business logic language and database language. However now, back-end frameworks are using Object-Relational Mapping (ORM). It helps programmer st...
How to Apply Active Record Observer on a Particular Column
Meaning:-
Active Record Observers means a callback or a trigger which will get called in the life cycle of active record object. This is used for the purpose of reducing the burden on model's functionality which is not directly belongs to model....