User Tools

Site Tools


create_table_as_select

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

create_table_as_select [2013/07/30 21:45]
admin Update according to new features in Lure V3
create_table_as_select [2013/07/31 14:49] (current)
admin
Line 11: Line 11:
 To illustrate this let's consider the table with name ''​DIVISION''​ and Subversion as a source code repository. Firstly we must get the revision when the file ''​DIVISION.table.lsql''​ was first added to Subversion: To illustrate this let's consider the table with name ''​DIVISION''​ and Subversion as a source code repository. Firstly we must get the revision when the file ''​DIVISION.table.lsql''​ was first added to Subversion:
  
-<box round 677px>​{{:​table-svn-log.png?​nolink&​}}</​box|Using "svn log" to get the earliest revision>​+<box round 707px>​{{:​table-svn-log.png?​nolink&​}}</​box|Using "svn log" to get the earliest revision>​
  
 Since the first revision of the file ''​DIVISION.table.lsql''​ in the repository is ''​65'',​ it will suffice if the version number of the versioned patch file is set to ''​64''​. (If the file has not yet been added to the Subversion repository then use the HEAD revision number.) Since the first revision of the file ''​DIVISION.table.lsql''​ in the repository is ''​65'',​ it will suffice if the version number of the versioned patch file is set to ''​64''​. (If the file has not yet been added to the Subversion repository then use the HEAD revision number.)
Line 17: Line 17:
 I will now create a patch file with name ''​DIVISION.table.lsql.r64.lpatch''​ and add my custom "''​CREATE TABLE AS SELECT''"​ statement: I will now create a patch file with name ''​DIVISION.table.lsql.r64.lpatch''​ and add my custom "''​CREATE TABLE AS SELECT''"​ statement:
  
-<box round 754px>​{{:​ctas-patch.png?​nolink&​}}</​box|Patch file with custom CREATE TABLE statement.>​+<box round 784px>​{{:​ctas-patch.png?​nolink&​}}</​box|Patch file with custom CREATE TABLE statement.>​
  
 Use Lure Patch Test to confirm that the patch file correctly creates the table: Use Lure Patch Test to confirm that the patch file correctly creates the table:
  
-<box round 754px>​{{:​ctas-patch-console.png?​nolink&​}}</​box|Patch Test output shows patch file is correct.>​+<box round 784px>​{{:​ctas-patch-console.png?​nolink&​}}</​box|Patch Test output shows patch file is correct.>​
  
 Lure executed the patch file and then verified that the patch file created a table with the correct structure. Lure executed the patch file and then verified that the patch file created a table with the correct structure.
create_table_as_select.txt ยท Last modified: 2013/07/31 14:49 by admin

Page Tools