Ruby on Rails Directory Structure
Ruby on Rails Directory Structure Like Below:demo/ ..../app ......../controller ......../helpers ......../models ......../views ............../layouts ..../components ..../config ..../db ..../doc ..../lib ..../log ..../public ..../script ..../test ..../tmp ..../vendor README RakefileDirectory or File Meaning:app : This organizes your application components. It\'s got subdirectories that hold the view (views and helpers), controller (controllers), and the backend business logic (models).app/co
How to access sqlite database
不知道会有多少人遇到同样的问题,ROR装好之后,怎样访问sqlite数据库?命令:rails db 或 rails dbconsole 或者 sqlite3 db/development.sqlite3D:\Ruby\projects\blog>rails db SQLite version 3.7.15.2 2013-01-09 11:53:05 Enter ".help" for instructions Enter SQL statements terminated with a ";" sqlite> select * from posts; 1|Hello World.|15mins build a blog with ROR. PTIAN |2013-04-06 03:39:30.770540|2013-04-06 03:39:30.770540 2|||2013-04
MVC in Ruby on Rails
這張圖示中的執行步驟是:瀏覽器發出HTTP request請求給Rails路由(Routing)根據規則決定派往哪一個Controller的Action負責處理的Controller Action操作Model資料Model存取資料庫或資料處理Controller Action將得到的資料餵給View樣板回傳最後的HTML成品給瀏覽器其中,路由主要是根據HTTP Method方法(GET、POST或是PUT、DELETE等)以及網址來決定派往到哪一個Controller的Action。例如,我們在「Rails起步走」一
使用Ruby On Rails15分钟打造一个博客系统
"15分钟做一个博客系统",是Ruby On Rails非常经典Demo练习。我也参考着视频,试着做了一遍,这里大概记录下过程。视频地址:http://v.youku.com/v_show/id_XNTM4NjA3MDQw.html----------------------------------------------------------------------详细过程--------------------------------------------------------------------------------------------------------------版本信息Rails版本:3.2.13Ruby版本:1.9.3OS:Windows 7控制台创建一个
Ruby on Rails Resource
RailsInstaller: http://railsinstaller.org/Ruby China: http://ruby-china.org/Ruby 使用手冊:http://guides.ruby.tw/ruby/Ruby on Rails实战圣经:http://ihower.tw/rails3/index.html Rails Guides:http://guides.rubyonrails.org/Ruby on Rails Tutorial:http://guides.rubyonrails.org/ (中文:http://about.ac/rails-tutorial-2nd-cn/)Rails in a Nutshell:http://ofps.oreilly.com/titles/9780596521424/Rails Complete API:http://api.rubyonrails.org/Ruby 代码规范:https://github.com/bbatsov/
Installing Ruby on Rails
对于新手推荐使用Railsinstaller来安装Ruby on Rails,刚开始减少在安装阶段过多的纠缠,快速进入框架学习阶段。1.下载Railsinstallersite:http://railsinstaller.org/对新手来说,Railsinstaller非常方便,里边包含了所有ROR需要的软件,可谓一站式安装。2.安装Railsinstaller唯一一点要注意的是,安装路径不要有空格3.安装完之后,输入github的用户名和邮箱4.重开一个命令行,查看各个组件是否安装
AD Merge Patch
AD Merge Patch (command:admrgpch) is used to merge multiple patches into a single one. This is useful when we have to apply many patches to reduce the patching time. Note:it can\'t be used to merge patches of different releases, platforms or parallel modes.Command like:admrgpch -s <source> -d <desintation> -logfile <name> -merge_name <default is merged, so name it appropriately>---------------------------------------------------------
Drop-down list in OA Framework
Basic Steps:1.Define a lookup, lookups value are for drop-down list items.2.Create VO, this is used to query above lookups3.in Page file, Add a messageChoice type item in a region.4.Drop-down list with static itemsSimilar Postshttps://blogs.oracle.com/prajkumar/entry/implement_poplist_in_oa_frameworkhttp://newtonapples.com/message-choice/
Error:"No method with signature" in OAF
In a OAF page, encounter a rrror like:No method with signature - No method with signature - subinvExitEvent()(subinvExitEvent is a method in AM)Solution:Check methods in AM and CO,re-Load latest related AM and CO into JDEV, Then re-test the issue.,
AD Utilities
AD Utilities (Applications DBA Utilities) are programs which perform a variety of tasks, including generating files, updating your system, merging and applying patches, installing off-cycle products. These AD Utilities are executable files in $AD_TOP/binUtility Executable/ Interface Role AD Administration adadmin Oracle Application Manager Performs maintenance tasks on the Oracle
Error:APP-FND-00804
点Locator弹性域,报APP-FND-00804错,详细错误信息如下APP-FND-00804: Program error: Invalid arguments to the flexfield routines. Please inform your support representative that:Routine FDFGST unable to find flexfield qualifier 4. The flexfield routines have been called incorrectly.Make sure the flexfield qualifiers specified match those defined in the Register Key Flexfield form.Solution:Recompile the Stock Locators KFF.In System Administrator responsibilityApplication : Flexfield :
Script to list Customer (Party), Account, Site data
The Script to list of its customer (party), account, site, address, collector, and other related information. SELECT ---------------------------------------------------------- -- Party Information ---------------------------------------------------------- hp.party_number "Registry ID", hp.party_name "Party Name", hp.party_type "Party Type", DECODE(hp
Scripts about Vendor(Supplier) Information
Use the Below Query to get the Vendor Details.SELECT PO.SEGMENT1 VENDOR_NUMBER, PO.VENDOR_NAME, PO.VENDOR_NAME_ALT, PO.VENDOR_TYPE_LOOKUP_CODE, POS.VENDOR_SITE_CODE ,VENDOR_SITE_CODE_ALT ,POS.ADDRESS_LINE1 ,POS.ADDRESS_LINE2 ,POS.ADDRESS_LINE3 ,POS.ADDRESS_LINE4 ,POS.CITY ,POS.COUNTRY ,POS.ZIP ,POS.COUNTY ,POS.STATE ,POS.INVOICE_CURRENCY_CODE ,POS.PAYMENT_CURRENCY_CODE ,POS.PAYMENT_METHOD_LOOKUP_CODE ,POS.PAY_GROUP_LOOKUP_CODE ,HR.NAME ,INACTIVE_DATE ,GLCC.CONCATENATED_SEGMENTS LIABILITY_ACC
ORA-24323 Error in Report Builder
Report Builder写入SQL后,点下一步,报ORA-24323: 不允许此值的错误解决方法:重新连接数据库,再试,问题应该能解决。原因可能是数据库的连接丢失造成的。
New Feature "Optional Lot Allocation" in Oracle EBS R12.2.2
今天和同事分享了我在EBS R12.2.2做的一个新功能-Optional Lot Allocation. Optional Lot Allocation的引入,可以让客户在挑库的时候,可以选择是否自动挑入批次。在以前,挑库后,批次一定会根据挑库规则被选择上,客户可能会不满意挑库规则所挑选的批次,那么就需要手动的删除批次,再更改批次,如果批次很多就会增加很多工作量。新功能之后,客户可以选择不挑批次,未来一个合
"ROWNUM = 1"会使SQL的性能更快?
SQL中加入ROWNUM = 1会让性能有所提升么?有可能,但也不全是。遇到了一个Case,ROWNUM = 1的加入并没有像想象的那样让性能有所提升。背景:PL/SQL的代码,用下边的Query来检查符合条件的记录是否存在。SELECT \'X\' FROM MTL_MATERIAL_TRANSACTIONS A,MTL_TRANSACTION_TYPES B WHERE A.ORGANIZATION_ID = :b1 AND B.TRANSACTION_TYPE_ID = A.TRANSACTION_TYPE_ID AND B.TRANSACTION_ACTION_ID = A.TRANSACTION_ACTION_ID AND ROWNUM = 1
不要为了重构而牺牲代码的阅读性
在性能可以接收的前提下,不要为了重构而牺牲代码的阅读性,这会让后期的维护越来越难。尤其是PL/SQL这样面向过程的语言,宁肯代码存在冗余,也要保证逻辑的清晰。重构是为了让逻辑更简单和清晰,而不是为了抽象让逻辑变得混淆和复杂。为了重构而重构,那是炫技,企业级软件工程需要更多地是稳定,清晰,而不是花架子。--------------------------------------------------------
Error: APP-ONT-250268: Record is currently being worked on by another user, Please try to update it
Error: APP-ONT-250268: Record is currently being worked on by another user, Please try to update it later.Cause:叉掉IE,EBS非正常关闭,就可能会有这个问题。非正常关闭,造成数据库锁没有释放,下次再登陆可能就遇到上述错误。Solution: 如何解数据库锁
Creating a Customer at the time of creating a Sales Order
Profile:OM: Add Customer允许可以在定义销售订单时,快速添加一个新的客户None:表示不允许使用快速添加客户功能。All:表示既可以添加新客户,也可以为已经存在的客户添加地址及联系人。Address and Contact Only:仅能为已经存在的客户添加地址及联系人
FRM-40735: ON-ERROR trigger raised unhandle exception ORA-06508
Form Builder版本10,在本机编译、运行Form(此form基于Template.fmb基础上开发的),编译都没有问题,但是运行时报错。英文:FRM-40735: ON-ERROR trigger raised unhandle exception ORA-06508中文:FRM-40735: ON-ERROR 触发器提出了不能处理的异常状况 ORA-06508原因:基于Template.fmb无法在本机的Form Builder中运行,必须上传到服务器上,才能运行,否则一定会报上述错误。全新开发的Form(不基于Template.fmb)