We learn this from 2 Timothy 3:14-17, the key Scripture for this blog:
But as for you, continue in what you have learned and have become convinced of, because you know those from whom you learned it, and how from infancy you have known the holy Scriptures, which are able to make you wise for salvation through faith in Christ Jesus. All Scripture is God-breathed and is useful for teaching, rebuking, correcting and training in righteousness, so that the man of God may be thoroughly equipped for every good work.
Matthew Henry's commentary on this verse summarizes the uses of Scripture for us:
-It makes us wise to salvation through faith
-It is profitable for-- doctrine (teaching)
--reproof (tell of faults)
--instruction in righteousness
-Makes us competent, finished to do God's will (Romans 12:2 -Do not conform any longer to the pattern of this world, but be transformed by the renewing of your mind. Then you will be able to test and approve what God's will is—his good, pleasing and perfect will.
-Furnished for every good work
Henry summarizes the passage this way:
Whatever duty we have to do, whatever service is required from us, we may find enough in the Scriptures to furnish us for it.