DBIX :: Composer.

DBIX :: Composer´Â SQL ¹®À» ÀÛ¼ºÇÏ°í ½ÇÇàÇÏ´Â Perl ¸ðµâÀÔ´Ï´Ù.
Áö±Ý ´Ù¿î·Îµå

DBIX :: Composer. ¼øÀ§ ¹× ¿ä¾à

±¤°í

  • Rating:
  • ƯÇã:
  • Perl Artistic License
  • °¡°Ý:
  • FREE
  • °Ô½ÃÀÚ À̸§:
  • Igor Plisco
  • °Ô½ÃÀÚ À¥»çÀÌÆ®:
  • http://search.cpan.org/~plisco/DBIx-Composer-1.00/lib/DBIx/Composer.pm

DBIX :: Composer. ű×


DBIX :: Composer. ¼³¸í

DBIX :: Composer´Â SQL ¹®À» ÀÛ¼ºÇÏ°í ½ÇÇàÇÏ´Â Perl ¸ðµâÀÔ´Ï´Ù. DBIX :: Composer´Â SQL ¹®À» ÀÛ¼ºÇÏ°í ½ÇÇàÇÏ´Â Perl ¸ðµâÀÔ´Ï´Ù. Synopsis´Â DBIX :: Composer $ cmd = »õ DBIX :: Composer ()¸¦ »ç¿ëÇÕ´Ï´Ù. $ cmd -> {table} = 'table1'; $ cmd -> {fields} = 'À̸§, À̸ÞÀÏ'; $ cmd -> {where} = "where login = 'peter'"; $ cmd-> compose_select¸¦ ÀμâÇϽʽÿÀ; # Àμâ "name, table1¿¡¼­ select name, select login = 'peter'"$ dbh = open_database (); # µ¥ÀÌÅͺ£À̽º ¿­±â DBIX :: Composer $ cmd = »õ DBIX :: Composer (dbh => $ dbh, debug => 1); $ cmd -> {table} = 'table1'; $ cmd -> {fields} = '·Î±×ÀÎ, À̸§, À̸ÞÀÏ'; $ cmd -> {°ª} = " 'Á¸', 'Á¸ ½º¹Ì½º', 'john@smith.com'; $ cmd-> insert (); # ¸í·ÉÀ» "inters"(·Î±×ÀÎ, À̸§, À̸ÞÀÏ) °ª # ( 'John', 'John Smith', 'john smith', 'john@smith.com') "·Î »ðÀÔÇϽʽÿÀ. #ÀÌ ¸í·ÉÀ» STDERR¿¡ ÀμâÇÕ´Ï´Ù. ½ÇÇà.ÀÌ ¸ðµâÀº SQL ¹®À» ÀÛ¼ºÇÏ°í ½ÇÇàÇÏ´Â µ¥ µµ¿òÀ̵˴ϴÙ. ¸ÕÀú SQL ¹®ÀÇ ÀϹÝÀûÀÎ ºÎºÐ¿¡ ´ëÇØ »õ °´Ã¼¸¦ ¸¸µé°í Çؽø¦ ä ¿ó´Ï´Ù. ±×·± ´ÙÀ½ÀÌ ºÎÇ°¿¡¼­ SQL ¹®À» ÀÛ¼ºÇϰųªÀ̸¦ ÀÛ¼ºÇÏ¿© ½ÇÇàÇÏ°í ÁÁ¾ÆÇÏ´Â ¿¬°á ¹æ¹ýÀ» »ç¿ëÇÏ¿© µ¥ÀÌÅͺ£À̽º¿¡ ¿¬°áÇÏ°í Ç¥ÁØ µ¥ÀÌÅͺ£À̽º Çڵ鷯 $ dbh°¡ÀÖ´Â DBIX :: Composer °´Ã¼¸¦ Á¦°øÇÕ´Ï´Ù. ¸í·É¹®À» ½ÇÇàÇÒ °èȹÀÌ ¾Æ´Ï¸é Database.so¿¡ ´ëÇÑ ¿¬°áÀ» »ý·« ÇÒ ¼ö ÀÖ½À´Ï´Ù. »õ °³Ã¼¸¦ »ý¼º ÇÑ ÈÄ ¸Å°³ º¯¼ö ¶Ç´Â SQL ¸í·É ÆÄÆ®¸¦ ¼³Á¤ÇÒ ¼ö ÀÖ½À´Ï´Ù. "where ...", "Order ...", "Limit ..."¿Í °°Àº ¸í·ÉÀÇ ¼öÁ¤ÀÚ´Â "a = b"»Ó¸¸ ¾Æ´Ï¶ó "a = b"»Ó¸¸ ¾Æ´Ï¶ó "a = b"¿Í °°Àº Àüü ¼öÁ¤ ÀÚ ¿©¾ßÇÕ´Ï´Ù. () SQL Fetch ¹®À» ÁغñÇؾßÇÕ´Ï´Ù - ³»ºÎÀûÀ¸·Î ÁغñµË´Ï´Ù. ºÎÇ°À» ¼³Á¤ ÇÑ Á÷ÈÄ ¸í·É¹®À» ½ÇÇàÇÒ ¼ö ¾ø½À´Ï´Ù. ¸ðµâÀº ¸í·ÉÀÌ ±¸¼ºµÇ¾î ½ÇÇàµÇ°í ½ÇÇàµÇ¾ú´ÂÁö ¿©ºÎ¸¦ È®ÀÎÇÕ´Ï´Ù. ÀÌ·¯ÇÑ µ¿ÀÛÀ¸·Î ÀÎÇØ ½ÇÇà ÈÄ ¸í·É ÆÄÆ®¸¦ Àç¼³Á¤ÇÏÁö ¾ÊÁö¸¸ »õ DBIX :: Composer °´Ã¼¸¦ ¸¸µå´Â °ÍÀÌ ÁÁ½À´Ï´Ù. ¿ä±¸ »çÇ× : ¡¤ Perl.


DBIX :: Composer. °ü·Ã ¼ÒÇÁÆ®¿þ¾î